commandlinefu.com is the place to record those command-line gems that you return to again and again.
Delete that bloated snippets file you've been using and share your personal repository with the world. 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.
If you have a new feature suggestion or find a bug, please get in touch via http://commandlinefu.uservoice.com/
You can sign-in using OpenID credentials, or register a traditional username and password.
First-time OpenID users will be automatically assigned a username which can be changed after signing in.
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.
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:
Great for little scripts that dig up obscure info that you are going to have to paste into another app anyway.
On Windows 2000 or newer, you can use the command line to save the current network interface info.
You can then edit the text file and re-apply it using the netsh -f command (or netsh exec). Keep a bunch of text files around to quickly switch connection info without using extra software.
displays time in seconds since January 1, 1970 UTC
plays wave file after 3 minutes
If you are behind a proxy server and have to authenticate with proxy server to browser web pages then you have to pass proxy server address and its port number along with user credentials to curl to got GET the page using curl. Example : "curl -U srikanth -x 126.96.36.199:8080
with this command you can empty file
Foward vnc securely from exampleserver.com
Depends on GET. You can also replace GET with curl, or `wget -qO -` if GET isn't available.
similar to perl chop()
Simply displays your current working directory. Helps when you are buried deep in /etc or some other obscure place.
If somehow if you get more than 1 same name rpm package install, then it cannot be removed by using simple rpm -e as it gives you more than one rpm matches error. The --matches will help to remove all the same name rpm packages.
Once Enabled this command enables a trail of all processes on the system. As the name suggested auditing for Solaris machines.
BSM creates a number of files in the /etc/security directory.
due to bug can not comment
add |sh when you agree the list, I often use that method to prevent typos in dangerous or long operations
Use this command to see logs update in real time
Telnet will make a tcp connection to a remote ip/port to test connectivity. If it times out, it's not reaching the host (maybe the firewall is blocking it). If connection is refused, it's reaching the host, but either the service is not listening on that port, or it's locked.