How do I reestablish system folders within a virtual server home folder?


Please read the forum post here :

  • Tim


Hi all

Does anybody know if it's possible to auto create system folders in a users virtual site if the user accidentally has deleted them? Normally the home folder consist of the following folders (including some files) awstats domains fcgi-bin logs public_html cgi-bin etc homes Maildir tmp

One of my users has somehow deleted all the folders except fcgi-bin and cgi-bin. I got an automatic mail this night telling me that the Virtualmin Validation Failed for the specific Virtual Server. Home directory : Sub-directory public_html under home directory does not exist AWstats reporting : AWstats data directory awstats does not exist

So, is there someway we can auto generate the system folders or are we in a need of a restore from backup?? Thanks in advance.


Howdy -- hmm, if the public_html folder doesn't exist, and had data in it previously -- the only way to get that back would be to restore from a backup.

Now, regarding other directories -- I'm not entirely certain of this, but you might try disabling the Apache website feature for that particular domain, and then re-enable it... does doing that cause it to re-create the other folders?

There's no easy way to automatically re-create the folders, but the validation check will tell you which ones are missing.

Hi all

So a manual re-create is needed or restore?

  • Tim

Either one of those options would work, depending on your preference... you can manually re-create them, or restore it from a backup when those paths were present.

Hi Eric

Thanks, I will try that next time I have the issue. I suspect the files in those folders will be auto created when the folders are present again?

  • Tim

Some will be. For any that aren't, you could always try changing the PHP Execution Mode to something else, and then change it back to what it is now, that should also re-create a number of those files.