Posted: 2005/11/28 by: fcruz.
Linux - Unix Blogs.
The following are a list of the most basic, but must know commands for any serious linux / unix user, please take your time to read this brief but informative article on linux commands.
Extremely Useful UNIX/Linux Commands
Solution:
Extremely Useful UNIX/Linux Commands
The following descriptions are short. You can get more information on their usage and options from their manual pages.
-
su
Switch to a different user in order to have their access priveleges without telneting in again. When no username is provided, su will switch you to root (superuser). You will be prompted for the user's password unless you have superuser priveleges. Usually the - option should be used since it loads all the configuration files for the user. Examples:
su su - su bob su - bob
-
ls
List contents of the directory.
-
pwd
Print Working Directory. Display the name of the directory that you are currently in.
-
cd
Change Directory.
-
mv
Move a file or directory
-
rm
Remove file.
-
rmdir
Remove directory.
-
chown
Change the owner of a file or directory.
-
chmod
Change Mode. Change the access restrictions for a file or directory.
-
du
Display the disk usage for a directory and its subdirectories.
-
df
Display the free disk space information.
-
ping
Ping an IP address or domain name to see if that server is active.
-
host
Look up a DNS entry for an IP address or domain name.
-
date
Display date and time.
-
command line completion
After typing part of a command or a path, hit the TAB key, and the Linux-Bash shell will auto complete what you're typing, or auto complete the path that your typing in! Try typing "cd /ho" and then hit the TAB key. It fills in "cd /home/", now add to that path "ht" and TAB... Now it gives you "cd /home/httpd/"! This and the "pwd" command allow you to move around the various paths of a machine faster that you can point and click in Windows Explorer! Give it a try.
[ Back ]
|