find all ip logged into cpanel

Revision as of 09:21, 26 February 2014 by Admin (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Find all Cpanel User logins from access_log

To find all logins to cpanel by a user

grep CPANEL_USERNAME /usr/local/cpanel/logs/access_log | awk -F' ' '{print $1}' | uniq


[email protected] [~]# grep akaniorg /usr/local/cpanel/logs/access_log | awk -F' ' '{print $1}' | uniq
[email protected] [~]#

Find all Cpanel User logins from session_log

grep CPANEL_USERNAME /usr/local/cpanel/logs/session_log

Find All Cpanel Logins From An IP

To find all cpanel sites an IP logged in

grep /usr/local/cpanel/logs/access_log | awk -F' ' '{print $3}' | sort | uniq

To get list of all sites a list of IPs logged in

egrep '||' /usr/local/cpanel/logs/access_log | awk -F' ' '{print $3}' | sort | uniq