Capistrano is great for automating system tasks. Here is how to install it on RPM-based systems:
# yum install ruby rubygems
# gem install mocha echoe rake capistrano
Please note that mocha, echoe are optional for tests, but I included them in these instructions.
This is a repository of all of my Linux/Unix writings as well as useful tips and tricks for systems administration, engineering, and programming.
Tuesday, April 26, 2011
Monday, April 18, 2011
TCP dump for only port 80
Here is a way to dump all tcp traffic on port 80 to and from the bond0 interface:
tcpdump -w tcpdumpPort80.pcap -i bond0 tcp port 80
If you wanted to use only the eth0 interface (more common), use this example:
tcpdump -w tcpdumpPort80.pcap -i eth0 tcp port 80
tcpdump -w tcpdumpPort80.pcap -i bond0 tcp port 80
If you wanted to use only the eth0 interface (more common), use this example:
tcpdump -w tcpdumpPort80.pcap -i eth0 tcp port 80
Sending files from the Linux command line
Here is a quick way to e-mail yourself files from a server using mutt.
$ mutt -a tcpdumpApril182011.pcap my_name@example.com < /dev/null
Mutt is great for sending MIME encoded files.
$ mutt -a tcpdumpApril182011.pcap my_name@example.com < /dev/null
Mutt is great for sending MIME encoded files.
Subscribe to:
Posts (Atom)