Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
* syslogd revisited
@ 1999-01-08  0:02 furio ercolessi
  1999-01-08  0:20 ` Bob McElrath
  0 siblings, 1 reply; 9+ messages in thread
From: furio ercolessi @ 1999-01-08  0:02 UTC (permalink / raw)
  To: axp-list

Again on syslogd.

I am not reporting the problem so often reported in the past
(syslogd and klogd eating all CPU, "select: Bad file descriptor",
"last message repeated 79172 times" , etc).  I am not suffering of 
this problem with my current setup (RH 5.2, 2.0.36, sysklogd-1.3-26).

However, I am rather unhappy with the amount of CPU which
syslogd seems to use under normal circumstances.
For instance, right now I observe a syslogd using about 60-70%
of a 533MHz LX to write about 13kB per minute on a file.
This is ridiculous.  Heck, in this case the messages are generated 
by sendmail, which does that while cruising along at 0.1% CPU.

syslogd therefore appears as the principal bottleneck in
our systems' performance.  Is anybody else observing that?

furio ercolessi
Spin - Trieste (Italy)


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: syslogd revisited
  1999-01-08  0:02 syslogd revisited furio ercolessi
@ 1999-01-08  0:20 ` Bob McElrath
  1999-01-08  1:04   ` furio ercolessi
  0 siblings, 1 reply; 9+ messages in thread
From: Bob McElrath @ 1999-01-08  0:20 UTC (permalink / raw)
  To: axp-list

On Fri, 8 Jan 1999, furio ercolessi wrote:

> Again on syslogd.
> 
> I am not reporting the problem so often reported in the past
> (syslogd and klogd eating all CPU, "select: Bad file descriptor",
> "last message repeated 79172 times" , etc).  I am not suffering of 
> this problem with my current setup (RH 5.2, 2.0.36, sysklogd-1.3-26).
> 
> However, I am rather unhappy with the amount of CPU which
> syslogd seems to use under normal circumstances.
> For instance, right now I observe a syslogd using about 60-70%
> of a 533MHz LX to write about 13kB per minute on a file.
> This is ridiculous.  Heck, in this case the messages are generated 
> by sendmail, which does that while cruising along at 0.1% CPU.
> 
> syslogd therefore appears as the principal bottleneck in
> our systems' performance.  Is anybody else observing that?

1) Turn off mail reporting (it generates high volume...)

2) configure sendmail to NOT sync after a write.  This may be where the CPU
usage is coming from.  Not from sendmail, but from the forced disk write
(via sync).

-- Bob

Bob McElrath (mcelrath@draal.physics.wisc.edu) Univ. of Wisconsin at Madison


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: syslogd revisited
  1999-01-08  0:20 ` Bob McElrath
@ 1999-01-08  1:04   ` furio ercolessi
  1999-01-08  1:31     ` Bob McElrath
  0 siblings, 1 reply; 9+ messages in thread
From: furio ercolessi @ 1999-01-08  1:04 UTC (permalink / raw)
  To: axp-list

> > However, I am rather unhappy with the amount of CPU which
> > syslogd seems to use under normal circumstances.
> > For instance, right now I observe a syslogd using about 60-70%
> > of a 533MHz LX to write about 13kB per minute on a file.
> > This is ridiculous.  Heck, in this case the messages are generated 
> > by sendmail, which does that while cruising along at 0.1% CPU.
> > 
> > syslogd therefore appears as the principal bottleneck in
> > our systems' performance.  Is anybody else observing that?
> 
> 1) Turn off mail reporting (it generates high volume...)

No, we cannot do that, we need the logs (we are an ISP).

> 2) configure sendmail to NOT sync after a write.  This may be where the CPU
> usage is coming from.  Not from sendmail, but from the forced disk write
> (via sync).

This was an excellent suggestion!  I just discovered that you could
do that by putting a "-" prefix in front of the filename in
syslog.conf, as explained in sysklogd(8).  It really worked.
syslogd usage went down to nearly zero, and the funny thing is that 
error messages seem to go out instantly to the disk file anyway.

Still, the cost of sync'ing a file cannot be that high.
I believe that this behavior suggests the presence of some other can 
of worms somewhere, which somebody may like to open ;-)

Thanks again for this fantastic tip!

furio ercolessi
Spin - Trieste (Italy)


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: syslogd revisited
  1999-01-08  1:04   ` furio ercolessi
@ 1999-01-08  1:31     ` Bob McElrath
  1999-01-08  1:51       ` furio ercolessi
  0 siblings, 1 reply; 9+ messages in thread
From: Bob McElrath @ 1999-01-08  1:31 UTC (permalink / raw)
  To: axp-list

On Fri, 8 Jan 1999, furio ercolessi wrote:

> > > However, I am rather unhappy with the amount of CPU which
> > > syslogd seems to use under normal circumstances.
> > > For instance, right now I observe a syslogd using about 60-70%
> > > of a 533MHz LX to write about 13kB per minute on a file.
> > > This is ridiculous.  Heck, in this case the messages are generated 
> > > by sendmail, which does that while cruising along at 0.1% CPU.
> > > 
> > > syslogd therefore appears as the principal bottleneck in
> > > our systems' performance.  Is anybody else observing that?
> > 
> > 1) Turn off mail reporting (it generates high volume...)
> 
> No, we cannot do that, we need the logs (we are an ISP).
> 
> > 2) configure sendmail to NOT sync after a write.  This may be where the CPU
> > usage is coming from.  Not from sendmail, but from the forced disk write
> > (via sync).
> 
> This was an excellent suggestion!  I just discovered that you could
> do that by putting a "-" prefix in front of the filename in
> syslog.conf, as explained in sysklogd(8).  It really worked.
> syslogd usage went down to nearly zero, and the funny thing is that 
> error messages seem to go out instantly to the disk file anyway.

Perhaps create a separate mail log and just don't sync on the mail log.

> Still, the cost of sync'ing a file cannot be that high.
> I believe that this behavior suggests the presence of some other can 
> of worms somewhere, which somebody may like to open ;-)

It really is that high.  Syslogd writes to disk after every message (usually
every line), so 13k/min is  ~130 writes/s.  When data is NOT synced, this
means that it is not physically on disk.  i.e. if the system crashes, the
only data on disk will be since the last sync.  (The kernel automatically
syncs at regular intervals...every few minutes, IIRC)

In other words, make sure kernel messages go to a file that gets synced, or
you could be in for trouble.  :)

Have you (or anyone else) noticed syslogd crashing regularly?  Mine crashes
like every 2-3 days, and I have to restart it.

-- Bob

Bob McElrath (mcelrath@draal.physics.wisc.edu) Univ. of Wisconsin at Madison


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: syslogd revisited
  1999-01-08  1:31     ` Bob McElrath
@ 1999-01-08  1:51       ` furio ercolessi
  1999-01-08  2:08         ` Larry Snyder
  1999-03-19 17:46         ` furio ercolessi
  0 siblings, 2 replies; 9+ messages in thread
From: furio ercolessi @ 1999-01-08  1:51 UTC (permalink / raw)
  To: axp-list

> On Fri, 8 Jan 1999, furio ercolessi wrote:
> 
> > > > However, I am rather unhappy with the amount of CPU which
> > > > syslogd seems to use under normal circumstances.
> > > > For instance, right now I observe a syslogd using about 60-70%
> > > > of a 533MHz LX to write about 13kB per minute on a file.
> > > > This is ridiculous.  Heck, in this case the messages are generated 
> > > > by sendmail, which does that while cruising along at 0.1% CPU.
> > > > 

> > Still, the cost of sync'ing a file cannot be that high.
> > I believe that this behavior suggests the presence of some other can 
> > of worms somewhere, which somebody may like to open ;-)
> 
> It really is that high.  Syslogd writes to disk after every message (usually
> every line), so 13k/min is  ~130 writes/s.  

I meant 13 kbytes per minute, or ~200 bytes/s or ~3 messages/s.
I also administer an HP 710/50 MHz (1993 or 1994) that handles a
comparable load rather comfortably, and the CPU is some factor 20 
less powerful.

> When data is NOT synced, this
> means that it is not physically on disk.  i.e. if the system crashes, the
> only data on disk will be since the last sync.  (The kernel automatically
> syncs at regular intervals...every few minutes, IIRC)
> 
> In other words, make sure kernel messages go to a file that gets synced, or
> you could be in for trouble.  :)

Yes; however, after the configuration change the log files seems synced 
anyway, only without the CPU overhead. Strange.

Another, perhaps related symptom I observed is that the "sync" command
may take a rather long time to execute (of the order of 30 seconds).
Isn't that a bit too much?

> Have you (or anyone else) noticed syslogd crashing regularly?  Mine crashes
> like every 2-3 days, and I have to restart it.

No, mine runs healthy :-)
root       184  1.0  0.2  3160   560  ?  S   Nov 21 740:43 syslogd

furio ercolessi
Spin - Trieste


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: syslogd revisited
  1999-01-08  1:51       ` furio ercolessi
