Topic: Missing syslog files
Where do the system logs get written? I notice /var is a mount, but nothing
seems to show up in /var/log. My concern is filling up the flash with
hidden log files, since the log-rotate will not work. If this is broken,
how do I fix it? (Maybe just delete the /dev/log and let syslogd remake it?)
I haven't done much on the Chumby root filesystem, added root passwd, changed
PS1, etc. Having trouble getting a chrooted Debian on usb mysqld running -- has the
socket permission problem, which I finally realized might not be the mysqld.sock, but the /dev/log
socket causing problems. Looked at the /dev/log and saw the syslog missing problem.
Thanks
Really empty:
# ls -a /var/log
. ..
(and it is writeable)
syslogd is running:
(I had recently restarted it, hence the large pid)
root@chumby-30-86-f9:/# ps auxww |fgrep sysl
8639 root 0:00 /sbin/syslogd -C400
(and var is mounted with a tmpfs)
The socket is present and is used in the later logger command:
root@chumby-30-86-f9:/# ls -l /dev/log*
srw-rw-rw- 1 root root 0 Jan 4 16:42 /dev/log
crw-rw---- 1 root root 10, 62 Dec 31 1969 /dev/log_events
crw-rw---- 1 root root 10, 63 Dec 31 1969 /dev/log_main
crw-rw---- 1 root root 10, 61 Dec 31 1969 /dev/log_radio
Nothing visible on the filesystem for messages:
root@chumby-30-86-f9:/# find / -name messages -ls
root@chumby-30-86-f9:/#
dmesg does output information, not sure how current, since the last lines refer to headphones, which I don't
use, but may have tested once.
strace of logger shows:
# strace logger "trace for the log"
execve("/usr/bin/logger", ["logger", "trace for the log"], [/* 24 vars */]) = 0
brk(0) = 0xdf000
uname({sys="Linux", node="chumby-30-86-f9", ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x4001d000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/lib/tls/v5l/fast-mult/half/libm.so.6", O_RDONLY) = -1 ENOENT (No such file or directory)
stat64("/lib/tls/v5l/fast-mult/half", 0xbeb1e188) = -1 ENOENT (No such file or directory)
---snip lots of missing /lib/tls, /lib/v5l, /lib/fast-mult, and /lib/half files
gettimeofday({1325724215, 619459}, NULL) = 0
open("/etc/localtime", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=2819, ...}) = 0
fstat64(3, {st_mode=S_IFREG|0644, st_size=2819, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x4001f000
read(3, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\4\0\0\0\4\0\0\0\0\0"..., 4096) = 2819
_llseek(3, -24, [2795], SEEK_CUR) = 0
read(3, "\nPST8PDT,M3.2.0,M11.1.0\n"..., 4096) = 24
close(3) = 0
munmap(0x4001f000, 4096) = 0
stat64("/etc/localtime", {st_mode=S_IFREG|0644, st_size=2819, ...}) = 0
socket(PF_FILE, SOCK_DGRAM, 0) = 3
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
connect(3, {sa_family=AF_FILE, path="/dev/log"...}, 110) = 0
send(3, "<13>Jan 4 16:43:35 root: trace f"..., 43, MSG_NOSIGNAL) = 43
close(3) = 0
exit_group(0) = ?