mkdir command stands for make directory allows the user to create an empty directory on Linux operating system. This command can also create multiple folders at once as well as set permissions for folders. Of course, pay attention to the permission to create the user’s directory when standing in the parent directory or not? Otherwise, you will get an error message about permission denied.
Here at Ibmi Media, as part of our Server Management Services, we regularly help our Customers to perform related Linux system commands queries.
In this context, we shall look into how to use the mkdir command through several examples.
It's syntax is give below:
$ mkdir [options] name
For example, We will create a directory named linuxapt:
$ mkdir linuxapt
Now, if this directory have files then you can list them with the ls command:
$ ls
Its options is given below:
This article covers how to use the mkdir command with some examples. In fact, The mkdir command in Linux/Unix allows users to create or make new directories. mkdir stands for "make directory". With mkdir, you can also set permissions, create multiple directories (folders) at once, and much more.