Files reappearing on server even after getting deleted

I am deleting files (wordpress theme files )of my website to the server using cPanel, but still the files are reappearing. The files have a 000 permissions set.

It is strange that files have proper permissions ( i.e. 777) when they are on my local machine, but on uploading they are getting changed to 000. Do you think the site is infected by virus ? I run an Anti-Virus scan, and found none.

Read More

Any reason why this may be happening?

Related posts

Leave a Reply

5 comments

  1. chmod 000 denies read, write, and execute permission to yourself, your group, and everyone else.

    How are the files uploaded to the server? Your FTP program might me screwing up the files when they are uploaded.

    If you have root access you should be able to remove using $ rm -rf filename

    Edit

    The Umask settings on your server are not right. Setting Umask to 777 will make permissions 000.

    If you have shell access you can check for 777 Umask values by running: grep 'umask 777' /etc/skel/.bashrc

    If you find anything change the Umask to 022. If you don’t have shell access your host should be able to fix this for you.

    Instead of using the cpanel uploader use a an FTP program like Transmit for Mac or Core FTP Pro for windows and make sure to always use SFTP which is encrypted instead of FTP.

  2. If you have the option, use FTP to manage your server files. It’s more reliable than any web-based client.

    If not, try changing permissions through cPanel to 777 before deleting them. If you are unable to do that, then contact the server administrator to resolve the issue (since it looks like a server/cpanel misconfiguraiton).

  3. This is caused by the server recreating folders because you have subdomains or email addresses still attached to the domains related to those folders. Delete the subdomains and emails related to them and those folders will stay deleted.Happened to me before 🙂
    Tim

  4. This may just work for other users who don’t know how to do the techies, or who don’t have shell access:

    1. Check to see whether what you want to delete is a FOLDER or a FILE
    2. If it is a FOLDER, check the permissions on that FOLDER and change to 755, do the same if it a FILE and simply delete
    3. The issue here is that you have to open the FOLDER and CHANGE ALL SUBFOLDERS and FILES inside it to permission settings 755.
    4. Delete the files from the inside of the SUBFOLDERS out then to the FOLDERS

    This should perhaps help someone.