We have 20 centos server and on each server we have 5 tomcats running. All time developer comes for logs so we are planning to keep all tomcat logs one URL so that Developer comes to that URL and check tomcat logs from there is there any way to check all server tomcat logs means catalina.out log from server or on URL
Log management is messy enough without random little scripts copying things around, maybe getting all the data in a timely manner or maybe not.
Really if you want to have centralized logging, you should have centralized logging and not little kludges hidden around for someone to forget about and then have to support after someone has quit. Do it right the first time.
Back when I would set up centralized logging in the good old days, I would use syslog-ng because it was so configurable, it would write to multiple directories/queues, set hostnames, timesync, and other goodness.
Looks like it even has corporate and multiplatform support now. Neat. The opensource freeware version should be fine for your uses.
You can do un script that make a simple
scp on all of your servers.
Something like this:
#From server where you want to store the logs: scp user@serverWithLogsToRetrieve:/path/to/logs/logName.log /local/path/to/log/logName.log
I assume your logs have date and time in their name, so you can make sure to retrieve only the logs you need, and not all.
You can also rename the retrieved log with the original server name so you can differentiate them easily. You can store them in different directories etc.
This script can be scheduled with a simple
To have it available on a website, you must have a web server (e.g. Apache), and put the logs into your site. Either directly into a directory and the browser will make the tree, or you can create a website if you want something more user friendly (logs stored by date, search tool etc).