Techcuriosity
Resources
Free Tutorials
 
 
 
Linux Tutorials
• About Linux
• Linux Vs Windows
• Linux File Permissions
• Linux Directory Structure
• Linux Basic Commands
• Advanced Permissions in Linux
• Linux Server Admin Commands
• Semaphores in Linux
 
Linux Commands Glossary
 
• Linux Commands Glossary - Index
• Linux Commands A
• Linux Commands B
• Linux Commands C
• Linux Commands D
• Linux Commands E
• Linux Commands F
• Linux Commands G
• Linux Commands H
• Linux Commands I
• Linux Commands J
• Linux Commands K
• Linux Commands L
• Linux Commands M
• Linux Commands N
• Linux Commands O
• Linux Commands P
• Linux Commands Q
• Linux Commands R
• Linux Commands S
• Linux Commands T
• Linux Commands U
• Linux Commands V
• Linux Commands W
• Linux Commands X
• Linux Commands Y
• Linux Commands Z
 
Linux Articles
• Difference between Hard Link and Soft Link in Linux
 
Other Tutorials
• Exim Tutorials
• FTP Tutorials
• MySQL Tutorials
• Linux Tutorials
• Shell Scripting Tutorials
• Web Hosting Tutorials
 
Web Designing Tutorials
 
• HTML Tutorials
• Perl Tutorials
• Web Templates Editing Tutorials
 
Bio Tutorials
• BioInformatics Tutorials
• Perl Scripts Library
 
Curiosity Topics
• Online Data Security
• VDS Technology
• How Website Works?
• About Hacking
 
 
Home   |   About us   |   Services   |   Forum   |   Articles   |   Tutorials   |   Contact us
 


Gateway to End all your Curiosities in Information Technology and Bio-Informatics!!.. FREE turorials for Linux, Web designing, Web template Editing, Operating systems, New technology, Bioinformatics, Bioinformatics perl scripts, Clinical research and much more curious topics you need to know.  
Your IP address is: 38.107.191.109


Allwebco Website Templates

Find more Info related to your curiosities @ our FORUM


Linux Basic Commands

Linux operating system has a beautiful graphical interface which most of us will be using. It will be good to learn the basic commands in Linux to work interactively with the Linux operating system. Linux has a back end access know as shell. You can control and activate all the process in Linux from the shell. So it is very important to learn few basic commands to work with Linux operating system.
 
 First we will learn how to login for shell access. There are 7 terminals for Linux. 6 terminals are non - GUI and 1 terminal for GUI access. You can login to each terminal using Alt + Ctrl + F1 , F2, .. F7. Each terminals will request your username and password for login. If you want to use the shell in the graphical interface (GUI), press Alt + F2 and type "konsole". As a user you will have permission to access only your /home/user directory and other directories in it.
 
 *Note: user denotes the username.

 

Basic commands in Linux

linux

Navigation Commands - [ pwd, cd ]

pwd
 This command is used to find the current location or current working directory.
 
 Eg:
 [user@ws26 ~]$ pwd
 /home/user
 
 
cd
 This command id used to change the directory. You can move from one directory to another using this command. Few examples are given below.
 
 Concider you have a directory structure /home/user/test/test1/ . test and test1 are directories in user home.
 
 Example 1:
 Consider you have a directory "test" in /home/user. Your current working directory is /home/user. You want to change your current working directory from /home/user to /home/user/test, use the following command
 [user@ws26 ~]$ pwd
 /home/user
 [user@ws26 ~]$ cd test
 [user@ws26 ~]$ pwd
 /home/user/test
 
 Example 2:
 If you want to move back to /home/user, use the following command
 [user@ws26 ~]$ cd ..
 [user@ws26 ~]$ pwd
 /home/user
 
 Example 3:
 To get back to the home directory of the user
 [user@ws26 ~]$ cd ~
 [user@ws26 ~]$ pwd
 /home/user.

Listing contents in a directory - [ ls, ls -l, ll ]

ls
 This command is used to list all the files and directory in the current directory.
 
 Eg:
 [user@ws26 ~]$ ls
 1152696870.jpg book OperaDownloads snapshot52.png
 image300.jpg Desktop test spiderman2.jpg
 
 
ls -l or ll
 This command is also used to list all the files and directories. Here you will get more details about the files and directories present in the current directory. You will see the permission set, creation date, file / directory size etc.
 
 Eg:
 [user@ws26 ~]$ ls -l
 total 5
 -rw-rw-r-- 1 user user 33188 Dec 22 02:56 1152696870.jpg
 -rw-rw-r-- 1 user user 17647 Aug 19 2006 534458.gif
 -rw-rw-r-- 1 user user 26817 Aug 19 2006 534477.gif
 drwxrwxr-x 2 user user 4096 Jan 13 04:20 book
 drwx------ 3 user user 4096 Feb 4 02:34 Desktop

Reading files in Linux - [ cat, more, less ]

Cat
 This command is used to display the contents of a file. You can read the file contents using the cat command.
 
 Example:
 [user@ws26 ~]$ cat testfile
 this is a test file.. You can read me..
 
 
 
Less and More
 Both the less and more commands serve similar function. They are used to display file one screen at a time. You can press spacebar to continue reading the file. These commands are mainly used while reading large files.
 
 Example 1:
 [user@ws26 ~]$ less testfile
 this is a test file.. You can read me..
 
 Example 2:
 [user@ws26 ~]$ more testfile
 this is a test file.. You can read me..

Manipulating files - [ cp, mv, rm, mkdir ]

cp
 This command is used to copy files/directory.
 
 Example:
 [user@ws26 ~]$ cp file1 directory1
 This will copy the file1 into the directory1
 
 
cp -R
 This command is used to copy directories recursively (copy all the files and folders inside the directory).
 
 Example:
 [user@ws26 ~]$ cp directory2 directory1
 This will copy the whole directory2 into directory1
 
 
mv
 This command is used to move the file or directory.
 
 Example:
 [user@ws26 ~]$ mv directory2 directory1
 This will move the whole directory2 into directory1
 
 
rm
 This command is used to remove or delete files and directories.
 
 Example:
 [user@ws26 ~]$ rm directory2
 This will delete the directory - directory2
 
 
mkdir
 This command is used to create a new directory
 
 Example:
 [user@ws26 ~]$ mkdir directory3
 This will create a new directory - directory3.

create new file in Linux - vi editor

The Vi editor is mainly used to create new files in Linux.

Example:
vi testfile
The command will open a new window and you can insert text to it. To begin press "i". After adding your contect press ":wq" to save the file.

<< Previous    |     Next >>
 
© TechCuriosity.com 2006 - 2007. All Rights Reserved.
Designed and Maintained by Telson Thomas
Techcuriosity
Website News
Sponsored Links
• Allwebco Website Templates
• Flash Templates
• Web Templates
• Flash Templates store
• Free website templates
• Free Flash Templates
• Web Hosting
• Dedicated Server
 
• Advertise Here
 
Help us in our Mission
 
Twitter 
Our Network Sites
• Web Hosting Solutions
• SEO and Link Directory
 
Free Tutorials
• HTML Tutorial
• PERL Tutorial
• Exim Commands
• MySQL Commands
• FTP Commands
• Shell Scripting Tutorial
 
Member Login
Username:

Password:

 
Search for Curiosity
 
 
 
Forum Curiosity Topics
• Forum Index
• Operating System's
• Web Hosting
• Programming
• Bioinformatics
• Biology & Bio-Technology
• Computer Security
• Hacking
• General Curiosity
• Jobs
 
Newsletter Signup
 
Subscribe
 
 
• Link Directory
• SiteMap