Bug#948257: depmod: ERROR: ../libkmod/libkmod.c:515 lookup_builtin_file() could not open builtin file '/var/tmp/mkinitramfs_N1a1Mk/lib/modules/5.4.0-1-amd64/modules.builtin.bin'
Bjørn Mork <bjorn@mork.no> writes:
> Marco d'Itri <md@Linux.IT> writes:
>
>> Control: severity -1 normal
>> Control: tags -1 patch
>> Control: reassign -1 initramfs-tools
>>
>> On Jan 06, crvi <crvisqr@gmail.com> wrote:
>>
>>> * What outcome did you expect instead?
>>>
>>> Successful ramfs generation
>> Do you have any reason to believe that the initrfamfs was not generated
>> successfully?
>>
>> This is only cosmetic, and it needs to be fixed in /usr/sbin/mkinitramfs
>> by copying modules.builtin.bin too:
>>
>> -for x in modules.builtin modules.order; do
>> +for x in modules.builtin modules.builtin.bin modules.order; do
>
> modules.builtin.bin is created, and always regenerated, by depmod based
> on modules.builtin. Requiring modules.builtin.bin to exist before
> running depmod makes no sense at all.
>
> So what change made depmod spit out this pointless warning? You should
> fix that bug instead insisting that some other package paper over it.
FYI: the bug is Debian-specific and introduced long ago with this patch:
bjorn@miraculix:/tmp/kmod-26+20191223$ cat debian/patches/verbose_missing_bin
Description: Report an error when some .bin files do not exist
Author: Marco d'Itri <md@linux.it>
Bug-Debian: http://bugs.debian.org/684901
---
--- a/libkmod/libkmod.c
+++ b/libkmod/libkmod.c
@@ -503,7 +503,7 @@ static char *lookup_builtin_file(struct
idx = index_file_open(fn);
if (idx == NULL) {
- DBG(ctx, "could not open builtin file '%s'\n", fn);
+ ERR(ctx, "could not open builtin file '%s'\n", fn);
return NULL;
}
@@ -575,7 +575,7 @@ char *kmod_search_moddep(struct kmod_ctx
idx = index_file_open(fn);
if (idx == NULL) {
- DBG(ctx, "could not open moddep file '%s'\n", fn);
+ ERR(ctx, "could not open moddep file '%s'\n", fn);
return NULL;
}
Non-existing files is expected for libkmod in some situations, like the
current example when depmod is looking up a module while generating
dependencies for it.
Bjørn
Reply to: