Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

SOLVED Transfer tool symlinks

Discussion in 'General Discussion' started by carock, Mar 30, 2018.

Tags:
  1. carock

    carock Well-Known Member

    Joined:
    Sep 25, 2002
    Messages:
    245
    Likes Received:
    5
    Trophy Points:
    168
    Location:
    St. Charles, MO
    Is there a way to get the transfer tool not to follow symlinks when copying an account?

    I have a symlink in a home directory that make the transfer fail because it thinks there isn't enough room on the destination server.

    Thanks,
    Chuck
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,711
    Likes Received:
    1,794
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hi @carock,

    Could you provide an example of how the symbolic link is configured? For instance, which path is it linked to? Also, what's the specific section of the transfer log where it's showing the symbolic link is leading to the quota issue?

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. carock

    carock Well-Known Member

    Joined:
    Sep 25, 2002
    Messages:
    245
    Likes Received:
    5
    Trophy Points:
    168
    Location:
    St. Charles, MO
    Here's the directory structure and sizes

    Code:
    endor2(178):[/home/clouddemo]-#ll
    total 11848K
    drwx--x--x  14 clouddemo clouddemo     4096 Feb 26 14:08 ./
    drwx--x--x. 12 root    root            4096 Mar 30 10:57 ../
    lrwxrwxrwx   1 clouddemo clouddemo       33 Jan 25 10:56 access-logs -> /usr/local/apache/domlogs/clouddemo/
    -rw-------   1 clouddemo clouddemo      611 Jan 31 10:31 .bash_history
    -rw-r--r--   1 clouddemo clouddemo       18 Jan 25 10:43 .bash_logout
    -rw-r--r--   1 clouddemo clouddemo      176 Jan 25 10:43 .bash_profile
    -rw-r--r--   1 clouddemo clouddemo      124 Jan 25 10:43 .bashrc
    lrwxrwxrwx   1 root    root              26 Feb  6 14:27 dist -> /storage/dist/files/
    -rw-r-----   1 clouddemo clouddemo       21 Jan 25 10:43 .contactemail
    drwx------   4 clouddemo clouddemo     4096 Mar 30 10:48 .cpanel/
    drwx------   4 clouddemo clouddemo     4096 Jan 25 10:43 .cphorde/
    -rw-rw-r--   1 clouddemo clouddemo       14 Jan 25 15:46 .dns
    drwxr-x---   3 clouddemo mail          4096 Jan 25 10:55 etc/
    -rw-r--r--   1 clouddemo clouddemo 12029794 Jan 25 10:47 clouddemo_2017_09_25_PHP70.zip
    -rw-------   1 clouddemo clouddemo      288 Feb 26 15:18 .history
    drwxr-x---   2 clouddemo clouddemo     4096 Jan 25 10:43 .htpasswds/
    -rw-------   1 clouddemo clouddemo       40 Jan 25 10:55 .lastlogin
    -rw-------   1 clouddemo clouddemo       43 Jan 25 15:56 .lesshst
    drwx------   2 clouddemo clouddemo     4096 Mar 14 07:15 logs/
    drwxr-x--x  10 clouddemo clouddemo     4096 Jan 25 10:43 mail/
    drwxrwxr-x   4 clouddemo clouddemo     4096 Jan 25 10:46 perl5/
    drwxr-x---   3 clouddemo clouddemo     4096 Jan 25 10:43 public_ftp/
    drwxr-x---  21 clouddemo clouddemo     4096 Feb 23 13:55 public_html/
    drwx------   2 clouddemo clouddemo     4096 Feb 26 14:08 .ssh/
    drwxr-xr-x   5 clouddemo clouddemo     4096 Jan 31 15:30 ssl/
    -rw-rw-r--   1 clouddemo clouddemo     1271 Jan 31 10:31 .tcshrc
    drwxr-xr-x   7 clouddemo clouddemo     4096 Jan 26 06:07 tmp/
    lrwxrwxrwx   1 clouddemo clouddemo       11 Jan 25 10:43 www -> public_html/
    -rw-r--r--   1 clouddemo clouddemo      658 Jan 25 10:43 .zshrc
    
    endor2(179):[/home/clouddemo]-#du -sh public_html/
    4.1G    public_html/
    
    endor2(182):[/home]-#du -sh clouddemo/
    4.1G    clouddemo/
    
    Filesystem       1K-blocks        Used   Available Use% Mounted on
    /dev/sdb1      7687113260K 1837194020K 5459429640K  26% /storage
    
    
    I found nothing in the transfer log about the symlink specifically, just these items.

    {"contents":{"action":"queue_size","msg":1762593592321,"queue":"TRANSFER","child_number":0},"partial":0,"type":"control","pid":20135,"indent":0}

    {"pid":20136,"indent":0,"partial":0,"type":"control","contents":{"local_item":"clouddemo","queue":"TRANSFER","msg":{"failure":"Insufficient disk space is available. “/h
    ome” on host “cloud1.tech.com” has 367.4 GB free and requires at least 1.6 TB free, which includes space for temporary files.","altered_items":0,"dangerous_ite
    ms":0,"size":1762593592320,"warnings":0,"contents":{"altered_items":null,"dangerous_items":null,"warnings":null,"skipped_items":null},"skipped_items":0},"item_name":"
    Account","item":"clouddemo","logfile":"item-TRANSFER_AccountRemoteRoot_clouddemo","child_number":1,"item_type":"AccountRemoteRoot","action":"failed-item"}}

    So you can see from the du output, the entire home directory is only 4.1 Gig, but the transfer wants to copy 1.7 Tb

    Chuck
     
  4. carock

    carock Well-Known Member

    Joined:
    Sep 25, 2002
    Messages:
    245
    Likes Received:
    5
    Trophy Points:
    168
    Location:
    St. Charles, MO
    I figured it out.

    Basically, it doesn't really matter where the files are on the server, or if the filesystem has quotas on or off.

    The fixquotas script is what calculates the disk used in the cPanel accounts and scans all mounted filesystems for anything with that username as the owner.

    The only way I could get the disk usage to only use the /home/<username> folder was to unmount the /storage filesystem and run the fixquotas script.

    This way, the script could add any files with owned by that user on that filesystem.

    Another workaround could also be done by changing the owner of those files in question to another user temporarily and running the fixquotas script again.

    Chuck
     
    cPanelMichael likes this.
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice