You are not logged in.

#1 2016-08-12 14:53:18

schmodd
Member
Registered: 2015-02-12
Posts: 33

Failed to execute /init (error -2) after pacman -Syu

Today I updated these 3 packages and rebooted after:
linux 4.7-1
linux-headers 4.7-1
nvidia 367.35-2

I am using uefi + systemd-boot.
/boot and / on a single ssd
/home/schmodd/Data on a sata drive

I got this error: http://imgur.com/XjkB6Mu (sry can only supply a picture).

I did chroot into my system and did another system update and also reinstalled those 3 packages again.
It is all being generated without an error.

All pretty basic and prior to this error it all worked well.
Any ideas?

Last edited by schmodd (2016-08-12 17:18:32)

Offline

#2 2016-08-12 14:57:05

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: Failed to execute /init (error -2) after pacman -Syu

Try the fallback kernel.

Offline

#3 2016-08-12 15:13:38

null
Member
Registered: 2009-05-06
Posts: 398

Re: Failed to execute /init (error -2) after pacman -Syu

Did you by any chance remove systemd-sysvcompat?
Try passing the real init as a kernel parameter:

init=/usr/lib/systemd/systemd

Offline

#4 2016-08-12 15:13:38

schmodd
Member
Registered: 2015-02-12
Posts: 33

Re: Failed to execute /init (error -2) after pacman -Syu

Fallback gives me the same result.

Last edited by schmodd (2016-08-12 15:14:39)

Offline

#5 2016-08-12 15:29:47

schmodd
Member
Registered: 2015-02-12
Posts: 33

Re: Failed to execute /init (error -2) after pacman -Syu

Something really weired is going on ... boot-menu is not even showing up during boot although i set up timeout 4.
It jumps straight to the error. Sometimes I manage to get the menu while pressing a key, but its more luck than anything else....

So while in the boot menu I pressed P to call Print - this showed me that the EFI had a different timeout (0) set than my config (4).
So it seemed like my EFI did change somehow.

systemd-sysvcompat is installed
setting init directly didnt help either.

Some more config files:
arch.conf:

title   Arch Linux
linux   /vmlinuz-linux
initrd  /intel-ucode.img
initrd  /initramfs-linux.img
options root=PARTUUID=9e841bee-c464-45a4-b643-72a06c8dc992 resume=PARTUUID=9e841bee-c464-45a4-b643-72a06c8dc992 resume_offset=399360 rw

fstab:

# 
# /etc/fstab: static file system information
#
# <file system>	<dir>	<type>	<options>	<dump>	<pass>
# /dev/sda2
UUID=e7783d8a-c48d-480f-9870-95e80edf3fe6	/         		ext4      	defaults,noatime,discard	0 1

# /dev/sda1
UUID=6B9C-06C8      				/boot     		vfat      	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro	0 2

# /home/schmodd/Data
UUID=fdde433e-49c9-4089-9116-d2d25f9a2b3a	/home/schmodd/data      ext4		rw,relatime,data=ordered	0 2

# /swapfile
/swapfile none swap defaults 0 0

blkid

/dev/sda1: UUID="6B9C-06C8" TYPE="vfat" PARTLABEL="boot" PARTUUID="f896c72f-96bc-4518-88d2-4c8425448b91"
/dev/sda2: UUID="e7783d8a-c48d-480f-9870-95e80edf3fe6" TYPE="ext4" PARTLABEL="root" PARTUUID="9e841bee-c464-45a4-b643-72a06c8dc992"
/dev/sdb1: LABEL="homedata" UUID="fdde433e-49c9-4089-9116-d2d25f9a2b3a" TYPE="ext4" PARTUUID="e538513d-0515-4791-b454-a05224bb769f"

mkinitcpio.conf

# vim:set ft=sh
# MODULES
# The following modules are loaded before any boot hooks are
# run.  Advanced users may wish to specify all system modules
# in this array.  For instance:
#     MODULES="piix ide_disk reiserfs"
#MODULES="nvidia nvidia_modeset nvidia_uvm nvidia_drm"
MODULES=""

