FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian Kernel

 
 
LinkBack Thread Tools
 
Old 02-10-2011, 04:48 PM
maximilian attems
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

On Thu, Feb 10, 2011 at 05:18:46PM +0100, Benedikt Spranger wrote:
> Am Thu, 10 Feb 2011 13:52:27 +0000
> schrieb maximilian attems <max@stro.at>:
>
> > > Sadly the generated initramfs has the same problem.
> >
> > which would be what, can we have the error message please?
> > (if not possible to keep logging netconsole comes handy).
> lvm: error while loading shared libraries: libgcc_s.so.1: cannot open
> shared object file: No such file or directory.
>
> If I copy "libgcc_s.so" from /usr/local/lib to /usr/lib in the
> initramfs image everything works fine.

what does on that box 'ldconfig -p' show?



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110210174836.GE5862@vostochny.stro.at">http://lists.debian.org/20110210174836.GE5862@vostochny.stro.at
 
Old 02-10-2011, 05:33 PM
Benedikt Spranger
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

Am Thu, 10 Feb 2011 17:48:36 +0000
schrieb maximilian attems <max@stro.at>:

> On Thu, Feb 10, 2011 at 05:18:46PM +0100, Benedikt Spranger wrote:
> > Am Thu, 10 Feb 2011 13:52:27 +0000
> > schrieb maximilian attems <max@stro.at>:
> >
> > > > Sadly the generated initramfs has the same problem.
> > >
> > > which would be what, can we have the error message please?
> > > (if not possible to keep logging netconsole comes handy).
> > lvm: error while loading shared libraries: libgcc_s.so.1: cannot
> > open shared object file: No such file or directory.
> >
> > If I copy "libgcc_s.so" from /usr/local/lib to /usr/lib in the
> > initramfs image everything works fine.
>
> what does on that box 'ldconfig -p' show?

I can send the over 1600 lines, but i think it is very useless.
Another try to explain the problem:

1) I have a local installed gcc:
$ ls -l /usr/local/lib/libgcc*
lrwxrwxrwx 1 root staff 13 12. Jan 15:56 /usr/local/lib/libgcc_s.so -> libgcc_s.so.1
-rw-r--r-- 1 root staff 451923 12. Jan
15:56 /usr/local/lib/libgcc_s.so.1

2) "lvm" needs "libgcc_s.so.1"
$ ldd /sbin/lvm
linux-gate.so.1 => (0xb7852000)
libdl.so.2 => /lib/i686/cmov/libdl.so.2 (0xb782b000)
libreadline.so.5 => /lib/libreadline.so.5 (0xb77f8000)
libdevmapper.so.1.02.1 => /lib/libdevmapper.so.1.02.1 (0xb77d5000)
libudev.so.0 => /lib/libudev.so.0 (0xb77c7000)
libc.so.6 => /lib/i686/cmov/libc.so.6 (0xb7681000)
/lib/ld-linux.so.2 (0xb7853000)
libncurses.so.5 => /lib/libncurses.so.5 (0xb7647000)
libgcc_s.so.1 => /usr/local/lib/libgcc_s.so.1 (0xb762a000)
libselinux.so.1 => /lib/libselinux.so.1 (0xb760e000)

3) create a initramfs:
$ /usr/sbin/mkinitramfs -o /tmp/fooo.bad 2.6.32-5-686

4) uncompress and extract /tmp/fooo.bad
# mkdir initramfs
# cd initramfs
# gzip -cd /tmp/fooo.bad | sudo cpio -i

5) move libgcc_s.so.1 from /usr/local/lib to /usr/lib
# mv usr/local/lib/libgcc_s.so.1 usr/lib

6) archive and compress the initrd
# find . | cpio -H newc -o > /tmp/fooo.1
# gzip -9f /tmp/fooo.1
# mv /tmp/fooo.1.gz /tmp/fooo.good

7) reboot and use initramfs fooo.bad
ERROR: lvm cannot start due to
lvm: error while loading shared libraries: libgcc_s.so.1:
cannot open shared object file: No such file or directory.

ends up in initramfs shell.

8) reboot and use initramfs fooo.good
Everything works fine.

Regards
Bene



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110210193317.5542ae0a@ariane.spranger.biz">http://lists.debian.org/20110210193317.5542ae0a@ariane.spranger.biz
 
Old 02-10-2011, 08:39 PM
maximilian attems
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

tags 612633 moreinfo
stop

On Thu, Feb 10, 2011 at 07:33:17PM +0100, Benedikt Spranger wrote:
> Am Thu, 10 Feb 2011 17:48:36 +0000
> schrieb maximilian attems <max@stro.at>:
>
> > what does on that box 'ldconfig -p' show?
>
> I can send the over 1600 lines, but i think it is very useless.

