truncated output in syslog with 1.4.2

Mike Frysinger vapier at gentoo.org
Tue Mar 20 00:41:02 UTC 2007


On Monday 19 March 2007, Denis Vlasenko wrote:
> Hi Mike, Stephane,
>
> On Monday 19 March 2007 02:49, Stephane Billiart wrote:
> > On 18/03/07 ? ? 18:32, Mike Frysinger wrote:
> > > anyone else seen truncated messages when using syslog/klog ?  so i
> > > start up my system and run syslog/klog, /var/log/messages looks like:
> > > Jun  1 08:01:10 blackfin syslog.info syslogd started: BusyBox v1.4.1
> > > then i restart klog and this shows up:
> > > Jun  1 08:02:11 blackfin user.notice kernel: Ker
> > > Jun  1 08:02:11 blackfin user.notice kernel: klo
> > >
> > > changing MAX_READ in sysklogd.c to like 0xFF gives me more output, but
> > > i feel like that isnt the correct route :)
> > > -mike
>
> Thanks Mike for narrowing it down.
>
> > I have reported the same problem last month with uClibc 0.9.27 (glibc is
> > ok). I did not have time to narrow it down precisely but the reads in
> > sysklogd.c are definitely short.
>
> I think you built uclibc with extra small stdio buffer
> or something like that -> BUFSIZ is very small (128 bytes?).

yeah, default is normally like 4096, but we were using 256

> What printf("BUFSIZ=%d\n", BUFSIZ) prints, if added in syslogd.c?

echo '#include <stdio.h>' | ...-gcc -E -dD - | grep BUFSIZ
#define __STDIO_BUFSIZ 256

> Does attached modified syslogd.c work better?

seems to work, thanks ... you going to cut something for 1.4.x or just leave 
it for 1.5.x ?
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 827 bytes
Desc: not available
Url : http://lists.busybox.net/pipermail/busybox/attachments/20070319/aa1490e9/attachment-0002.pgp 


More information about the busybox mailing list