@ 1999-01-08  2:08         ` Larry Snyder
  1999-03-19 17:46         ` furio ercolessi
  1 sibling, 0 replies; 9+ messages in thread
From: Larry Snyder @ 1999-01-08  2:08 UTC (permalink / raw)
  To: axp-list

furio ercolessi <furio@spin.it> wrote:
> > On Fri, 8 Jan 1999, furio ercolessi wrote:
> > 
> > > > > However, I am rather unhappy with the amount of CPU which
> > > > > syslogd seems to use under normal circumstances.
> > > > > For instance, right now I observe a syslogd using about 60-70%
> > > > > of a 533MHz LX to write about 13kB per minute on a file.
> > > > > This is ridiculous.  Heck, in this case the messages are generated 
> > > > > by sendmail, which does that while cruising along at 0.1% CPU.
> > > > > 
> 
> > > Still, the cost of sync'ing a file cannot be that high.
> > > I believe that this behavior suggests the presence of some other can 
> > > of worms somewhere, which somebody may like to open ;-)
> > 
> > It really is that high.  Syslogd writes to disk after every message (usually
> > every line), so 13k/min is  ~130 writes/s.  
> 
> I meant 13 kbytes per minute, or ~200 bytes/s or ~3 messages/s.
> I also administer an HP 710/50 MHz (1993 or 1994) that handles a
> comparable load rather comfortably, and the CPU is some factor 20 
> less powerful.

Some flavors of sync copy ALL buffers to disk, but don't necessarily flush them.
That's why running it frequently can hurt deeply.
-ls-
  
> 
> > When data is NOT synced, this
> > means that it is not physically on disk.  i.e. if the system crashes, the
> > only data on disk will be since the last sync.  (The kernel automatically
> > syncs at regular intervals...every few minutes, IIRC)
> > 
> > In other words, make sure kernel messages go to a file that gets synced, or
> > you could be in for trouble.  :)
> 
> Yes; however, after the configuration change the log files seems synced 
> anyway, only without the CPU overhead. Strange.
> 
> Another, perhaps related symptom I observed is that the "sync" command
> may take a rather long time to execute (of the order of 30 seconds).
> Isn't that a bit too much?
> 
> > Have you (or anyone else) noticed syslogd crashing regularly?  Mine crashes
> > like every 2-3 days, and I have to restart it.
> 
> No, mine runs healthy :-)
> root       184  1.0  0.2  3160   560  ?  S   Nov 21 740:43 syslogd
> 
> furio ercolessi
> Spin - Trieste
> 
> -- 
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: syslogd revisited
  1999-01-08  1:51       ` furio ercolessi
  1999-01-08  2:08         ` Larry Snyder
