Anope IRC Services

Please login or register.

Login with username, password and session length
Advanced search  

News:

Pages: [1]   Go Down

Author Topic: Syslog Support?  (Read 5717 times)

0 Members and 1 Guest are viewing this topic.

someone

  • Anope User
  • Offline Offline
  • Gender: Male
  • Posts: 42
    • http://www.somenet.org
Syslog Support?
« on: August 28, 2010, 03:52:15 PM »

Wouldnt it be easy to add syslog support instead of/additionally to logchan and logfiles?
Logged

Jobe

  • Contributor
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 1023
    • Anope IRC Services
Re: Syslog Support?
« Reply #1 on: August 29, 2010, 02:27:42 PM »

Firstly a lot of people using Anope done have access to syslog on the boxes they're using anyway, as most syslog logs are only accessible by root.

Secondly, what feature would you suggest the messages be sent to syslog as? (severity depending on the message obviously)
Logged
Your IP: ()
My IRC Status:

Come along and visit http://www.anopequotes.org/

someone

  • Anope User
  • Offline Offline
  • Gender: Male
  • Posts: 42
    • http://www.somenet.org
Re: Syslog Support?
« Reply #2 on: October 18, 2010, 12:08:20 AM »

well if one is running irc on a 50c shell server he doesnt deserve to have access to logs ;)
There are many shell providers, that give you access to logs, based on user. (syslog-ng is great for stuff like this)

it would be enought, if it was possible to set the filename of the logfiles, so you could set it to something like /dev/log or some other pipe.

I didnt understand your second question.
You can ignore severity at all - just send the data over...
newer syslogD's have regex filtering and stuff - there is no need for severity and facility levels anymore.
Logged

Taylor

  • Contributor
  • *
  • Offline Offline
  • Posts: 100
Re: Syslog Support?
« Reply #3 on: October 18, 2010, 12:21:42 AM »

Why is logchan and logfiles not enough?
Logged
Cronus
irc.cncirc.net
http://CnCIRC.net

katsklaw

  • Supporter
  • Anope User
  • Offline Offline
  • Posts: 537
Re: Syslog Support?
« Reply #4 on: October 22, 2010, 07:04:03 PM »

Tylor, he never said it wasn't enough, he's just wanting other options.

someone, sending everything maybe good enough for syslog to handle but adds more resource usage to Anope it's self. By Anope using it's own logging system it's far easier to keep control of as well as expand upon. Additionally, using internal methods cuts back on relying on external applications. Finally, your "50c shell" example is hardly accurate. Everyone deserves logs and besides the sysadmin of the shell company might not want 100 different Anope's hogging up syslog whilst important global logging needs to be done.

As far as the feature request it's self goes, I see no harm in it truthfully. Of course that would require a huge undertaking since the logging, db, core bots as well as countless other areas aren't so modular as other services packages are in these areas.
Logged

someone

  • Anope User
  • Offline Offline
  • Gender: Male
  • Posts: 42
    • http://www.somenet.org
Re: Syslog Support?
« Reply #5 on: October 25, 2010, 03:06:49 AM »

Tylor, he never said it wasn't enough, he's just wanting other options.
THIS!

someone, sending everything maybe good enough for syslog to handle but adds more resource usage to Anope it's self. By Anope using it's own logging system it's far easier to keep control of as well as expand upon. Additionally, using internal methods cuts back on relying on external applications.
DUDE!
What is faster: writing to 1) heavily used hdd, 2) moderately used hdd or 3) to ram?

So given the possibility to NAME a SINGLE logfile (which can be a named pipe to a syslogd), you could pipe ANY output directly to the syslogd (without the data ever going to a hdd)
Now if you want to tell me, that this puts more straint on the machine, than anope writing to a physical hdd, i should stop arguing as it would be as useful as explaining some people who never saw a computer, how cool the internet is.

Also the argument, its more tidy is invalid.
There is no benefit of keeping logfiles in the programs directory. Not on windows not on linux.
Actually, if anope dies, there will be logfiles, that will never get automatically deleted - oh yeah!

You can also have mutliple partitions/hdds (again, on win and on linux) having diffrent configuration for diffrent pusposes.
So it *MIGHT* be very, very ressource consuming/slow, if you are forced to write to on an allready heavy loaded hdd, instead on a moderately loaded log-hdd...

Also the external programs you are talking about are linux's (and windows) core fetures, WHY not use them?
Its like, if THEY break, the least probem you have to deal with is anope or irc...

But yes, there is not much of a benefit for windows users, as win's syslog is pretty good hidden AND hard to access.


Finally, your "50c shell" example is hardly accurate. Everyone deserves logs and besides the sysadmin of the shell company might not want 100 different Anope's hogging up syslog whilst important global logging needs to be done.
As i said: per user logfiles.
Works like a charm!

As far as the feature request it's self goes, I see no harm in it truthfully. Of course that would require a huge undertaking since the logging, db, core bots as well as countless other areas aren't so modular as other services packages are in these areas.
DUDE, NO!
*ALL* you need to change, is the function that gives the logfiles their names.
If you can define a single name, instead getting forced into a logs directory with date-appended files, you are done.

it would take like one config parameter that defaults to:
LogFileName = "logs/service.{DATE}.log"

Ppl like me could then simply change this parameter to stuff like "/dev/log" or ppl that do not want logging at all could stick with "/dev/null"

I guess we allready wrote more, than it would need to change the code ;)
« Last Edit: October 25, 2010, 03:23:02 AM by someone »
Logged

katsklaw

  • Supporter
  • Anope User
  • Offline Offline
  • Posts: 537
Re: Syslog Support?
« Reply #6 on: October 25, 2010, 05:53:19 PM »

It seems you know exactly what you are doing so instead of arguing further, perhaps you can put such elite skills to use and write a patch to do what it is you want since it's so easy and as you said have typed more than the fix. Then submit it to the Anope Team for review.
Logged

someone

  • Anope User
  • Offline Offline
  • Gender: Male
  • Posts: 42
    • http://www.somenet.org
Re: Syslog Support?
« Reply #7 on: October 30, 2010, 06:46:58 PM »

after reading your suggestion i got my git clone and started looking for the logging code...
and... ZOMG!
They allready did it like 2 months ago!

in git anope has allready support for naming logfiles!
TY DUDES!
« Last Edit: October 30, 2010, 06:48:59 PM by someone »
Logged
Pages: [1]   Go Up