# BINARIES
# This setting includes any additional binaries a given user may
# wish into the CPIO image.  This is run last, so it may be used to
# override the actual binaries included by a given hook
# BINARIES are dependency parsed, so you may safely ignore libraries
BINARIES=""

# FILES
# This setting is similar to BINARIES above, however, files are added
# as-is and are not parsed in any way.  This is useful for config files.
FILES=""

# HOOKS
# This is the most important setting in this file.  The HOOKS control the
# modules and scripts added to the image, and what happens at boot time.
# Order is important, and it is recommended that you do not change the
# order in which HOOKS are added.  Run 'mkinitcpio -H <hook name>' for
# help on a given hook.
# 'base' is _required_ unless you know precisely what you are doing.
# 'udev' is _required_ in order to automatically load modules
# 'filesystems' is _required_ unless you specify your fs modules in MODULES
# Examples:
##   This setup specifies all modules in the MODULES setting above.
##   No raid, lvm2, or encrypted root is needed.
#    HOOKS="base"
#
##   This setup will autodetect all modules for your system and should
##   work as a sane default
#    HOOKS="base udev autodetect block filesystems"
#
##   This setup will generate a 'full' image which supports most systems.
##   No autodetection is done.
#    HOOKS="base udev block filesystems"
#
##   This setup assembles a pata mdadm array with an encrypted root FS.
##   Note: See 'mkinitcpio -H mdadm' for more information on raid devices.
#    HOOKS="base udev block mdadm encrypt filesystems"
#
##   This setup loads an lvm2 volume group on a usb device.
#    HOOKS="base udev block lvm2 filesystems"
#
##   NOTE: If you have /usr on a separate partition, you MUST include the
#    usr, fsck and shutdown hooks.
#HOOKS="base udev resume autodetect modconf block filesystems keyboard fsck"
HOOKS="base udev resume autodetect modconf block filesystems keyboard fsck"

# COMPRESSION
# Use this to compress the initramfs image. By default, gzip compression
# is used. Use 'cat' to create an uncompressed image.
#COMPRESSION="gzip"
#COMPRESSION="bzip2"
#COMPRESSION="lzma"
#COMPRESSION="xz"
#COMPRESSION="lzop"
#COMPRESSION="lz4"

# COMPRESSION_OPTIONS
# Additional options for the compressor
#COMPRESSION_OPTIONS=""

/boot

drwxr-xr-x    4 root     root          4096 Oct 10  2015 EFI
-rwxr-xr-x    1 root     root      17278744 Aug 12 16:34 initramfs-linux-fallback.img
-rwxr-xr-x    1 root     root       2013855 Aug 12 16:34 initramfs-linux.img
-rwxr-xr-x    1 root     root        947712 Jul 22 12:02 intel-ucode.img
drwxr-xr-x    3 root     root          4096 Aug 12 15:19 loader
-rwxr-xr-x    1 root     root       4699936 Aug  8 20:07 vmlinuz-linux

Last edited by schmodd (2016-08-12 17:20:22)

Offline

#6 2016-08-12 20:23:34

reztho
Member
Registered: 2007-12-16
Posts: 43

Re: Failed to execute /init (error -2) after pacman -Syu

It's affecting me too.

The interesting thing is that it seems it has nothing to do with the new kernel (4.7).

I had a running LTS kernel and a non-running regular kernel (4.7), then I did a mkinitcpio -P and then even the LTS kernel couldn't find the /init from its initramfs.

I've recovered my system from a previous backup, so I'll experiment a bit...

Offline

#7 2016-08-12 20:32:44

schmodd
Member
Registered: 2015-02-12
Posts: 33

Re: Failed to execute /init (error -2) after pacman -Syu

Thanks for letting me know. I also tried downgrading. No success.

Offline

#8 2016-08-12 22:08:44

reztho
Member
Registered: 2007-12-16
Posts: 43

