Und ich würde noch gerne den Output von fsck dabei haben.
Vielleicht so?
/etc/inittab anpassen:
1. /etc/init.d/rcS bekommt ein wrapper script.
2. fsck wird später gemacht.
Code: Alles auswählen
root@homematic-raspi:~# tail -n 26 /etc/inittab
# Startup the system
tty2::sysinit:/bin/mount -t proc proc /proc
tty2::sysinit:/bin/mount -t sysfs sysfs /sys
tty2::sysinit:/bin/mkdir -p /dev/pts /dev/shm
#tty2::sysinit:/sbin/fsck -A -R -p
#tty2::sysinit:/bin/mount -a
#tty2::sysinit:/bin/mkdir -p /var/run /var/cache
#tty2::sysinit:/sbin/ldconfig -C /var/cache/ld.so.cache
#null::sysinit:/usr/bin/psplash -n &
# now run any rc scripts
#::sysinit:/etc/init.d/rcS
::sysinit:/etc/init.d/rcS.logged
# run monit to monitor our important services
null::respawn:/usr/bin/monit -Ic /etc/monitrc
# Put a getty on tty2
tty2::askfirst:/sbin/getty -L tty2 0 vt100
# Stuff to do for the 3-finger salute
::ctrlaltdel:/sbin/reboot
# Stuff to do before rebooting
null::shutdown:/usr/bin/monit unmonitor all
::shutdown:/etc/init.d/rcK
tty2::shutdown:/bin/umount -a -r -f >/dev/null
tty2::shutdown:/sbin/swapoff -a
Code: Alles auswählen
root@homematic-raspi:~# cat /etc/init.d/rcS.logged
#!/bin/sh
# shellcheck shell=dash disable=SC2169 source=/dev/null
/bin/mount /tmp
/etc/init.d/rcS 2>&1 | /usr/bin/tee -a /tmp/rcS.log
# now /tmp/rcS.log should go to a persistent location
Code: Alles auswählen
root@homematic-raspi:~# head -n 15 /etc/init.d/rcS
#!/bin/sh
# shellcheck shell=dash disable=SC2169 source=/dev/null
#
/sbin/fsck -A -R -p
/bin/mount -a
/bin/mkdir -p /var/run /var/cache
/sbin/ldconfig -C /var/cache/ld.so.cache
/usr/bin/psplash -f 0 &
# Start all init scripts in /etc/init.d
# executing them in numerical order.
Beim Starten von psplash muste ich die Parameter ändern, habe da aber nicht wirklich den Durchblick.
Also: Nicht nach machen.
Code: Alles auswählen
root@homematic-raspi:~# more /tmp/rcS.log
fsck 1.46.4 (18-Aug-2021)
userfs: clean, 2737/328000 files, 54779/1311470 blocks
FBIOPAN_DISPLAY not supported, double buffering disabledIdentifying onboard hardware: ova-KVM, OK
Initializing ZRAM Swap: OK
Initializing RTC Clock: onboard, OK
Starting acpid: OK
Running sysctl: OK
Initializing urandom: OK
Checking for Factory Reset: not required
Checking for Backup Restore: not required
Initializing System: OK
Starting logging: OK
Populating /dev using udev: done
Init onboard LEDs: init, OK
Starting irqbalance: OK
Starting rngd: OK
Starting system message bus: done
Starting iptables: OK
Starting bluetooth: disabled
Starting network: eth0: link up, dhcp, firewall, inet up, 192.168.bla.bla, wlan0: missing, OK
Starting Network Interface Plugging Daemon: eth0.
Starting chrony: OK
Identifying Homematic RF-Hardware: ....HmRF: HMIP-RFUSB/eQ-3 HmIP-RFUSB@usb-0000:00:05.1-1, HmIP: HMIP-RFUSB/eQ-3 HmIP-RFUSB@usb-0000:00:05.1-1, OK
Updating Homematic RF-Hardware: HMIP-RFUSB: 4.4.16, OK
Starting hs485dLoader: disabled
Starting xinetd: OK
Starting eq3configd: OK
Starting lighttpd: OK
Starting ser2net: disabled
Starting ssdpd: OK
Starting sshd: OK
Starting NUT services: disabled
Initializing Third-Party Addons: OK
Starting LGWFirmwareUpdate: ...OK
Setting LAN Gateway keys: OK
Starting hs485d: disabled
Starting multimacd: .OK
Starting rfd: .OK
Starting HMIPServer: ........OK
Starting ReGaHss: .OK
Starting CloudMatic: OK
Starting Third-Party Addons: OK
Starting crond: OK
Setup onboard LEDs: booted, OK