LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   how to monitor specific ip address in squid access.log (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-monitor-specific-ip-address-in-squid-access-log-815331/)

struggled_newbie 06-20-2010 08:30 PM

how to monitor specific ip address in squid access.log
 
hello linux gurus

I'm trying the tail -f 172.16.X.XX /var/log/squid/access.log
to view the sites requested by the client ip 172.16.X.XX but the result is
it still open all the ip's requesting for the internet access.

is there any tail commands that can monitor only the specific IP address requesting for internet access.

to the moderator(tinkster)/owner: sorry for my impatience

scheidel21 06-21-2010 09:46 AM

pipe the output of tail -f to grep and use grep to filter the results. Like tail -f /var/log/squid/access.log | grep 172.16.*.*

struggled_newbie 06-21-2010 07:05 PM

Quote:

Originally Posted by scheidel21 (Post 4010265)
pipe the output of tail -f to grep and use grep to filter the results. Like tail -f /var/log/squid/access.log | grep 172.16.*.*

thanks... it works on me


All times are GMT -5. The time now is 12:02 AM.