@ 1999-03-19 17:46         ` furio ercolessi
  1999-03-19 17:51           ` Reid van Melle
  1999-03-22 15:06           ` wae
  1 sibling, 2 replies; 9+ messages in thread
From: furio ercolessi @ 1999-03-19 17:46 UTC (permalink / raw)
  To: axp-list

[ this is from a january thread starting with
  http://www.lib.uaa.alaska.edu/axp-list/archive/1999-01/0303.html ]

Bob McElrath wrote:
> > Have you (or anyone else) noticed syslogd crashing regularly?  Mine crashes
> > like every 2-3 days, and I have to restart it.

furio ercolessi wrote:
> No, mine runs healthy :-)
> root       184  1.0  0.2  3160   560  ?  S   Nov 21 740:43 syslogd

Well, on one of my machines I now observed syslogd crashes (leaving
a core).  So far it happened twice.  This is sysklogd-1.3-26 from the 
RH5.2 updates.  Annoying.

furio ercolessi
Spin - Trieste (Italy)


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: syslogd revisited
  1999-03-19 17:46         ` furio ercolessi
@ 1999-03-19 17:51           ` Reid van Melle
  1999-03-22 15:06           ` wae
  1 sibling, 0 replies; 9+ messages in thread
From: Reid van Melle @ 1999-03-19 17:51 UTC (permalink / raw)
  To: axp-list

> Bob McElrath wrote:
> > > Have you (or anyone else) noticed syslogd crashing regularly?  Mine crashes
> > > like every 2-3 days, and I have to restart it.

I have been upset with syslogd for a long time.  Every few days, we find
this on top:

12665 root      17   0   392  328   240 R     264 99.9  0.0 42139m syslogd

and do a "/etc/rc.d/init.d/syslog restart" which completely hangs the
machine for about 30-40 seconds.  I'm using sysklogd-1.3-19.  I believe I
tried 1.3-27 and it didn't work (can't remember why).  I'm hoping there is
eventually a permanent solution to the syslogd problems.

				Reid van Melle

 > 
> furio ercolessi wrote:
> > No, mine runs healthy :-)
> > root       184  1.0  0.2  3160   560  ?  S   Nov 21 740:43 syslogd
> 
> Well, on one of my machines I now observed syslogd crashes (leaving
> a core).  So far it happened twice.  This is sysklogd-1.3-26 from the 
> RH5.2 updates.  Annoying.
> 
> furio ercolessi
> Spin - Trieste (Italy)
> 
> -- 
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com
> 


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: syslogd revisited
  1999-03-19 17:46         ` furio ercolessi
  1999-03-19 17:51           ` Reid van Melle
@ 1999-03-22 15:06           ` wae
  1 sibling, 0 replies; 9+ messages in thread
From: wae @ 1999-03-22 15:06 UTC (permalink / raw)
  To: axp-list

I have also observed the same behavior on a PC164 machine running
syskogd-1.3-26 with 5.2 updates. I do not have a good feel for the
frequency at this time, but it seems to be once a week at least. 

Bill Edmonson

furio ercolessi wrote:
> 
> [ this is from a january thread starting with
>   http://www.lib.uaa.alaska.edu/axp-list/archive/1999-01/0303.html ]
> 
> Bob McElrath wrote:
> > > Have you (or anyone else) noticed syslogd crashing regularly?  Mine crashes
> > > like every 2-3 days, and I have to restart it.
> 
> furio ercolessi wrote:
> > No, mine runs healthy :-)
> > root       184  1.0  0.2  3160   560  ?  S   Nov 21 740:43 syslogd
> 
> Well, on one of my machines I now observed syslogd crashes (leaving
> a core).  So far it happened twice.  This is sysklogd-1.3-26 from the
> RH5.2 updates.  Annoying.
> 
> furio ercolessi
> Spin - Trieste (Italy)
> 
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~1999-03-22 15:20 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-01-08  0:02 syslogd revisited furio ercolessi
1999-01-08  0:20 ` Bob McElrath
1999-01-08  1:04   ` furio ercolessi
1999-01-08  1:31     ` Bob McElrath
1999-01-08  1:51       ` furio ercolessi
1999-01-08  2:08         ` Larry Snyder
1999-03-19 17:46         ` furio ercolessi
1999-03-19 17:51           ` Reid van Melle
1999-03-22 15:06           ` wae

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox