Category:
commands
The column utility is helpful for taking raw data and formatting it in a way that is easier for humans to comprehend. It can take a single column of data and format it into many equally spaced columns. Alternatively it can format multiple rows of data into tables. In our first example we have a [...]
In many cases it can be helpful to access text from within a PDF file but accomplishing this can be next to impossible. Luckily in Linux there is a command line program called pdftotext which is included with the xpdf package. This first step is making sure that the xpdf package is installed. In Ubuntu [...]
gphoto2 allows you to directly connect a digital camera over USB and transfer the saved images and videos to your computer. This is very helpful when you don’t have access to a media card reader. Install the gphoto2 package on your system. In Gentoo: # emerge media-gfx/gphoto2 In Ubuntu: # aptitude install gphoto2 Start off [...]
The lsof command stands for “list open files”. It can show all open files as well as sockets, memory mapped libraries, directories, pipes, and network sockets. It is an incredibly powerful tool which you can use to gather detailed information about what is happening on your system. If you run lsof as a normal user [...]
The find command allows you to recursively search and locate files on your system based on specific criteria. You can search by name, owner, group, type, permissions, date, as well as many others. The find command uses the following format: find [search_path(s)] [search_criteria] The following is the most basic way to run the find command. [...]
The ldd command allows you to view detailed information about library dependencies of dynamically linked programs and other shared libraries. ldd uses the runtime linker ld.so which reads the ELF formatted executable to generate the output. It is a helpful tool to have at your disposal when debugging broken programs. Here ldd examines the ‘ls’ [...]
Similar to the tail command which shows you the last few lines of a text file, the head command lets you to quickly view the first few lines. The head command syntax. head [options] file By default head will show you the first 10 lines of a text file. $ head textfile.txt You can change [...]
Similar to the head command which shows you the first few lines of a text file, the tail command lets you to quickly view the last few lines of a text file. It also supports a monitoring mode which displays ongoing changes within the file. The tail command syntax. tail [options] file By default tail [...]
The file command identifies the type or format of a file. It is a very handy command that can show you how to approach a file when the format is unknown. There are a variety of tests that it uses to determine its type, these tests include a filesystem test, magic number test, and language [...]
TAR is the GNU Tape ARchive utility. It is used to pack the contents of multiple files or directories in an archive file called a tarball. Tar can preserve directory organization including file ownership, permissions, links, as well as directory structure. To save space you can optionally enable compression with gzip, bzip2, or another external [...]