tar to compress a directory [code]tar zcvf thetar.tar dir/[/code] uncompress a tar [code]tar zxvf thetar.tar[/code] if you need to tar…
listing files and directories on Linux using ls, and its variety of switches. List files that begin with ‘stu’ [code]ls…
there are many ways to find things when on the linux command line finding text in a file to find…
total filesystem disk space [code]df -h[/code] get the size of a directory [code]du -sh /the/dir/[/code] list of directories and size…
appending text to a file [code]echo ‘hi there’ >> theFile[/code] append a file to another file [code]cat file1 >> file2[/code]…
most of my servers are running redhat (or centOS). here’s how i would count the number of emails in each…
make file executable chmod +x thefile execute a file in your current directory ./thefile
get all files of a type [code]wget -r -A.pdf http://www.thewebsite.com/[/code] get entire site like a spider [code]wget -r http://www.thewebsite.com[/code]
netstat -ntalp | grep :25 | awk ‘{print $5}’ | cut -d’:’ -f1 | uniq -c | sort -n