This site will look much better in a browser that supports web
standards, but should be accessible to any browser or Internet device.
<< Back: Part 3 <<
Week Four Quick Reminders
[some of the topics and commands covered]
More Basic Commands
[this week there's snoopy stuff! goodie!]
- ps [show processes running]
- ps -a [all processes running]
- ps -aux [includes process details]
- top [tool for monitoring system load which constantly refreshes itself. Ctrl+C
to quit]
- jobs [shows processes running in the background]
- fg [restores last process suspended in background]
- fg #% [selects a specific process to restore based on its number in the list of suspended programs]
- du [shows disk usage of directories]
- du directory path [follow with directory name to check only one directory]
- du -h [shows slightly more size detail like k or m measures. can be used with one or multiple directories. follow with directory name for just one]
- du -ha [shows all file disk usage. can be used with one or multiple directories.
follow with directory name for just one]
- du -s [summarize]
- quota [shows web account space allocation]
- quota -q [shows if you are over quota]
- Note: find -type f -size +# [is a quick way to find files
over a specified size if you need to pinpoint larger unnecessary files]
- users [see who else is located on your system]
- who [see who is actually logged into the system]
- w [gives who information with added details]
- whoami [gives you your own username. only useful if you have several login names]
- su [substitute user allows you to stay in your own shell and log in as a different user. permission normally denied to regular users on shared hosting.]
- last login [who has logged in on the server recently. this
command gives you the time span on the server]
- last [follow with this command for details on the logins]
- finger [allows you to check information on an individual user]
- finger someusername
- finger someusername@somesite.com [allows you to check remote sites if you know the username]
- wget [follows links to other files within a directory you download. any file type can be downloaded]
- wget -r [recursive. includes all subdirectories. assumed default is five levels.]
- wget -x [forces creation of separate directories]
- wget -rx --level=# http://somedomain.com [specifies how many directories deep to go with the number listed after level=]
- wget -b [puts process in background]
- wget -V [tells you what version you have]
- wget -k [retrieves the files in a setup for local viewing]
- wget -p [forces collection of any parts needed to display the document
ie. images]
- wget -m [mirror option. not totally reliable?]
- wget -w # [or --wait # forces wget to wait a specified number of
seconds between document requests to keep from overloading server where
you are downloading a large number of files]
- wget -t [forces retries due to interruptions default number of retries
is 20]
- wget -c [similar to resume feature in browsers and ftp clients. wget
picks up where it left off, doe not have to start over]
- wget -O [writes all documents to one large file]
- wget -N [time-stamp option] or....
- wget --timestamping
- wget -nc [no clobber good used with -r to prevent overwriting of files]
- wget -nd [no directory. all files will be placed in current directory.
original directory structure not recreated]
- wget -x [opposite of -nd. forces creation of directories]
- wget -nH [no-host directories. forces www.domain.com
not to be added. used with -r which does that by default]
- Ctrl+C [as in other places, stops process]
- rsync [create synchronized backups...updated files only]
- rsync -v [verbose output]
- rsync -a [archive -- recursive plus preserve file properties]
- rsync -p [preserve permissions]
- rsync -t [preserve times]
- rsync between separate remote servers is also covered in this lesson
- tar [recording of archives. must be used with options. slang
= tarball]
- tar -c [create]
- tar -f [file]
- tar -t [test]
- tar -v [verbose]
- * .filetype [used after option to specify one type of file only]
- several directory or file names after options will add them all to the archive
- tar -x [unpacks/extracts files from archive]
- tar -z [acts like gunzip to unzip. unpacks
tarball that's gzipped all in one step]
- gzip [compression tool]
- nice [adjusts priority schedule of operation. allows servver to schedule. range -20 highest priority to 19 lowest
- gunzip [uncompresses but does not save original archive
without using -c]
- zcat [duplicate of gunzip function]
- zip [create .zip files]
- unzip [unpack .zip files]
- compress/uncompress [older style version of this type of
command. produces file with .z extension. not using in class exercises]
- BZip2 [newer version of this type of command. produces files with .bz2 extension.
not used in class exercises]
- set [list of enviornmental variables. use Q
to quit a go back to prompt]
- which [shows if a program is available in your PATH]
- source [synonmous with << . >> period
command. not same as . for current directory. will
executed commands from specified filename from the current shell]
- alias [shorthand or shortcut to commands you use frequently]
<< Back: Part 3 <<