Skip to content
xYnta
Go to websitexynta.com
Search
EN

Resetting file permissions on your hosting package

Updated on

If you cannot edit or delete certain files or folders, the file permissions may be wrong. Reset them to the standard: 644 for files and 755 for folders. For a single file or folder you do this in File Manager; for a whole folder with everything in it, in the DirectAdmin Terminal.

A single file or folder

  1. Log in to DirectAdmin

    Log in via Single Sign-On from Mijn xYnta, or at https://yourdomain.nl:2222.

  2. Open File Manager

    Under System Info & Files, click File Manager.

  3. Go to the right folder

    On the left, click the folder that contains the file or folder, for example domains › yourdomain.nl › public_html.

  4. Open the permissions

    Right-click the file or folder and choose Set permissions.

  5. Choose the standard

    Choose Shared file (644) for a file or Shared directory (755) for a folder, and click SAVE.

Set Permissions in DirectAdmin File Manager
Set Permissions for a folder, with the choice Shared directory (755).

A whole folder with everything in it

  1. Log in to DirectAdmin

    Log in via Single Sign-On from Mijn xYnta, or at https://yourdomain.nl:2222.

  2. Open the Terminal

    Under System Info & Files, click Terminal.

  3. Reset the permissions

    Type these two commands and press Enter after each. The first sets all folders to 755, the second all files to 644, in your website's folder and everything below it:

    find ~/domains/yourdomain.nl/public_html -type d -exec chmod 755 {} +
    find ~/domains/yourdomain.nl/public_html -type f -exec chmod 644 {} +

    If you get No such file or directory, the domain name in the command is wrong and nothing has been changed.

Then try to edit or delete the file or folder again.

Not working?
  • If Terminal is not in your menu, contact us.
  • Scripts that need to run, such as Perl scripts in cgi-bin, then need 755 again: set them one by one with Set permissions to Shared & Executable file (755).
  • A folder with a % in its name cannot be deleted.
  • If the problem persists, the permissions deeper in the folder structure may still be wrong. If resetting does not work, contact us.

Video

Resetting file permissions in DirectAdminYouTube

Related articles