Analyze logfile & take action, Linux Scripting

Completado Publicado Dec 18, 2013 Pagado a la entrega
Completado Pagado a la entrega

There is an application running which generates log file. We need to create some script which will check for errors in the logfile do the following:

1. Tail last 10 minutes of log file |grep only the rows which contain specific word

2. from the output we need to fetch 2 variables - "username" & "IP", as it is both variables we need to sed next words after specific patterns

3. the output will look like

user1 1.1.1.1

user2 2.2.2.2

user3 3.3.3.3

user1 1.1.1.1

user4 4.4.4.4

4. If the username exists more than "X" times in the final output take action -

ban IP for specific time &

send email to email address fetched from db mysql [url removed, login to view] where username = $user &

write some info to mysql [url removed, login to view] where username = $user

The script must be optimized, not memory or cpu hungry, will be run each 10 min in cron job, so please only experienced users who know what to do.

thank you

Linux MySQL PHP Arquitectura de software Desarrollo de software

Nº del proyecto: #5240553

Sobre el proyecto

8 propuestas Proyecto remoto Activo Dec 18, 2013

Adjudicado a:

AlxKS

Hello, I will be glad to wire a script for you. For this I will need: 1. example of log file 2. dump of database 3. Installed firewall on server (CSF, iptables, lfd?) Regards, Alex_ks

$56 USD en 0 días
(3 comentarios)
1.5

8 freelancers están ofertando un promedio de $105 por este trabajo

TonyUA

Hello I'm linux system engineer with more than 8 years of production experience, familiar with such kind of work. I can help you fast and quality. Regards, Tony

$100 USD en 2 días
(72 comentarios)
5.7
mikipeshevski

Hello, I work as a Linux/Unix system administrator for the past 10 years and have all the necessary skills and hands-on experience to complete the task. Hope to hear from you soon.

$66 USD en 1 día
(11 comentarios)
3.9
programec

PMB Please...

$230 USD en 5 días
(11 comentarios)
3.8
coskung

Hello there. I'm an experienced linux system administrator and I can write the script you need quickly and well documented. Please feel free to contact me if you've any question. Best regards.

$111 USD en 2 días
(4 comentarios)
3.2
shkerin

looks like you definitelly know what do you need, it is good for both of us. I believe I can help you, It will not be too long, I guess 1..2 days. Please give me a sample of source log. Thank you.

$111 USD en 3 días
(2 comentarios)
2.6
manthantilva

hi I am experience. programmer. I have expertise in c cpp perl Linux and kava. I can do your this work easy in perl scripting. I have also experience in mysql and familiar with cron job.

$155 USD en 3 días
(1 comentario)
2.3
goarilla

Does the logfile contain timestamps because if not the "Tail last 10 minutes of log file" is not possible. If you mean go through all the lines since last check then this can be accomplished in another way (by c Más

$40 USD en 7 días
(2 comentarios)
2.1