LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Can be done? (https://www.linuxquestions.org/questions/linux-networking-3/can-be-done-423425/)

JJX 03-10-2006 03:33 AM

Can be done?
 
I had this idea:

Is possible to create a script that will login to several linux machines (ssh) and parse the logs (using grep) and return some results?
So i will be able to keep some specific logs in one central pc.

Can this be done? Which language is suitable for something like this?
Perl can do this?

thx for any answers

uselpa 03-10-2006 03:46 AM

You can do this in bash for example, that might be the easiest to start with. The quickest way would be to copy the logs via `scp` on your machine and to parse them there.
A different approach would be to create a central syslog server and have all your machines put their logs on that server. Of course your server would need to be up all the time.
A third approach would be to use something like logwatch on the different machines and have them generate an alert in a central place.

Pick yours, depending on the amount you can wait to get the alert and the possibility of having a central log server.

JJX 03-10-2006 05:38 AM

The script will have double usage:
Checking the logs for some critical entries and executing the same commands on all 3 linux servers, reducing the time i need for administrating them.


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