Welcome to Centmin Mod Community
Register Now

Tracking an IP address

Discussion in 'System Administration' started by Andy, Oct 30, 2014.

  1. Andy

    Andy Active Member

    542
    89
    28
    Aug 6, 2014
    Ratings:
    +132
    Local Time:
    12:07 PM
    I'd like to look through all the activities from a specific IP address accessing my server. I like to find out the time, what url they access, etc.


    Is there a specific command line, access log, etc that I can find out? How far back the access log is kept?
     
  2. eva2000

    eva2000 Administrator Staff Member

    53,818
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:07 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Nginx logrotate is setup via lines 38 to 53 of inc/logrotate.inc on initial install and you end up with Nginx logrotate config file at /etc/logrotate.d/nginx which is configured to rotate daily and keep 10 rotations but has override setting to rotate if log file hits 100MB which takes priority over interval rotation

    Code:
    /var/log/nginx/*.log /usr/local/nginx/logs/*.log /home/nginx/domains/*/log/*.log {
            daily
            missingok
            rotate 10
            size=100M
            compress
            delaycompress
            notifempty
            postrotate
                    /sbin/service nginx restart
                   #or
                   #kill -s USR1 'cat /usr/local/nginx/logs/nginx.pid'
            endscript          
    }
    See logrotate info at Understanding logrotate utility | Knowledge Center | Rackspace Hosting
     
  3. eva2000

    eva2000 Administrator Staff Member

    53,818
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:07 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+