Note : This is all regarding Linux and free software, as that's what I mostly use, but you should be fine with a syslog client on Windows to send the logs to a Linux syslog server.
Logging to an SQL server:
With only ~30 machines, you should be fine with pretty much any centralised syslog-alike and an SQL backend. I use syslog-ng and MySQL on Linux for this very thing.
Pretty frontends for graphing are the main problem -- It seems that there is a lot of hacked-up front-ends which will grab items from the logs and show how many hits, alerts etc but I've not found anything integrated and clean. Admittedly this is the main thing that you're looking for... (If I find anything good then I'll update this section!)
Alerting: I use SEC on a Linux server to find bad things happening in the logs and alert me via various methods. It's incredibly flexible and not as clicky as Splunk. There's a nice tutorial here which guides through a lot of the possible features.
I also use Nagios for graphs of various stats and some alerting which I don't get from the logs (such as when services are down etc). This can be easily customized to add graphs of anything you like. I have added graphs of items such as the number of hits made to an http server, by having the agent use the check_logfiles plugin to count the number of hits in the logs (it saves the position it gets up to for each check period).
Overall, it depends on how much your time will cost to set this up, as there are many options which you can use but they aren't as integrated as Splunk and will probably require more effort to get doing what you want. The Nagios graphs are straightforward to set up but don't give you historical data from before you add the graph, whereas with Splunk (and presumably other front-ends) you can look back at the past logs and graph things you've only just thought of to look at from them.
Note also that the SQL database format and indexing will have a huge effect on the speed of queries, so your idea of fulltext indexing will make a tremendous increase to the speed of searches. I'm not sure if MySQL or PostgreSQL will do something similar.
Edit : MySQL will do fulltext indexing, but only on MyISAM tables prior to MySQL 5.6. In 5.6 Support was added for InnoDB.
Edit: Postgresql can do full text search of course: http://www.postgresql.org/docs/9.0/static/textsearch.html
You could do something like this:
tail -f logfile | grep -v "some\.ip\.address\.to\.ignore"
or
tail -f logfile | grep -v "some\.ip\.address\.to\.ignore.*user-name"
Best Answer
If the log files are being generated on the client server via the
syslog
facility then the best way is to setup the clients syslog daemon to forward those logs to a seperate host. For example, if I have an internal namesyslog.private
which points to the remote server that I want to receive the log entries. I can add the following line to the/etc/syslog.conf
on the client server.and then restart the syslog daemon on the client
This will cause every entry that passes through the clients syslog to be sent across the wire to
syslog.private
and if that machine is configured correctly, the entries will be available there as well. In RedHat systems this is controlled by the/etc/sysconfig/syslog
file. Make sure the-r
option is presentand then restart the syslog daemon on the receiving server.
You can also control what is forwarded to the remote server by adding exclusions, see the example below
Which says forward everything to
syslog.private
with the exception of anything sent to themail
facility.If this solution works out for you, you may consider one of the alternate syslog implementations like rsyslog, or syslog-ng, which provide extra logging and storage options.