Bug 482

Summary: syslog startup script is broken
Product: [Build System, Metadata & Runtime] Meta-yocto Reporter: Mark Hatle <mark.hatle>
Component: meta-yoctoAssignee: Qing He <qing.he>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium CC: jessica.zhang, ke.yu, kevin.tian, poky.bs.watcher, poky.watcher, richard.purdie, sgw
Version: 0.9   
Target Milestone: 0.9 M4   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: ---

Description Mark Hatle 2010-10-18 16:17:06 UTC
The syslog startup script fails with:


root@routerstationpro:~# /etc/init.d/syslog start
/etc/init.d/syslog: /etc/syslog.conf: line 5: *.=debug: not found

Looking at the syslog initscript, it attempts to source the file /etc/syslog.conf.  However this file is NOT in shell format, it is indeed just the configuration file for syslog.

---

Disabling the sourcing of /etc/syslog.conf still results in error messages:


  syslogd: /usr/adm/debug: No such file or directory
  syslogd: /usr/adm/syslog: No such file or directory
  syslogd: /var/adm/critical: No such file or directory
  syslogd: /var/adm/kernel: No such file or directory
  syslogd: /var/adm/kernel-info: No such file or directory
  syslogd: /var/adm/mail: No such file or directory
  syslogd: /var/adm/info: No such file or directory
  syslogd: /usr/adm/messages: No such file or directory

The syslog.conf file needs to be updated to point to the proper locations for log storage.  If the specified locations are correct, then the directories need to be generated somewhere.
Comment 1 Saul Wold 2010-10-18 16:52:38 UTC
There are also 2 syslog init scripts delivered to the image, one by busybox, which is the /etc/init.d/syslog, there is a second one for the non-busybox sysklogd, which when installed is an Alternative to the busybox syslogd.  That script should be installed instead of syslogd.  

Please verify that alternatives are set up correctly in the sysklogd recipe, and test that syslog start correctly in a basic/lsb image as well as in a minimal images since there are 2 different syslogs.

Also double check the /etc/syslog.conf is correct for the installed version.

Finally the default syslog.conf from sysklogd is not correct and needs to be setup for /var/log not /var/adm and /usr/adm, so a new syslog.conf file should be created and installed along with the init.d script.
Comment 2 Ke Yu 2010-10-19 07:34:06 UTC
submit patch as http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=kyu3/bug482, waiting for checking.

it has been tested in qemux86 minimal, sato and lsb image, all works.