You are not logged in.
Pages: 1
Hi everybody,
i just got Devuan working on my Odroid N2+ using the maveric image as starting point (works flawlessly 🥰).
Now in order to spare the eMMC I used to run log2ram on it but log2ram is dependent on systemd.
According to the developer it should also work with init.d only the init script is needed.
My question is, does anyone use log2ram with sysvinit or knows another simple tool I could use to write logs to ram? I have no experience with sysv so far and thought I'd ask before starting to tinker myself.
Thank you.
Offline
Okay after researching for another hour or so I found that log2ram is the successor of a project called transientlog which in turn was born out of an article from debian-administration.org called A transient /var/log - back in 2010 when systemd wasn't yet relevant.
Therefore I was able to apply transientlog almost without modification to my Devuan 5 install and for now it seems to work. It creates a RAM drive on startup and copies all log files into it. On shutdown/reboot it does the opposite. It copies all log files from the RAM drive to the eMMC card. The only thing I modified was the size of the RAM drive - from 25M to 90M because my log folder was already 38M in size.
I will keep monitoring the script to see if it is stable and report my findings.
Offline
Hi, thanks Jonny, I tried transientlog and had to modify the install script I believe (removed systemctl daemon-reload from install.sh, Anyway I got it to work, but it was unreliable after I installed fail2ban and ufw. It would work if I stopped, deleted the permanentlog file and started it again. So I went searching for someone who has got ram2log working for sysv and I found this > https://energytalk.co.za/t/gx-device-lo … g2ram/2130
I have 3 Arm sbc devices, one is a old bananapi pro. All are headless and have new fresh devuan installs on them. I followed the tutorial for log2ram above, it all went smooth, seems to work.
The other 2 smb's are located remotely and both running devuan daedalus as well. As I installed to the next one via ssh I did this too I thought this would work but it never came back after I rebooted (end of the install tutorial), so :-(
Maybe somebody here could look and suggest change(s) to that tutorial. I am not sure if I typed something wrong on my second device or not.
The only complaint during install was when entering this (both devices)- sudo update-rc.d log2ram-init.sh start 06 S . stop 80 0 6 . I got this: update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults otherwise no errors.
So maybe the tutorial works and maybe its doesn't. cheers
Edit: I just thought of this, On the bannanapro install, for root command I do not have to enter sudo first. Such as #findmnt on the other 2 I have to enter sudo first #sudo findmnt I wonder if this is my problem. The tutorial in link , he did say "IMPORTANT: Install findmnt - needed to log2ram core tool:"
hmmmmm
Edit#2: Actually after more digging around I can use findmnt (/sbin), but not anything located in /bin unless I type sudo first.
I bet that could be my problem
Edit#3: sleuthing around the internet today, I guess I should have used su - to get the correct path. I logged in as a normal user, then "su root" but I guess that is not enough, still need to su - first. Got the remote sbc rebooted and the root file system mounted. Its just busybox inititramfs and dropbear right now. Log file doesn't have much of a clue. I'll get this eventually sorted out and post a reply here, so if it works then there is alternative beside transientlog.
Last edited by cake (2024-11-14 03:35:48)
Offline
Pages: 1