Help Center Live Community

Support => Tips and Tricks => Topic started by: The Phantom on May 05, 2009, 03:30:28 PM

Title: Undeletable directories
Post by: The Phantom on May 05, 2009, 03:30:28 PM
I've moved HCL to another directory (I couldn't simply rename the old one).  However, the old directory still has two subdirectories which I cannot delete! These directories are cache and compile, and I believe that I can't delete them because their content was created by a PHP script.  I made a simple PHP script that, technically, must delete them, but it doesn't.  I've tried both removing these directoies and what's inside them (and yes, I know that Linux cannot delete an un-empty directory) - no luck.  :( So could you please provide a script that will delete them or another way of deletig them.  ??? Thx.

Title: Re: Undeletable directories
Post by: SpenserJ on May 12, 2009, 12:21:30 AM
If you have ssh access (or any command line access) then there is a simple (but dangerous, if you run it incorrectly) fix:
CD into the directory where HCL was hosted ("cd /home/account/public_html/hcl" for instance)
then remove the files forcefully and recursively... be VERY careful with this command, as it can delete your whole server!
rm -rf cache
rm -rf compile

If that throws an error about permissions, then add "sudo " infront of it, so it would be "sudo rm -rf cache"