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!

Can you delete user/doc

Discussion in 'General Discussion' started by WebHostPro, Sep 14, 2002.

  1. WebHostPro

    WebHostPro Well-Known Member
    PartnerNOC

    Joined:
    Jul 28, 2002
    Messages:
    1,654
    Likes Received:
    15
    Trophy Points:
    318
    Location:
    LA, Costa RIca
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello,

    I filled up the user directory on a server and would like clean out as many files as I can. Repartitioning is a little too risky with the files on there.

    Not knowing what I can delete, specificly do you know if can I delete the usr/doc directory and/or any other doc type and other file types to free up space.

    I was thinking the usr/info directory as well.

    Appreciate it,

    Charles
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  2. ecoutez

    ecoutez Well-Known Member

    Joined:
    May 23, 2002
    Messages:
    152
    Likes Received:
    0
    Trophy Points:
    316
    /usr/doc probably won't help you much. Mine is under 10MB on all my boxes.

    You're probably using up space with Apache domain logs. Consider moving the files from /usr/local/apache/domlogs to another partition. See how much space these are taking up (du -h -s /usr/local/apache/domlogs) and see if you have this room on another partition (df -h). If you have a lot of available room in /var for example, you could move the files...

    1: Stop Apache from WHM
    2: make new log directory - mkdir /var/log/domlogs
    3: move content - mv /usr/local/apache/domlogs/* /var/log/domlogs/
    4: remove /usr/local/apache/domlogs directory - rmdir /usr/local/apache/domlogs
    5: add symbolic link to the new directory - ln -s /var/log/domlogs /usr/local/apache/domlogs
    6: Start Apache in WHM

    - Jason
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. WebHostPro

    WebHostPro Well-Known Member
    PartnerNOC

    Joined:
    Jul 28, 2002
    Messages:
    1,654
    Likes Received:
    15
    Trophy Points:
    318
    Location:
    LA, Costa RIca
    cPanel Access Level:
    Root Administrator
    Twitter:
    Yah that things over 200 megs, that would do it.

    Sorry for being lame here but a couple things:

    What is the link in the WHM to stop and start apache?

    In the move content command (3) Can I paste that hole line or is there more then one command there and is the * a variable or is that part of the command.

    And the last lame question :) is the last command (symbolic) is this the command that I type in to finish:

    ln -s /var/log/domlogs /usr/local/apache/domlogs

    Thanks
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. WebHostPro

    WebHostPro Well-Known Member
    PartnerNOC

    Joined:
    Jul 28, 2002
    Messages:
    1,654
    Likes Received:
    15
    Trophy Points:
    318
    Location:
    LA, Costa RIca
    cPanel Access Level:
    Root Administrator
    Twitter:
    I think I found the the link to stop apache under Service Manager - httpd (web server)
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. ecoutez

    ecoutez Well-Known Member

    Joined:
    May 23, 2002
    Messages:
    152
    Likes Received:
    0
    Trophy Points:
    316
    [quote:b0e925623a][i:b0e925623a]Originally posted by DWHS.net[/i:b0e925623a]
    In the move content command (3) Can I paste that hole line or is there more then one command there and is the * a variable or is that part of the command.

    And the last lame question :) is the last command (symbolic) is this the command that I type in to finish:

    ln -s /var/log/domlogs /usr/local/apache/domlogs
    [/quote:b0e925623a]

    It's one command - the * is a wildcard to grab ALL the log files. Type it as is. The space just seperates the source from destination for this flie move.

    Yes, that last line is the create a symbolic link. You have it right.

    - Jason
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. WebHostPro

    WebHostPro Well-Known Member
    PartnerNOC

    Joined:
    Jul 28, 2002
    Messages:
    1,654
    Likes Received:
    15
    Trophy Points:
    318
    Location:
    LA, Costa RIca
    cPanel Access Level:
    Root Administrator
    Twitter:
    Thanks for this.

    It won't let me romove the file everthing else I think is fine.

    It sais this:

    rmdir: `/usr/local/apache/domlogs': Directory not empty


    I also tried this:

    root@tangle [/usr/local/apache]# rm domlogs -d
    rm: remove directory `domlogs'? y
    rm: cannot unlink `domlogs': Is a directory
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  7. WebHostPro

    WebHostPro Well-Known Member
    PartnerNOC

    Joined:
    Jul 28, 2002
    Messages:
    1,654
    Likes Received:
    15
    Trophy Points:
    318
    Location:
    LA, Costa RIca
    cPanel Access Level:
    Root Administrator
    Twitter:
    Actually I think it worked anyways, I have more room already.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  8. ecoutez

    ecoutez Well-Known Member

    Joined:
    May 23, 2002
    Messages:
    152
    Likes Received:
    0
    Trophy Points:
    316
    It sounds like your domlogs is currently a link. Do this and make sure that it's pointing to the right place:
    ls -alF /usr/local/apache

    You should see an entry for domlogs hopefully like...
    domlogs -& /var/log/domlogs/
    or something along those lines.

    - Jason
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  9. WebHostPro

    WebHostPro Well-Known Member
    PartnerNOC

    Joined:
    Jul 28, 2002
    Messages:
    1,654
    Likes Received:
    15
    Trophy Points:
    318
    Location:
    LA, Costa RIca
    cPanel Access Level:
    Root Administrator
    Twitter:
    I think it's working fine, the old folder is only 800k now, this is the response I got from the last post if you want to look:

    total 52
    drwxr-xr-x 13 root root 4096 Sep 7 23:42 ./
    drwxr-xr-x 18 root root 4096 Sep 8 00:01 ../
    drwxr-xr-x 2 root root 4096 Sep 13 01:30 bin/
    drwxr-xr-x 2 root root 4096 Sep 7 23:34 cgi-bin/
    drwxr-xr-x 7 root root 4096 Sep 13 14:16 conf/
    drwxrwxr-x 2 root mail 4096 Sep 13 15:01 domlogs/
    lrwxrwxrwx 1 root root 4 Sep 7 23:42 etc -& conf/
    drwxr-xr-x 3 root root 4096 Sep 7 23:34 htdocs/
    drwxr-xr-x 3 root root 4096 Sep 7 23:34 icons/
    drwxr-xr-x 3 root root 4096 Sep 7 23:34 include/
    drwxr-xr-x 2 root root 4096 Sep 8 00:01 libexec/
    drwxr-xr-x 2 root root 4096 Sep 13 15:13 logs/
    drwxr-xr-x 4 root root 4096 Sep 7 23:34 man/
    drwxr-xr-x 2 nobody nobody 4096 Sep 7 23:34 proxy/

    Thanks again, this worked great.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  10. ecoutez

    ecoutez Well-Known Member

    Joined:
    May 23, 2002
    Messages:
    152
    Likes Received:
    0
    Trophy Points:
    316
    Umm... it looks like it did not! You moved your old log files, and are probably now writing to new ones. This will be a problem for log analysis in Analog and Webalizer. That missing symbolic link will be a real thorn in your side.

    Send me a private message, email or find me on AIM... It shouldn't be too hard to fix, but I'm not sure I can walk you through it blindly. Happy to do it for you since I lead you down this path. ;)

    - Jason
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
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