Indiana University
University Information Technology Services
  
What are archived documents?
Login>>
Login

Login is for authorized groups (e.g., UITS, OVPIT, and TCC) that need access to specialized Knowledge Base documents. Otherwise, simply use the Knowledge Base without logging in.

Close

In Unix, how do I create a new directory?

To create a subdirectory in the home directory of your Unix account, use the mkdir command. For example, to create a subdirectory called work, at the Unix prompt from within your home directory, enter: mkdir work The mkdir command requires at least one argument and will take multiple arguments. To create three directories named work, programs, and reports, enter: mkdir work programs reports If you're currently in your home directory and you want to make a new directory in another directory, you don't need to use the cd command first. You may specify a pathname with the mkdir command, for example: mkdir bin/work The mkdir command in conjunction with the  -p  option creates the directories specified in a path. This is very useful when you want to make a directory structure that is several directories deep, and none of the subdirectories exist yet. For example, the following command will create the work, work/programs, work/programs/reports, and work/programs/reports/completed subdirectories: mkdir -p work/programs/reports/completed Without the  -p  option, this command would have returned an error.

For more information on the mkdir command, see the online manual. At the Unix shell prompt, enter: man mkdir

At Indiana University, for personal or departmental Linux or Unix systems support, see At IU, how do I get support for Linux or Unix?

This is document abng in domain all.
Last modified on August 22, 2008.

Comments/Questions/Corrections

Use this form to offer suggestions, corrections, and additions to the Knowledge Base. We welcome your input!

If you are affiliated with Indiana University and would like assistance with a specific computing problem, please use the Ask a Consultant form, or contact your campus Support Center.

Contact Information

Note: We will reply to your comment at this address. If your message concerns a problem receiving email, please enter an alternate email address.