# Long term tcpdump

**URL:** <https://community.f5.com/t/long-term-tcpdump/12398>\
**Category:** Technical Forums\
**Tags:** availability, performance, irules, ihealth, icall, devops, application-delivery\
**Created:** [December 31, 2014, 9:03am UTC](https://community.f5.com/t/long-term-tcpdump/12398 "2014-12-31T09:03:53Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![artl2377\_166103](https://avatars.discourse-cdn.com/v4/letter/a/8e7dd6/32.png) [@artl2377\_166103](https://community.f5.com/u/artl2377_166103)\
**Post date:** [December 31, 2014, 9:03am UTC](https://community.f5.com/t/long-term-tcpdump/12398/1 "2014-12-31T09:03:53Z")

</div>

I am trying to investigate a non regular failure. external checking services are reporting failures to a customer website. I am running a tcpdump filtered for the scr ip and with a 50byte capture. Is there any other suggestions out there which could do this better ? am thinking iCall iRules etc - but have no experience of these. it is tough because the trigger is the lack of a session - so logging wont help…

Thanks in advance

---

<div class="post-metadata">

**Author:** ![Matt\_Dierick](https://d1p9zq3aats0t8.cloudfront.net/user_avatar/community.f5.com/matt_dierick/32/17074_2.png) [@Matt\_Dierick](https://community.f5.com/u/Matt_Dierick)\
**Post date:** [December 31, 2014, 9:15am UTC](https://community.f5.com/t/long-term-tcpdump/12398/2 "2014-12-31T09:15:42Z")

</div>

Hi,

If there isn’t any trigger, unfortunately, there is no option ☹ You have to add the most filters you can for your long term TCPDUMP and split it.

---

<div class="post-metadata">

**Author:** ![nitass\_89166](https://avatars.discourse-cdn.com/v4/letter/n/9fc29f/32.png) [@nitass\_89166](https://community.f5.com/u/nitass_89166)\
**Post date:** [December 31, 2014, 9:24am UTC](https://community.f5.com/t/long-term-tcpdump/12398/3 "2014-12-31T09:24:15Z")

</div>

I am running a tcpdump filtered for the scr ip and with a 50byte capture.

i understand support engineer would prefer full packet size (-s0) and end-to-end (client to server) capture with extended tmm data (:nnn).

e.g.

```tcl
tcpdump -nni 0.0:nnn -s0 -w /var/tmp/output.pcap

```

sol13637: Capturing internal TMM information with tcpdump

> **[404 Page not found | BIG-IP Documentation](https://techdocs.f5.com/kb/en-us/solutions/public/13000/600/sol13637.html)**
>
> Usage information and technical documentation for BIG-IP and other related F5 products

to continuously run it, you may check whether -C and -W are useful.

```tcl
-C Before writing a raw packet to a savefile, check whether the file is currently larger than file_size and, if so, close the current savefile and open a new one. Savefiles after the first savefile will have the name specified with the -w flag, with a number after it, starting at 1 and continuing upward. The units of file_size are millions of bytes (1,000,000 bytes, not 1,048,576 bytes).

Note that when used with -Z option (enabled by default), privileges are dropped before opening first savefile.

-W Used in conjunction with the -C option, this will limit the number of files created to the specified number, and begin overwriting files from the beginning, thus creating a ârotatingâ buffer. In addition, it will name the files with enough leading 0s to support the maximum number of files, allowing them to sort correctly.

```

or icall if there is something can trigger it.

iCall - All New Event-Based Automation System by Jason Rahm

> **[DevCentral](https://community.f5.com/)**
>
> DevCentral is an online technical community where engineers and practitioners collaborate, share knowledge, and solve problems related to F5 technologies and industry trends.

---

<div class="post-metadata">

**Author:** ![nitass](https://d1p9zq3aats0t8.cloudfront.net/user_avatar/community.f5.com/nitass/32/2270_2.png) [@nitass](https://community.f5.com/u/nitass)\
**Post date:** [December 31, 2014, 9:24am UTC](https://community.f5.com/t/long-term-tcpdump/12398/4 "2014-12-31T09:24:15Z")

</div>

I am running a tcpdump filtered for the scr ip and with a 50byte capture.

i understand support engineer would prefer full packet size (-s0) and end-to-end (client to server) capture with extended tmm data (:nnn).

e.g.

```tcl
tcpdump -nni 0.0:nnn -s0 -w /var/tmp/output.pcap

```

sol13637: Capturing internal TMM information with tcpdump

> **[404 Page not found | BIG-IP Documentation](https://techdocs.f5.com/kb/en-us/solutions/public/13000/600/sol13637.html)**
>
> Usage information and technical documentation for BIG-IP and other related F5 products

to continuously run it, you may check whether -C and -W are useful.

```tcl
-C Before writing a raw packet to a savefile, check whether the file is currently larger than file_size and, if so, close the current savefile and open a new one. Savefiles after the first savefile will have the name specified with the -w flag, with a number after it, starting at 1 and continuing upward. The units of file_size are millions of bytes (1,000,000 bytes, not 1,048,576 bytes).

Note that when used with -Z option (enabled by default), privileges are dropped before opening first savefile.

-W Used in conjunction with the -C option, this will limit the number of files created to the specified number, and begin overwriting files from the beginning, thus creating a ârotatingâ buffer. In addition, it will name the files with enough leading 0s to support the maximum number of files, allowing them to sort correctly.

```

or icall if there is something can trigger it.

iCall - All New Event-Based Automation System by Jason Rahm

> **[DevCentral](https://community.f5.com/)**
>
> DevCentral is an online technical community where engineers and practitioners collaborate, share knowledge, and solve problems related to F5 technologies and industry trends.

---

<div class="post-metadata">

**Author:** ![StephanManthey](https://avatars.discourse-cdn.com/v4/letter/s/e5b9ba/32.png) [@StephanManthey](https://community.f5.com/u/StephanManthey)\
**Post date:** [December 31, 2014, 5:10pm UTC](https://community.f5.com/t/long-term-tcpdump/12398/5 "2014-12-31T17:10:52Z")

</div>

As recommended by Nitass the so called ringdump will probably do the job. Make sure to write into the shared file system (option -w). A valuable parameter is “p” (for peer traffic) in the interface definition. The “p” will make sure to dump the serverside forwarded and returned packets as well in your trace.

Nitass already added the so called noise parameter (“nnn”) which requires the [F5 WireShark](https://devcentral.f5.com/articles/getting-started-with-the-f5-wireshark-plugin-on-windows) plugin to display the so called ethernet trailer information. The plugin for your WireShark version is available for download here on DevCentral.

The example below will run a ringdump with a total size of appr. 4 GByte (20 files of 200 MByte).

Please run a “df -h” first to make sure there is enough space in the target volume.

- C 200 (200 Mio. bytes per file)
- W 20 (max 20 files)
- Z root (run as root to avoid error when writing file)

```tcl
tcpdump -i 0.0:nnnp -C 200 -W 20 -s 0 -Z root -w /shared/ringdump/dump.cap

```

---

<div class="post-metadata">

**Author:** ![artl2377\_166103](https://avatars.discourse-cdn.com/v4/letter/a/8e7dd6/32.png) [@artl2377\_166103](https://community.f5.com/u/artl2377_166103)\
**Post date:** [January 1, 2015, 10:53pm UTC](https://community.f5.com/t/long-term-tcpdump/12398/6 "2015-01-01T22:53:56Z")

</div>

thanks very useful

---

<div class="post-metadata">

**Author:** ![artl2377\_166103](https://avatars.discourse-cdn.com/v4/letter/a/8e7dd6/32.png) [@artl2377\_166103](https://community.f5.com/u/artl2377_166103)\
**Post date:** [January 1, 2015, 10:53pm UTC](https://community.f5.com/t/long-term-tcpdump/12398/7 "2015-01-01T22:53:56Z")

</div>

thanks very useful
