[syslog-ng] Bugreport: Ver 1.9.5 problems with facility/level
filtering
Roberto Nibali
ratz at drugphish.ch
Tue Oct 4 00:53:53 CEST 2005
> Well this is depressing.... I'm googling this, and found this:
> http://archive.apache.org/gnats/7902
Nice.
> I get the distinct impression that tm_getoff doesn't exist on Solaris 8
> (although it appears that Sun finally added it later on, as it's obviously
> there in 10). I guess the Apache guys produced a Solaris-specific chunk
> of code to work around that shortcoming (and that's what the web page is
> discussing).
Exactly. Here is the full code which seems to work around those issues
rather nicely (you're in for a good treat reading the comment block
almost at the end of the code):
http://svn.apache.org/viewcvs.cgi/apr/apr/trunk/time/unix/time.c?view=markup
I wonder if this should be implemented in syslog-ng as well? Browsing
through the whole httpd code of Apache reveils a very thoughtful
designed cross-platform implementation of concepts in many aspects of
ancients disputes in Unix history.
> If anyone has any clues as to how one might add the "later" (more capable)
> time functionality on Solaris 8, I'd obviously love to hear it, or it
I have an idea, but distinct lack of time right now. Bazsi is in Sevilla
enjoying the sun and giving interesting speeches at the present time ;).
He has a lot to fix when he comes back.
> looks like I'm dead in the water for using the future version of syslog-ng
> at this point. (i.e. a possible patch, or external component, that has
> this extended capability.)
Could you grep for this tm_gmtoff and altzone as follows, please (maybe
it's defined as __tm_gmtoff)?
find /usr/ -type f -name "*.h" -exec grep "tm_gmtoff" /dev/null {} \;
find /usr/ -type f -name "*.h" -exec grep "altzone" /dev/null {} \;
But chances are little. Reading man page of SunOS 8/04 localtime(3C) I
could find:
The value of tm_isdst is positive if daylight savings time
is in effect, zero if daylight savings time is not in
effect, and negative if the information is not available.
Previously, the value of tm_isdst was defined as non-zero if
daylight savings was in effect.
The external time_t variable altzone contains the differ-
ence, in seconds, between Coordinated Universal Time and the
alternate time zone. The external variable timezone contains
the difference, in seconds, between UTC and local standard
time. The external variable daylight indicates whether time
should reflect daylight savings time. Both timezone and
altzone default to 0 (UTC). The external variable daylight
is non-zero if an alternate time zone exists. The time zone
names are contained in the external variable tzname, which
by default is set to:
char *tzname[2] = { "GMT", "" };
These functions know about the peculiarities of this conver-
sion for various time periods for the U.S. (specifically,
the years 1974, 1975, and 1987). They start handling the new
daylight savings time starting with the first Sunday in
April, 1987.
http://docs.sun.com/app/docs/doc/817-5438/6mkt5pc7s?q=localtime&a=view
So, in fact, it could be done for your system as well. I should know
since I live in a country where time means everything to the its people
;). They even apologize to you at the railway station through the
loudspeakers if the train departure is delayed by more than 3 minutes.
Have a nice one,
Roberto Nibali, ratz
--
echo
'[q]sa[ln0=aln256%Pln256/snlbx]sb3135071790101768542287578439snlbxq' | dc
More information about the syslog-ng
mailing list