New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
Question about a Tail -f baash command
Tail -f file.name lists the last 10 entries in the file specified as far as I know. Is it possible to exclude certain lines from being displayed?
I'm watching my site's visit log and most of my logs are unfortunately my ips. How could I stop tail from showing my ips?
I've got 5 IP-s I want to block:
my home ip
my server ipv6
my window's server's ipv6
my window's server's ipv4
my amazon server's ipv4
My server's IP show up I assume when wordpress is doing its pinging and caching and so on.
Windows and amazon servers are connected via owncloud desktop clients, so I see them making connections in tail -f.
Thanks!
Comments
What about:
tail -f AccessLog | grep -v '1.2.3.4|2.3.4.5|3.4.5.6'
What markTurner said, use grep.
Doesn't seem to work on Ubuntu 14.04
tail -f /path/to/wordpress.access.log | grep -v '1.2.3.4|5.6.7.8|1234:5678:500:1234:f33f:abcd:745:1234|1234:1234:1:12::12:1234|7.8.9.0'
Stupid Cloudflare has removed my slashes
It should say:
'1.2.3.4BACKSLASH|2.3.4.5BACKSLASH|3.4.5.6'
The word backslash change to the symbol \
Damn man I'm really pissed off at you, it actually worked
.
And I agree on cloudflare, it's an annoyance and don't think it solves anything on lowendsqldump.
You seems to know nothing about what's happen after you click "Post Comment". So shy how much members called "Provider" here can only put advertisements in signatures; but when it comes to some knowledge - just nothing. Why do you think that's not lowendtalk CMS (Vanilla)?
Did you try to put it in "code" tags?
tail -f AccessLog | grep -v '1.2.3.4\|2.3.4.5\|3.4.5.6'
LOL
The issue has been solved, thanks.