Archive for the 'Linux/Unix' Category

Find the CPU (processor) speed and model under Linux

This article will show you how to find CPU (processor) type, speed, cache size, and much more under Linux. To find this information you will need to login to the Linux command-line shell and and enter the following command at the $ (or #) prompt: $ cat /proc/cpuinfo Sample Output processor : 0 vendor_id : [...]

Click here to read the full post

How to use tar to archive and extract files

This article will explain how to use the tar command in Linux to create, list, and extract files. 1. Creating a .tar file To tar the contents of a single folder: tar -cvf filename.tar /folder1 To tar the contents of a multiple folders: tar -cvf filename.tar /folder1 /folder2 /folder3 To tar multiple files tar -cvf [...]

Click here to read the full post

Find the number of files in a directory (Linux)

This article will show you how to find the number of files (including directories) within the current directory under Linux. Command ls -1 | wc -l Syntax Breakdown ls is the Linux command to list all files and folders in the current directory -1 will list each file on a separate line wc -l will [...]

Click here to read the full post

Shell command to bulk change file extensions in a directory (Linux)

This article will explain how to change the file extension for all files in a directory in Linux using a simple bash shell command. 1. Change from one extension to another The command below will rename all files with the extension .php4 to .php for f in *.php4; do mv $f `basename $f .php4`.php; done; [...]

Click here to read the full post

Run a script on Linux startup in 2 simple steps

There are several ways to run a script or program at startup on a Linux machine, especially when taking into account the various run levels. This example is a quickstart method on how to run it at run level 3. Copy your script or file to /etc/init.d Create a symbolic link from this file to [...]

Click here to read the full post

How to mount an ISO image in Linux

This article will explain how to mount an ISO image quickly and easily on Linux without downloading any additional software. If you are on a Windows operating system, check out the article: How to mount an ISO on Windows XP and Windows Vista Login as the root user (if you are not root, then switch [...]

Click here to read the full post

Find largest files on your hard drive (Windows & Linux)

Are you running low on disk space or just curious to know what files are eating up your hard drive space? Finding out the biggest files in your hard drive is simple. This article will show you how to do this on Windows XP and Linux/Unix. Windows XP Go to Start / Search / For [...]

Click here to read the full post