Commands tagged bandwidth (7)

What's this? 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

Split huge file into DVD+R size chunks for burning
Real DVD+R size is 4700372992 bytes, but I round down a little to be safe. To reconstitute use cat. "cat file.img.gz.aa file.img.gz.ab ..... > file.img.gz"

Extract all of the files on an RPM on a non-RPM *nix

Tweak system files without invoking a root shell
only for sudo-style systems. Use this construct instead of I/O re-directors ``>'' or ``>>'' because sudo only elevates the commands and *not* the re-directors. ***warning: remember that the `tee` command will clobber file contents unless it is given the ``-a'' argument Also, for extra security, the "left" command is still run unprivileged.

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"

Convert CSV to JSON
Replace 'csv_file.csv' with your filename.

Geolocate a given IP address
GeoIP Needs to be installed. Can be done from some distro's or via for free. There even is a free city database availabble. If the GeoLiteCity is downloaded and installed it will also find more information $ geoiplookup -f /var/lib/GeoIP/GeoLiteCity.dat GeoIP City Edition, Rev 1: US, NJ, Absecon, 08201, 39.420898, -74.497704, 504, 609

Scale,Rotate, brightness, contrast,...with Image Magick
$rotate: the rotate angle $width, $height: width and height to scale to $birghtness: change brighness

Sort a character string
Sorts a character string, using common shell commands.

backup and synchronize entire remote folder locally (curlftpfs and rsync over FTP using FUSE FS)
connect to a remote server using ftp protocol over FUSE file system, then rsync the remote folder to a local one and then unmount the remote ftp server (FUSE FS) it can be divided to 3 different commands and you should have curlftpfs and rsync installed

get all bookmarks from all profiles from firefox
for i in $(ls /home/marco/.mozilla/firefox/*\.*/places.sqlite); do sqlite3 $i "SELECT strftime('%d.%m.%Y %H:%M:%S', dateAdded/1000000, 'unixepoch', 'localtime'),url FROM moz_places, moz_bookmarks WHERE = ORDER BY dateAdded;"; done

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.


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: