Results 1 to 3 of 3
  1. #1

    How to fix cPanel Transfer Script Problem with Ownership

    When you use cPanel's automatic transfer script is changes the group of the the "public_html" directory to the user owning the site. It should correctly be assigned to the "nobody" group. If it is not assigned the to "nobody" group the site will be unavailable to view even though the files are present. To fix the problem it is very simple to run the following at the command line inside the account's folder in the /home directory:

    chgrp nobody public_html

    This will transfer the ownership of the group to the web server and will fix the problem.

    However, if you have transferred multiple sites it can quickly become cumbesome to do so. So put this script in the /home directory and run. It will change all public_html directories to the nobody group and mass fix the problem.

    Code:
    #!/usr/bin/perl
    $mode = "nobody";
    @dir = <*>;
    foreach $file (@dir) {
    `chgrp $mode $file/public_html`;
    }
    Be sure to chmod the script to 755 before running. Enjoy.
    Last edited by beachtrader; 02-04-2004 at 09:16 AM.

  2. #2
    Join Date
    Jan 2001
    Location
    Illinois, USA
    Posts
    7,175
    Thanks - do you know if this "bug" is on all versions of cPanel - or has it been fixed?

  3. #3
    Anything less than 8.8 stable does not work and needs to be changed. I ran one move with 8.8 stable and it did get the permissions/ownership correct so hopefully it won't be a problem for the future.
    Richard
    Multiple Domain Hosting | See our Ad in PC Magazine
    Windows Reseller Hosting @ www.e3servers.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •