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.

Last Login question

Discussion in 'General Discussion' started by pawan.rote, Sep 20, 2011.

  1. pawan.rote

    pawan.rote Member

    Joined:
    Jul 28, 2011
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    How can I identify customers who are not using their web hosting account since long. The duration may be more than 30 days. Alternatively I want to know Where can I view last login (date) in cpanel.

    I know we can view Last Login From but I real interest in getting the date.
     
  2. cPanelTristan

    cPanelTristan Quality Assurance Analyst
    Staff Member

    Joined:
    Oct 2, 2010
    Messages:
    7,623
    Likes Received:
    21
    Trophy Points:
    38
    Location:
    somewhere over the rainbow
    cPanel Access Level:
    Root Administrator
    This will get you the last modification time on those files but it doesn't include the file name:

    Code:
    stat /home/*/.lastlogin | grep -i modify
    This will go alphabetically by files found by that name.
     
  3. pawan.rote

    pawan.rote Member

    Joined:
    Jul 28, 2011
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    I also want to know the last login in to wordpress and web based email for each customer. Is it stored somewhere in cPanel database? what are possible ways to get the last login details of each customer.
     
  4. cPanelJared

    cPanelJared Technical Analyst
    Staff Member

    Joined:
    Feb 25, 2010
    Messages:
    1,842
    Likes Received:
    18
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    This would be a WordPress issue, and would have nothing to do with cPanel. cPanel does not track log-ins to site software such as WordPress. I did a quick Google search on "wordpress last login" and it looks like there is a plug-in that will do this:

    WordPress › WordPress Last Login « WordPress Plugins
     
  5. cPanelJared

    cPanelJared Technical Analyst
    Staff Member

    Joined:
    Feb 25, 2010
    Messages:
    1,842
    Likes Received:
    18
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    I apologize that I overlooked this part of your question. Access to Webmail is logged in the file /usr/local/cpanel/logs/access_log. The data are stored in Apache-style format, with timestamps, source IP address, browser used, and other data. There is no way to view this file from the WebHost Manager. You will need to log into the server as root via SSH and use commands like vi, grep, cat, tail and head to view the file.

    Access to all areas of cPanel, including the WebHost Manager, is logged to the same file.
     
  6. pawan.rote

    pawan.rote Member

    Joined:
    Jul 28, 2011
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    I appreciate your quick response, Thanks a lot.
     
Loading...

Share This Page