Create a directory including parent folders
create a folder in linux | make a directory | create nested folders at once | mkdir with parents | mkdir | directory | createCaution: This command changes the system. Understand what it does before you run it.
mkdir -p -- /var/www/vhosts/example.com/private/backups/2026Creates the directory including all missing parent folders. -p also avoids an error if the directory already exists, which makes the command ideal for scripts.
Note: New folders belong to the user running the command. If created as root, the web server or the Plesk subscription may not be able to write to them.
Also searched as
- create a folder in linux
- make a directory
- create nested folders at once
- mkdir with parents