Professional Documents
Culture Documents
known as I/O redirection ( < for getting input from a file input and > for outputing to a file ) and piping using | to feed the output of one command as input to the next. Please investigate manuals in the lab for more examples than the few offered here. he following charts offer a summar! of some simple UNIX commands. hese are certainl! not all of the commands available in this robust operating s!stem" but these will help !ou get started.
E amp!e ls ls $al% cd tempdir cd .. cd (dh!att)web$docs mkdir graphics rmdir empt!dir cp file# web$docs cp file# file#.bak rm file#.bak rm 2.tmp mv old.html new.html more index.html lpr index.html man ls
Description &ists files in current director! &ist in long format *hange director! to tempdir +ove back one director! +ove into dh!att,s web$docs director! +ake a director! called graphics /emove director! (must be empt!) *op! file into director! +ake backup of file# /emove or delete file /emove all file +ove or rename files &ook at file" one page at a time 6end file to printer 8nline manual (help) about command
E amp!e grep :bad word: 2 chmod 1.. 2.html chmod 300 file.exe passwd ps aux ps aux | grep dh!att kill $5 4.0gcc file.c $o file g>> fil'.cpp $o fil' g?ip bigfile gun?ip bigfile.g? mail me@tAhsst.edu < file# pine telnet vortex.tAhsst.edu ssh $l dh!att Aa??.tAhsst.edu ftp station#.tAhsst.edu ncftp metalab.unc.edu
Description %ind which files contain a certain word *hange file permissions read onl! *hange file permissions to executable *hange passwd &ist all running processes b! ;I< &ist process ;I<,s running b! dh!att =ill process with I< ;4.0*ompile a program written in * *ompile a program written in *>> *ompress file Uncompress file 6end file# b! email to someone /ead mail using pine 8pen a connection to vortex 8pen a secure connection to Aa?? as user dh!att Upload or <ownload files to station# *onnect to archives at UN*
0. "i!! <opt> <ID> 1. gcc )g**+ <so,rce> 3. g-ip <&i!e> 4. mai! )pine+ 5. te!net <'ost> ss' <'ost> #7. &tp <'ost> nc&tp <'ost/director .>
-. .ta!" <,ser0p!a ce> .. 'istor. 0. &ort,ne 1. date 3. ca! <mo> <.r> 4. e.es 5. ca!c #7. mpage <opt> <&i!e>
!talk dh!att@thr eat histor! fortune date cal 5 '777 xe!es B xcalc B mpage $4 file# | lpr
&ists commands !ou,ve done recentl! Print random humerous message Print out current date Print calendar for 6eptember '777 =eep track of cursor (in :background:) *alculator (:background: process) Print 4 pages on a single sheet and send to printer (the font will be smallC)
0. &o!d 1. tar
Print s!stem usage and top resource hogs Jow to 9uit a UNIX shell.