No it isn't. Send it attached and compressed, can't be that big.

> Another try to explain the problem:

Hehe, a late reply to the question if lvm did or does work.

thank you.

--
maks




--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110210213951.GF5862@vostochny.stro.at">http://lists.debian.org/20110210213951.GF5862@vostochny.stro.at
 
Old 02-11-2011, 07:47 AM
Benedikt Spranger
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

Am Thu, 10 Feb 2011 21:39:51 +0000
schrieb maximilian attems <max@stro.at>:

> On Thu, Feb 10, 2011 at 07:33:17PM +0100, Benedikt Spranger wrote:
> > Am Thu, 10 Feb 2011 17:48:36 +0000
> > schrieb maximilian attems <max@stro.at>:
> > > what does on that box 'ldconfig -p' show?
Output attached.

Regards
Bene
 
Old 02-16-2011, 09:58 AM
maximilian attems
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

On Fri, 11 Feb 2011, Benedikt Spranger wrote:

> Am Thu, 10 Feb 2011 21:39:51 +0000
> schrieb maximilian attems <max@stro.at>:
>
> > On Thu, Feb 10, 2011 at 07:33:17PM +0100, Benedikt Spranger wrote:
> > > Am Thu, 10 Feb 2011 17:48:36 +0000
> > > schrieb maximilian attems <max@stro.at>:
> > > > what does on that box 'ldconfig -p' show?
> Output attached.
>

I see, and then we would need the ldconfig from inside the broken
initramfs, so you need

A) add ldconfig inside the initramfs
echo "copy_exec /sbin/ldconfig /bin/" >> /usr/share/initramfs-tools/hooks/busybox

B) generate the resulting initramfs
(with the patched mkinitramfs adding /etc/ld.so.conf* to initramfs)

mkinitramfs -o /tmp/foo.broken

C) unpack that initramfs

mkdir /tmp/la && cd /tmp/la; zcat ../foo.broken | cpio -i

D) chroot into it

chroot ./ /bin/sh

E) run ldconfig three times:
(first invocation should tell that no cache around, second should
built it and we need output of third)
ldconfig -p
ldconfig
ldconfig -p

thank you!

--
maks



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110216105818.GA4773@stro.at">http://lists.debian.org/20110216105818.GA4773@stro.at
 
Old 02-16-2011, 10:19 AM
Benedikt Spranger
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

Am Wed, 16 Feb 2011 11:58:18 +0100
schrieb maximilian attems <max@stro.at>:

> E) run ldconfig three times:
> (first invocation should tell that no cache around, second should
> built it and we need output of third)
> ldconfig -p
# ldconfig -p
0 libs found in cache `/etc/ld.so.cache'

> ldconfig
> ldconfig -p
# ldconfig -p
32 libs found in cache `/etc/ld.so.cache'
libz.so.1 (libc6) => /usr/lib/libz.so.1
libuuid.so.1 (libc6) => /lib/libuuid.so.1
libudev.so.0 (libc6) => /lib/libudev.so.0
libsysfs.so.2 (libc6) => /lib/libsysfs.so.2
libsplashycnf.so.1 (libc6) => /lib/libsplashycnf.so.1
libsplashy.so.1 (libc6) => /lib/libsplashy.so.1
libselinux.so.1 (libc6) => /lib/libselinux.so.1
librt.so.1 (libc6, OS ABI: Linux 2.6.18) => /lib/librt.so.1
libreadline.so.5 (libc6) => /lib/libreadline.so.5
libpthread.so.0 (libc6, OS ABI: Linux 2.6.18) => /lib/libpthread.so.0
libpopt.so.0 (libc6) => /lib/libpopt.so.0
libpng12.so.0 (libc6) => /lib/libpng12.so.0
libpcre.so.3 (libc6) => /lib/libpcre.so.3
libncurses.so.5 (libc6) => /lib/libncurses.so.5
libm.so.6 (libc6, OS ABI: Linux 2.6.18) => /lib/libm.so.6
liblzo2.so.2 (libc6) => /usr/lib/liblzo2.so.2
libgpg-error.so.0 (libc6) => /lib/libgpg-error.so.0
libglib-2.0.so.0 (libc6) => /lib/libglib-2.0.so.0
libgcrypt.so.11 (libc6) => /lib/libgcrypt.so.11
libgcc_s.so.1 (libc6) => /usr/local/lib/libgcc_s.so.1
libfusion-1.2.so.9 (libc6) => /usr/lib/libfusion-1.2.so.9
libfreetype.so.6 (libc6) => /usr/lib/libfreetype.so.6
libdl.so.2 (libc6, OS ABI: Linux 2.6.18) => /lib/libdl.so.2
libdirectfb-1.2.so.9 (libc6) => /usr/lib/libdirectfb-1.2.so.9
libdirect-1.2.so.9 (libc6) => /usr/lib/libdirect-1.2.so.9
libdevmapper.so.1.02.1 (libc6) => /lib/libdevmapper.so.1.02.1
libctutils.so.0 (libc6) => /lib/libctutils.so.0
libconsole.so.0 (libc6) => /lib/libconsole.so.0
libcfont.so.0 (libc6) => /lib/libcfont.so.0
libc.so.6 (libc6, OS ABI: Linux 2.6.18) => /lib/libc.so.6
libblkid.so.1 (libc6) => /lib/libblkid.so.1
ld-linux.so.2 (ELF) => /lib/ld-linux.so.2

