The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

FTP Accounts?

Discussion in 'General Discussion' started by nriley, Jun 20, 2008.

  1. nriley

    nriley Member

    Joined:
    Oct 22, 2007
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    I recently added a Urchin stats server to my network and want to read in the logs for some of my clients on our cpanel server. I see that there is a user_logs account that gets created with the user's password, but since we don't track user passwords that does not work for my situation.

    How can I create a global ftp account that urchin can use to then read in the logs for the various sites? I am using pure-ftpd and the way its all configured is a bit of a mystery to me.

    TIA!
     
  2. wizzy420

    wizzy420 Well-Known Member

    Joined:
    Nov 13, 2007
    Messages:
    125
    Likes Received:
    2
    Trophy Points:
    18
    If you look in /usr/local/apache/domlogs/ you will see all logs get created as owned by root, group is the username, and the other users permission is set to none.

    This means that the only one who can read the files is either the root account, or the user.

    So unless you have urchin FTP in as root I think you're not going anywhere. But I could be wrong.

    If you know the exact time that cPanel rotates the logs you could make a script to copy all the log files into a common area owned by a user you setup, and make them accessible to that one user who could FTP in. You might lose a few lines of log that way but I can't imagine much. If it takes one minute to copy the files, fire it off two minutes before the logs get cleaned out.

    W
     
  3. nriley

    nriley Member

    Joined:
    Oct 22, 2007
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    Eh that is not going to work. I definitely need to find a way to create a ftp user with the appropriate access...

    logging in as root is out of the question imo...
     
  4. wizzy420

    wizzy420 Well-Known Member

    Joined:
    Nov 13, 2007
    Messages:
    125
    Likes Received:
    2
    Trophy Points:
    18
    You could create an FTP login and put the user in every users group.

    For example if you have users smokey, mary, and jane.

    Add this FTP user to group smokey, group mary, and group jane.

    Then the FTP login can access all their log files.

    W
     
  5. nriley

    nriley Member

    Joined:
    Oct 22, 2007
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    That is more along the lines of what I was thinking, the problem is creating ftp accounts on this cpanel server from the console seems less than straightforward... I'm not really sure how to go about it. I tried using pure-pw with no luck...
     
    #5 nriley, Jun 20, 2008
    Last edited: Jun 20, 2008
Loading...

Share This Page