Professional Documents
Culture Documents
Unix Tutorial 08
Unix Tutorial 08
operating system
Developed at AT&T Bell Labs in the 1960s
Command Line Interpreter
GUIs (Window systems) are now available
Linux
is open source
Most of the machines youll use in the
Bioinformatics program are running the
Linux OS
is free
Its fully customizable
Its stable (i.e. it almost never crashes)
These
up a terminal:
up a terminal:
The prompt
The host
Shell
Help!
Whenever
Help!
Help!
Help!
/home/mary/
/home/john/portfolio/
The Path
Command: pwd
To find
Command: cd
To change
Command: cd
Command: cd
..
Command: ls
To list
Command: ls
ls
man
Command: ls -ltr
List
General Syntax: *
*
Command: mkdir
To create
Command: rmdir
To remove
1)
2)
3)
nano / pico
vi
emacs
use ctrl-x
Displaying a file
Various
cat
less
head
tail
Command: cat
Dumps an entire file to standard output
Good for displaying short, simple files
Command: less
Command: head
head
Command: head
Heres
Command: tail
Same
File Commands
Copying
a file: cp
Move or rename a file: mv
Remove a file: rm
Command: cp
To copy
a file use cp
Command: mv
To move
Command: mv
mv
Command: rm
To remove
a file use rm
Command: rm
To remove
a file recursively: rm r
Used to remove all files and directories
Be very careful, deletions are permanent
in Unix/Linux
File permissions
Each
Permission levels
r
File Permissions
User (you)
File Permissions
Group
File Permissions
The World
Command: chmod
If you own the file, you can change its permissions with
chmod
Syntax: chmod [user/group/others/all]+[permission] [file(s)]
Ending a program
To end
Command: ps
To view
Command: top
To view
Command: kill
To terminate
program_a
> file.txt
Command: wc
To count
Command: grep
To search
Command: diff
To compare
diff
Try:
ssh, scp
Try:
beginners
http://en.wikipedia.org/wiki/Unix