Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Look up keyword or section
Like this
5Activity
P. 1
unix commands

unix commands

Ratings:

4.5

(4)
|Views: 138|Likes:
Published by vijayer
Unix Commands
Unix Commands

More info:

Categories:Types, School Work
Published by: vijayer on Nov 03, 2008
Copyright:Public Domain

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as DOC, PDF, TXT or read online from Scribd
See more
See less

06/13/2013

pdf

text

original

 
UNIX Commands
To Create a File:Syntax: $ cat [option] > <filename>
Ex: $ cat > file1Hello..This is my first FileHave a Nice DayBye
Ctrl+d (Save)
Ctrl+d – Possible Completer Ctrl+c – Cancel foreground JobCtrl+z – Stop (interrupted) a foreground Job
To View a already existing File:Syntax: $ cat <filename>
Ex: $ cat file1
To append data to an existing fileSyntax: $ cat >> <filename>
Ex: $ cat >> file1
To Create a Multiple file with help of cat commandSyntax: $ cat <filename1 filename2 ...filename (n) >
Ex: $ cat >f1 >f2 >f3 >f4Hello....This is file number f4We create multiple files^d (Save)
Display the record number to the particular fileSyntax: $ cat [option] <filename>
Ex: $ cat -n file1
To ignore the blank RecordsSyntax: $ cat [option] <filename>
Ex: $ cat -b file1
Vijay Kumar E R – 98486 11007
1
 
Create a Hidden fileSyntax: $ cat [option] <filename>
Ex: $ cat >.file1
Create a DirectorySyntax: $ mkdir [option] <Directory name>
Ex: $mkdir raju
Create Multiple DirectoriesSyntax: $ mkdir [option] <Directory names>
Ex: $ mkdir d1 d2 d3 d4 d5
Create Multi – level DirectoriesSyntax: $ mkdir [option] <Directory names>
Ex: $ mkdir –p /d5/d51/d52/d53
Create Multiple Sub directoriesSyntax: $ mkdir [option] <Directory nam
 
es>
Ex: $ mkdir –p d3/d31 d4/d41
To Display present working DirectorySyntax: $ pwd
Ex: $ pwd
To Change the DirectorySyntax: $ cd <Directory name>
Ex: $ cd raju
To change the directory forwardSyntax: $ cd..
Ex: $ cd..
To Move parent Directory (root)Syntax: $ cd /
Ex: $ cd /
To Create a Hidden DirectorySyntax: $ mkdir [option] <Directory name>
Ex: $ mkdir .venkat
Vijay Kumar E R – 98486 11007
2
 
REMOVE COMMANDS:
To Remove a fileSyntax; $ rm [option] <filename>
Ex: $ rm kiran
To Remove Multiple FilesSyntax: $ rm [option] <filenames >
Ex: $ rm f1 f2 f3 f4
To remove files ForciblySyntax: $ rm [option] <filename>
Ex: $ rm -f kiran
To Remove Interactive ModeSyntax: $ rm [option] <filename>
Ex: $ rm -i kiran
To Remove DirectorySyntax: $ rm
 
[option] <Directory Name>
Ex: $ rm sagar
To Remove all Directories and subdirectoriesSyntax: $ rm [option] <Directory Name>
Ex: $ rm -r sagar
To Remove Directories ForciblySyntax; $ rm [option] <Directory Name>
Ex: $ rm -rf sagarEx: $ rm -rf sagar pavan amar
To Remove Directories InteractivelySyntax; $ rm [option] <Directory Name>
Ex: $ rm -i sagarEx: $ rm -i sagar pavan amar
Vijay Kumar E R – 98486 11007
3

Activity (5)

You've already reviewed this. Edit your review.
1 hundred reads
1 thousand reads
talk2parimi liked this
wizrun liked this
adddata liked this

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->