IE
Home arrow Blog arrow All arrow Linux arrow Command Line
Command Line Print Email
Written by Nick Yeoman   
Sunday, 25 March 2007

In this tutorial I have collected the command line applications I use most.

Popular Commands

CommandDescription
suLogin as Super User
su -Update the environment
man <command_name>Manual or Help pages
ntsysvFind your running applications (fedora core 4)
locate search_wordLocate a file on your system
mkfs.ext3 /dev/hda1Format your hard disk in extention 3
shutdown -h nowShutdown the computer
reboot
shutdown -r now
reboot the computer
md5sumcheck the md5 sum of a file
sortsorts input
Symbolic Link
ln -s /dir/to/link/to
Taring
Create Gzipped Tarball tar -czvf file.tgz files
Extract Gzipped Tarball tar -xzvf file.tgz
File Permissions
Change Ownershipchown username filename
Chnage Groupchgrp groupname filename
Change owner and groupchown username:groupname file
Change group usersvigr
Change passwdvigpw

zip Files

*Unzip multiple zip files with a wildcard as only an update to extracted files
and to a different directory other than where the current zip files
reside:
unzip -u '*.zip' -d /something/something/dir

*Unzip multiple zip
files with a wildcard overwriting existing extracted files w/o answering a
prompt and to a different directory other than where the current zip files
reside:
unzip -o '*.zip' -d /something/something/dir

Find Your MAC Address

ifconfig

Mount Hard Drive

mount -t fs_type /dev/hda1 /mnt/hda1

The -t Option tells what file system type.

The /dev/hda1 is what device to mount.

The /mnt/hda1 is where to moun the device.

Grab input in a script

echo -n "password: "
read pass
echo "Your pass is $pass"

 

Fsck

File System Check.

This will check your file system for errors.

fsck.ext3 -f /dev/hda1

The .ext3 specifies the file type.

The -f option forces a check even if all seems well.

References

Last Updated ( 2007-07-27 19:15:36 )