How to create directory at root level of Web directory?

  • Hi
    I need to create a folder on them same level of HTDOCS, out of it, for moodle data install

    mkdir /var/www/virtual/<domain name>/moodledata
    Operation not permitted

    I'm root user and I don't have permissions?!

    How I can create a folder on same level of HTDOCS?


  • Thanks a lot!!!
    I didn't know that this exists!!!! thanks!!! thanks!!!!

  • Hello ;

    Be aware that creating directory at root level of a web directory is considered a bad practice. To store data outside your public directory (htdocs), you should use the 00_private directory which was added specially for this purpose. Once it's done, you can always set PHP include path and/or play with your autoloader if any. For safety reasons, i-MSCP provide the Web folder protection feature using the immutable bit. This option can be disabled through the frontend.