Welcome guest


mkdir - Make Directory

You should remember that a directory is a special file that can contain other files and directories, used to organized related files. At times, you will probably be required to do some assignments using the computers on campus which will most likely generate files. In order to keep your home directory from becoming too cluttered, you can create directories in which to keep your work. The command that will let you create and name a directory in Linux is called mkdir (make directory).

Syntax

eos% mkdir directorypath

Example

How would you make a directory in (under) your home directory called MyE115?

Ask yourself:

Q: What am I doing? A: Making a directory.
Q: How do I do that? A: Using the mkdir command.
Q: What are the path names? A: I am in my home directory ("~/"). It will be named MyE115 and is going in ~/

mkdir on the File Tree

If you had been located somewhere else on the file tree, such as in the info directory, and wanted to make a directory in your home directory called MyE115, you would have to type one of the following:

eos% mkdir /afs/unity.ncsu.edu/users/y/yourhome/MyE115
eos% mkdir ~/MyE115