You are not logged in.

#1 2012-11-09 19:58:55

oeufcoque
Member
Registered: 2012-11-09
Posts: 19
Website

[Solved] WARNING: No modules were added to the image. This is probably

I've had this problem for the past 3 upgrades of the package "linux"

This happens when I run "mkinitcpio"

==> Starting dry run: 3.6.6-1-ARCH
  -> Running build hook: [base]
  -> Running build hook: [udev]
  -> Running build hook: [autodetect]
/usr/lib/initcpio/install/autodetect: line 26: _autodetect_cache["$m"]: bad array subscript
==> WARNING: No modules were added to the image. This is probably not what you want.
==> Dry run complete, use -g IMAGE to generate a real image

Why is this happening?

I temporary solve it by:
1. booting a live disk
2. mounting root and boot
3. chrooting
4. pacman -S linux

Then it generates initramfs without errors.

Last edited by oeufcoque (2012-11-09 21:40:34)

Offline

#2 2012-11-09 20:08:15

Raynman
Member
Registered: 2011-10-22
Posts: 1,154

Re: [Solved] WARNING: No modules were added to the image. This is probably

Related? https://bugs.archlinux.org/task/32532

Last edited by Raynman (2012-11-09 20:08:52)

Offline

#3 2012-11-09 20:09:36

illusionist
Member
From: localhost
Registered: 2012-04-03
Posts: 498

Re: [Solved] WARNING: No modules were added to the image. This is probably

Post your mkinitcpio.conf .
EDIT: Looking at the bug report .... are you running custom kernel ?

Last edited by illusionist (2012-11-09 20:10:51)


  Never argue with stupid people,They will drag you down to their level and then beat you with experience.--Mark Twain
@github

Offline

#4 2012-11-09 20:28:53

oeufcoque
Member
Registered: 2012-11-09
Posts: 19
Website

Re: [Solved] WARNING: No modules were added to the image. This is probably

That's the error I'm getting, it's not related to a custom kernel though

illusionist wrote:

Post your mkinitcpio.conf .
EDIT: Looking at the bug report .... are you running custom kernel ?

No I'm not running a custom kernel

Here is my /etc/mkinitcpio.conf.
It's the default one except for the "encrypt" and "usb" hook I believe.

# 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=""

# 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.
# Some users may wish to include modprobe.conf for custom module options
# like so:
#    FILES="/etc/modprobe.d/modprobe.conf"
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 pata scsi sata filesystems"
#
##   This is identical to the above, except the old ide subsystem is
##   used for IDE devices instead of the new pata subsystem.
#    HOOKS="base udev autodetect ide scsi sata filesystems"
#
##   This setup will generate a 'full' image which supports most systems.
##   No autodetection is done.
#    HOOKS="base udev pata scsi sata usb 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 pata mdadm encrypt filesystems"
#
##   This setup loads an lvm2 volume group on a usb device.
#    HOOKS="base udev usb lvm2 filesystems"
#
##   NOTE: If you have /usr on a separate partition, you MUST include the
#    usr, fsck and shutdown hooks.
HOOKS="base udev autodetect pata scsi sata usb encrypt filesystems usbinput 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_OPTIONS
# Additional options for the compressor
#COMPRESSION_OPTIONS=""

I should note that in step 4 when I run "pacman -S linux" it simply re-installs the kernel and runs mkinitcpio successfully.

But if I run "mkinitcpio -p linux" in the same shell I get the error.

Offline

#5 2012-11-09 20:39:26

illusionist
Member
From: localhost
Registered: 2012-04-03
Posts: 498

Re: [Solved] WARNING: No modules were added to the image. This is probably

Remove autodetect and then try to make the image.


  Never argue with stupid people,They will drag you down to their level and then beat you with experience.--Mark Twain
@github

Offline

#6 2012-11-09 21:12:32

oeufcoque
Member
Registered: 2012-11-09
Posts: 19
Website

Re: [Solved] WARNING: No modules were added to the image. This is probably

illusionist wrote:

Remove autodetect and then try to make the image.

The image is created successfully at the moment, this error only happened the last few times the "linux" package was upgraded.

I'll remove autodetect from the hooks for now, and see if it solves the problem next time. Running "mkinitcpio -H autodetect" I see it's only there to shrink the image, which isn't a priority for me.

I took a look into the ".INSTALL" file in the "linux" package, and I noticed it also runs "mkinitcpio -p linux".

The only difference I can see is that it sets the PATH variable in the beginning, as well as the KERNEL_VERSION variable and then uses this value when running the command:

depmod ${KERNEL_VERSION}

And then it runs "mkinitcpio -p linux" successfully.

Offline

#7 2012-11-09 21:23:12

illusionist
Member
From: localhost
Registered: 2012-04-03
Posts: 498

Re: [Solved] WARNING: No modules were added to the image. This is probably

A little off-topic ..
You should have a look here too.
Optimizing Bootup


  Never argue with stupid people,They will drag you down to their level and then beat you with experience.--Mark Twain
@github

Offline

#8 2012-11-09 21:39:52

oeufcoque
Member
Registered: 2012-11-09
Posts: 19
Website

Re: [Solved] WARNING: No modules were added to the image. This is probably

illusionist wrote:

A little off-topic ..
You should have a look here too.
Optimizing Bootup

Thank you. I'm not interested in optimizing or speeding up the boot time, but I can see how it may help me troubleshoot the issue next time.

I'll mark the topic is as solved for now, since I don't have a way to try it out without downgrading.

Offline

Board footer

Powered by FluxBB