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.
» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10
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:
The following command finds all the files not modified in the last 5 days under /protocollo/paflow directory and creates an archive files under /var/dump-protocollo in the format of ddmmyyyy_archive.tar
Please be careful while executing the following command as you don?t want
to delete the files by mistake. The best practice is to execute the same
command with ls ?l to make sure you know which files will get deleted when
you execute the command with rm.
No comment... it's easy! Using the VBoxManage list and the switch 'hdds' or 'dvds' you can show the list of hard disks and DVD registered on the system.
If you want to know what OS are supported on "guest" machines on the Sun VirtualBox server.
where "cicciobox" is the name of your virtual machine in a Sun VirtualBox server
How to show the system properties of a Sun VirtualBox server
ethtool is used for querying settings of an ethernet device and changing them. In this example I setup 100 Mb/s full duplex on my Linux Box
the command is obvious, I know, but maybe not everyone knows that using the parameter "-l" you can limit the use of bandwidth command scp.
In this example fetch all files from the directory zutaniddu and I copy them locally using only 10 Kbs
edit the /etc/sysconfig/iptables file and try to work whit this:
-A INPUT -i (interface) -m mac (mac address) -j ACCEPT/DROP
Instead, install apt-get install secure-delete and you can use:
-- srm to delete file and directory on hard disk
-- smem to delete file in RAM
-- sfill to delete "free space" on hard disk
-- sswap to delete all data from swap
Check the ssh_config file and set the variable:
StrictHostKeyChecking no
A dear friend of mine asked me how do I copy a DVD to your hard drive? If you want to make a copy of the ISO image that was burned to a CD or DVD, insert that medium into your CD/DVD drive and (assuming /dev/cdrom is associated with your computer?s CD drive) type the following command
This command clone the first partition of the primary master IDE drive to the second partition
of the primary slave IDE drive (!!! back up all data before trying anything like this !!!)
When you need to add another tty device that can automatically start at boot time
If you need to keep an eye on a command whose output is changing, use the watch command. For example, to keep an eye on your load average
If you launch gnome-terminal manually, you can start with three open tabs
For example: check the APT security keys to make sure the Google digital signature was imported correctly
You can view the man pages from section five by passing the section number as an argument to the man command