Regards
Bene



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110216121910.23ef78c6@ariane.spranger.biz">http://lists.debian.org/20110216121910.23ef78c6@ariane.spranger.biz
 
Old 02-16-2011, 11:16 AM
maximilian attems
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

On Wed, Feb 16, 2011 at 12:19:10PM +0100, Benedikt Spranger wrote:
> Am Wed, 16 Feb 2011 11:58:18 +0100
> schrieb maximilian attems <max@stro.at>:
>
> > E) run ldconfig three times:
> > (first invocation should tell that no cache around, second should
> > built it and we need output of third)
> > ldconfig -p
> # ldconfig -p
> 0 libs found in cache `/etc/ld.so.cache'
>
> > ldconfig
> > ldconfig -p
> # ldconfig -p
> 32 libs found in cache `/etc/ld.so.cache'
[..]
> libgcc_s.so.1 (libc6) => /usr/local/lib/libgcc_s.so.1

cool, so now it would boot.

Thanks for your report, this means quite some work to resolve
that bug as ldconfig can't work against the symlinked tree
of initramfs-tools in ${DESTDIR}.
Will see to sort out that mess next days.

--
maks



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110216121637.GN5862@vostochny.stro.at">http://lists.debian.org/20110216121637.GN5862@vostochny.stro.at
 
Old 02-16-2011, 11:22 AM
maximilian attems
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

On Wed, Feb 16, 2011 at 12:19:10PM +0100, Benedikt Spranger wrote:
> libsplashycnf.so.1 (libc6) => /lib/libsplashycnf.so.1
> libsplashy.so.1 (libc6) => /lib/libsplashy.so.1

unrelated to that bug, I'd recommed plymouth.

ps untagged moreinfo.



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110216122219.GO5862@vostochny.stro.at">http://lists.debian.org/20110216122219.GO5862@vostochny.stro.at
 
Old 02-27-2011, 07:37 PM
maximilian attems
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

hello,

added last week the branch maks/mkinitramfs_cp on top of the initial
fix runndinig ldconfig on the initramfs root:
http://git.debian.org/?p=kernel/initramfs-tools.git;a=shortlog;h=refs/heads/maks/mkinitramfs_cp

a snapshot based on this patch is available:
http://charm.itp.tuwien.ac.at/~mattems/initramfs-tools_0.98.9~1.gbp5f06ec_all.deb
it's signature
http://charm.itp.tuwien.ac.at/~mattems/initramfs-tools_0.98.9~1.gbp5f06ec_all.deb.sha512sum.asc

could you test if that boots your setup out of the box?
(snapshot has minimal qemu + my own laptop testing)

thank you.

--
maks



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110227203722.GA2867@stro.at">http://lists.debian.org/20110227203722.GA2867@stro.at
 
Old 02-28-2011, 01:29 PM
Benedikt Spranger
 
Default Bug#612633: initramfs-tools: mkinitramfs creates non working initramfs

Hi,

> a snapshot based on this patch is available:
> http://charm.itp.tuwien.ac.at/~mattems/initramfs-tools_0.98.9~1.gbp5f06ec_all.deb
> it's signature
> http://charm.itp.tuwien.ac.at/~mattems/initramfs-tools_0.98.9~1.gbp5f06ec_all.deb.sha512sum.asc
> could you test if that boots your setup out of the box?
> (snapshot has minimal qemu + my own laptop testing)

I tested this snapshot (build and installed a new kernel/initrd;
update existing initrd). It works like a charm.
Feel free to add a

Tested-by: Benedikt Spranger <b.spranger@linutronix.de>

Thanks
Bene



--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20110228152936.7509868b@ariane.spranger.biz">http://lists.debian.org/20110228152936.7509868b@ariane.spranger.biz
 

Thread Tools




All times are GMT. The time now is 02:51 PM.

VBulletin, Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org