log2ram
log2ram copied to clipboard
[Feature] init.d compatibility
Is it possible to adapt log2 ram to init.d that is used on Gentoo Linux instead of Systemd?
I think Gentoo have init.d system ?
Yes, i have /etc/init.d... Sorry. At boottime on tehn screen i can see openrc starting. i think i was misunderstanding that.
related to #16
Are you familiar to use iniV ? I will allow init configuration, but I cannot test it here.
No, sorry. Never heard about iniV
Sorry the name of init.d script is sysvinit (also named SystemV), the doc say it's compatible with OpenRC
What is the output of cat /proc/1/comm
?
Well, minimal... Have seen already some but can not convert from systemd :-( The Gentoo i used is Gen2VDR that is a distribution bundled with VDR and Kodi to have an Linux HTPC. Bas System is Gentoo.
The reqested Output:
root auf hdvdr01 am 19.02.2018 13:52
[~] # cat /proc/1/comm
init
I found this: https://github.com/akhilvij/systemd-to-sysvinit-converter But i doubt it is much help
@fugitive90 Maybe you can help with that. I see you have fork my project for FreeBSD use. We can open a branch for sysvinit compatibility.
Hello everyone. Sorry didn't noticed notification. @azlux yes, I planed to made for sysvinit and open-rc, but didn't got time to finish it. I'll see what I can do.
@fugitive90 You can make changes into https://github.com/azlux/log2ram/tree/sysvinit I see you have change many function, maybe we can create a functional branch for init.d system and add other changes later.
@azlux Please find me on freenode, #devuan,#alpine-linux or #artix nick ``fugitive'' so we can discuss it.
i tried to install om my VDR. But it fails:
root auf hdvdr01 am 01.06.2018 13:30 [~/log2ram-sysvinit] # bash ./install.sh ./install.sh: Zeile 14: systemctl: Kommando nicht gefunden.
Reboot to activate log2ram
Does your machine run systemd? Looks like this is not the case.
Is Gentoo Linux
root auf hdvdr01 am 19.02.2018 13:52 [~] # cat /proc/1/comm init
i think it is openrc-init https://wiki.gentoo.org/wiki/Init_system
@MegaV0lt Sorry I cannot make the init script for gentoo. I never use it. If you think you can do it, I will create a Branch for that.
I have several raspberry pis running Rasbian (Debian 7) which still uses init instead of systemd. I don't know if a solution for init on Rasbian might benefit the Gentoo distro in any way?
Gen2VDR (Gentoo) is using init.d-Scripts. Example:
root auf hdvdr01 am 07.06.2018 08:31
[~] # cat /etc/init.d/ntpd
#!/sbin/openrc-run
# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
description="ntpd - the network time protocol daemon"
pidfile="/var/run/ntpd.pid"
command="/usr/sbin/ntpd"
command_args="-p ${pidfile} ${NTPD_OPTS}"
start_stop_daemon_args="--pidfile ${pidfile}"
depend() {
use net dns logger
after ntp-client
}
start_pre() {
if [ ! -f /etc/ntp.conf ] ; then
eerror "Please create /etc/ntp.conf"
return 1
fi
return 0
}
start-stop-deamion is also in some scripts
I started a attempt to include detection of init-system and install/uninstall files acording to the init-system. My first try looks good so far. You can take a look here: https://github.com/MegaV0lt/log2ram
Is it just recent update broke openrc support?
What update you mean?
Never mind, I just copied the old open-rc script from another alpine box and it works now, just guessing recent update removed / broke open-rc support