Re: Failed to execute /init (error -2) after pacman -Syu

Sorry, schmodd. I can't reproduce the problem anymore.

Offline

#9 2016-08-13 10:36:07

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: Failed to execute /init (error -2) after pacman -Syu

Please post the output of:

# mount /dev/sda1 /mnt && ls /mnt
# gdisk -l /dev/sda

Have you updated the systemd-boot loader?

# bootctl update

Ensure that /dev/sda1 is (auto)mounted to /boot before running that command.

# grep sda1 /proc/self/mounts

EDIT: Also, try using "root=/dev/sda2" instead of the PARTUUID in the "options" section of the systemd-boot configuration file.

Last edited by Head_on_a_Stick (2016-08-13 10:37:50)

Offline

#10 2016-08-13 10:48:18

schmodd
Member
Registered: 2015-02-12
Posts: 33

Re: Failed to execute /init (error -2) after pacman -Syu

Sorry, but I'am currently wiping the disk and setting it up again.

But I can remember what I tried:
I did bootctl update. Still the same error.
I even did "bootctl install" ... it all didnt help.

Will report back if fresh install succeeded.

Offline

#11 2016-08-13 16:50:04

r3pek
Member
From: Beja, Portugal
Registered: 2013-06-08
Posts: 8
Website

Re: Failed to execute /init (error -2) after pacman -Syu

Exactly the same problem here. I'm just using Grub instead of systemd-boot. Any solution? (Downgrading the kernel didn't help)

Offline

#12 2016-08-13 16:57:38

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: Failed to execute /init (error -2) after pacman -Syu

@r3pek -- please list the contnets of your ESP and confirm that /boot and the ESP were mounted correctly during the upgrade.

Offline

#13 2016-08-13 17:00:35

r3pek
Member
From: Beja, Portugal
Registered: 2013-06-08
Posts: 8
Website

Re: Failed to execute /init (error -2) after pacman -Syu

They were.... Just reinstalled the kernel on a chroot twice. Esp have all the files there (kernel and initrd).

Sorry for not listing the contents but I'm typing on my phone.

Last edited by r3pek (2016-08-13 17:01:03)

Offline

#14 2016-08-13 17:15:47

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: Failed to execute /init (error -2) after pacman -Syu

r3pek wrote:

Sorry for not listing the contents but I'm typing on my phone.

You can use a pastebin client to generate a URL that can be posted instead:
https://wiki.archlinux.org/index.php?ti … in_clients

Have you tried re-installing the GRUB bootloader to your disk and re-configuring?

Offline

#15 2016-08-13 17:38:25

r3pek
Member
From: Beja, Portugal
Registered: 2013-06-08
Posts: 8
Website

Re: Failed to execute /init (error -2) after pacman -Syu

Yes... I reinstalled Grub and jus tried with systemd-boot and it also gives the same error

Offline

#16 2016-08-13 17:44:44

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: Failed to execute /init (error -2) after pacman -Syu

r3pek wrote:

jus tried with systemd-boot and it also gives the same error

Please provide the relevant configuration files and the output of:

# efibootmgr -v

Is your ESP mounted to /boot?

Offline

#17 2016-08-13 18:05:16

r3pek
Member
From: Beja, Portugal
Registered: 2013-06-08
Posts: 8
Website

Re: Failed to execute /init (error -2) after pacman -Syu

OK I solved the problem.

Thing is, for some reason (I think a package upgrade some time ago), I had to remove /usr/lib64 because of a file conflict, and I didn't recreate it because o thought the package would. Since it didn't, I had missing files on the initrd and so, it couldn't boot anymore. I just had to reinstall the "filesystem" package and everything booted fine again (grub and systemd-boot).

Thanks again for your help!

Offline

#18 2016-08-16 14:55:04

schmodd
Member
Registered: 2015-02-12
Posts: 33

Re: Failed to execute /init (error -2) after pacman -Syu

My reinstall works, so I may have had the same problem like you.

Offline

Board footer

Powered by FluxBB