But The file is not persisted across reboots some reboots or as it seems so. It enabled file writing on Sep 27 but the first row in the file now is from 1st Oct.
Is the file being rotated and written somewhere else not in /var/log ?
OR
Can it be that the log size is too small (256) and it is being overwritten?
If it is the size that is too low how much can I set it to? I am using Raspberry Pi3 and have plenty of space in the filesystem.
you probably don't want to log to the router flash (limited resource, limited
writes, impossible to replace), send the logs to a remote host or configure to
write to a USB drive (use rsyslog or syslog-ng if you are doing anything more
than just sending logs to a remote destination that are always going to be <1k)
This is how filesystems look like. /var is located on / partition which is /dev/root device, ext. Are you sure it is a ramdisk?
Sending logs to separate logserver is a pain since I will need to set one up and logserver is really boring. If it is really a ramdisk then of course I do not want to write to it.
But shouldn't it be possible to mount a sdcard which is in the PI3 or take some of it's disk and create a partition ...
root@ROOter:~# mount
/dev/root on / type ext4 (rw,noatime,block_validity,delalloc,barrier,user_xattr)
proc on /proc type proc (rw,nosuid,nodev,noexec,noatime)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,noatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noatime)
/dev/mmcblk0p1 on /boot type vfat (rw,noatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
tmpfs on /dev type tmpfs (rw,nosuid,relatime,size=512k,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,mode=600)
debugfs on /sys/kernel/debug type debugfs (rw,noatime)
root@ROOter:~# df -h
Filesystem Size Used Available Use% Mounted on
/dev/root 252.0M 25.6M 221.3M 10% /
tmpfs 464.9M 2.0M 462.8M 0% /tmp
/dev/mmcblk0p1 19.9M 9.4M 10.5M 47% /boot
tmpfs 512.0K 0 512.0K 0% /dev