Commands tagged Linux (266)

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands


Check These Out

List the number and type of active network connections

Email a file to yourself
This works on Solaris 10.

Which processes are listening on a specific port (e.g. port 80)
swap out "80" for your port of interest. Can use port number or named ports e.g. "http"

Show linux kernel modules dependencies
Use modprobe to list all the dependencies of a certain kernel module. Handy when debugging system issues.

Send a backup job to a remote tape drive on another machine over SSH
I use this all the time for taking manual backups of stuff i want to keep but not important enough to backup regularly.

Find the package that installed a command

Replace spaces in a filename with hyphens
As long as you have perl based rename. You can check: =$ rename --help Unknown option: help Usage: rename [-v] [-n] [-f] perlexpr [filenames] That's the good one.

Convert a date to timestamp
Simple way to get a timestamp from a date

remove files and directories with acces time older than a given date
touch a dummy file with the specified date, then use find with -anewer .

List 10 largest directories in current directory
du -m option to not go across mounts (you usually want to run that command to find what to destroy in that partition) -a option to also list . files -k to display in kilobytes sort -n to sort in numerical order, biggest files last tail -10 to only display biggest 10


Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: