Read this whole guide offline with no ads, for a very low price!
Click Here!

Custom Search







Table Of Contents  CertiGuide to A+ (A+ 4 Real)
 9  Chapter 5: The Linux Operating System
      9  Basic Concepts and Procedures for Creating, Viewing and Editing Files and Directories
           9  Common Commands

Previous Topic/Section
ls - List  Directory Contents
Previous Page
Pages in Current Topic/Section
1
Next Page
pwd - Print Name Of Current/Working Directory
Next Topic/Section

mkdir - Make Directories Command

The make directory command is very simple in its structure and concept simply type:

mkdir directory_name

and a directory within the current directory will be created with the name directory_name. This can be verified using the ls -l command to see the results and noting the d is in the leftmost position of the permissions area as shown:

drwxrwxr-x 2 phil phil 4096 Jun 9 04:22 directory_name

Please notice that this new directory is referred to as a directory as opposed to a sub-directory. Although technically it is a sub directory, clearly when one gets several levels down to refer to a sub sub sub sub directory can be very confusing so in general directories are referred to as directories whether they are within a directory or at the root level.

If you need to create a directory within a directory use:

mkdir dir_one/new_dir

However, the directory new_dir will only be created if the directory dir_one already exists. Using the -p option will cause the dir_one directory to be created if it does not exist followed by the creation of the new_dir directory.


Previous Topic/Section
ls - List  Directory Contents
Previous Page
Pages in Current Topic/Section
1
Next Page
pwd - Print Name Of Current/Working Directory
Next Topic/Section

If you find CertiGuide.com useful, please consider making a small Paypal donation to help the site, using one of the buttons below. You can also donate a custom amount using the far right button (not less than $1 please, or PayPal gets most/all of your money!) In lieu of a larger donation, you may wish to consider buying an inexpensive PDF equivalent of the CertiGuide to A+ (A+ 4 Real) from StudyExam4Less.com. Thanks for your support!
Donate $2
Donate $5
Donate $10
Donate $20
Donate $30
Donate: $



Home - Table Of Contents - Contact Us

CertiGuide to A+ (A+ 4 Real) (http://www.CertiGuide.com/apfr/) on CertiGuide.com
Version 1.0 - Version Date: March 29, 2005

Adapted with permission from a work created by Tcat Houser et al.
CertiGuide.com Version Copyright 2005 Charles M. Kozierok. All Rights Reserved.
Not responsible for any loss resulting from the use of this site.