Page 1 of 1

Small fix for next Porteus (new option acpi=off)

Posted: 21 Feb 2017, 06:07
by Falcony
New boot option `acpi=off`

Currently if acpi=off option enabled Porteus starts with this error:
RTNETLINK1 answer: No such file or directory
acpid: error talking to the kernel via netlink

For Porteus `acpi=off` have to be implemented correсtly in boot scripts and described in documentation.

1. Patching current Porteus boot scripts:

Current /etc/rc.d/rc.M

Code: Select all

67 # Start ACPI daemon:
68 [ -x /etc/rc.d/rc.acpid ] && /usr/sbin/acpid -n &
now if acpi=off anyway it try to start acpid - and it failed with error.

Need to add checking before start acpid, if not equial acpi=off then start daemon

Change to /etc/rc.d/rc.M:

Code: Select all

67 # Start ACPI daemon:
68 if ! egrep -qo " acpi=off( |\$)" /proc/cmdline; then
69 [ -x /etc/rc.d/rc.acpid ] && /usr/sbin/acpid -n &
70 fi
Patch also start script of /etc/rc.d/rc.acpid:

Code: Select all

4# Start acpid:
5 acpid_start() {
6  if [ -x /usr/sbin/acpid -a -d /proc/acpi ]; then
7    echo "Starting ACPI daemon:  /usr/sbin/acpid"
8    /usr/sbin/acpid
9  fi
to:

Code: Select all

4# Start acpid:
5 acpid_start() {
6 if ! egrep -qo " acpi=off( |\$)" /proc/cmdline; then
7  if [ -x /usr/sbin/acpid -a -d /proc/acpi ]; then
8    echo "Starting ACPI daemon:  /usr/sbin/acpid"
9    /usr/sbin/acpid
10  fi
11 else
12 echo "ACPI daemon: it seems acpi=off boot parametr used."
13 fi

2. Please add descr. of acpi=off option to Porteus boot/docs/cheatcodes.txt:


After 'zram=some_value%':

Code: Select all

acpi=off 

   ... disable ACPI on boot stage, may use with debug option.
       Correct value is only `off`       
       Example: 'acpi=off'

Re: Small fix for next Porteus (new option acpi=off)

Posted: 26 Feb 2017, 00:08
by brokenman
Thanks for looking into it.

There are a million kernel cheat codes and I don't think we can add them all. The cheatcodes file is mainly for porteus related cheatcodes and not the standard kernel cheatcodes. I think this problem with acpi is an upstream bug and I am waiting for it to be fixed. Thanks.

Re: Small fix for next Porteus (new option acpi=off)

Posted: 05 Mar 2017, 13:49
by brokenman
Ok, now I understand. Sorry for the confusion. I've patched this in rc.M now so next release should be ok.