All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-lvm] Problems with initrd for LVM2 on 2.6.0-test8 and -test9 kernels.. .
@ 2003-10-29 17:53 Weber, Geoffrey M.
  2003-10-30  7:50 ` Luca Berra
  0 siblings, 1 reply; 4+ messages in thread
From: Weber, Geoffrey M. @ 2003-10-29 17:53 UTC (permalink / raw)
  To: 'linux-lvm@sistina.com'

[-- Attachment #1: Type: text/plain, Size: 1471 bytes --]

Greetings all,

I have been having quite a few problems getting a server I am setting up to
use root on a LVM2 setup.  I used the "lvmcreate_initrd" script as suggested
on the 'net, and also tried to hand-edit some of the LVM2 requirements into
that initrd image (such as the /dev/mapper/control mknod command from the
initialization script and /lib/devmapper.so library).  As soon as I try to
use LILO or GRUB with the "root=/dev/vg00/root" or "root=3f00" (device major
and minor numbers), my machine hangs after "Uncompressing Linux... Ok,
booting the kernel.".

I have also tried (unsuccessfully) to use an initrd image I found on the
'net at http://www.comedia.it/~bluca/cooker/lvm2/

.. and also tried modifying this to work (along with the evms-supplied
initrd image).  All hang at the same point.  I got an idea to start a shell
inside the initrd image when booting on my setup root partition to see what
I could find out. When trying to use the Busybox "ash" command inside the
modified evms initrd image, however, the machine doesn't halt and give me a
shell at all but keeps booting.

Is there something that I can try out or that I am overlooking?

Thanks,
    Geoff



NOTICE: This electronic mail transmission may contain confidential
information and is intended only for the person(s) named.  Any use, copying
or disclosure by any other person is strictly prohibited. If you have
received this transmission in error, please notify the sender via e-mail.




[-- Attachment #2: Type: text/html, Size: 2225 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [linux-lvm] Problems with initrd for LVM2 on 2.6.0-test8 and -test9 kernels.. .
  2003-10-29 17:53 Weber, Geoffrey M.
@ 2003-10-30  7:50 ` Luca Berra
  0 siblings, 0 replies; 4+ messages in thread
From: Luca Berra @ 2003-10-30  7:50 UTC (permalink / raw)
  To: Weber, Geoffrey M.; +Cc: 'linux-lvm@sistina.com'

On Wed, Oct 29, 2003 at 09:26:14AM -0600, Weber, Geoffrey M. wrote:
>   library).    As   soon  as  I  try  to  use  LILO  or  GRUB  with  the
>   "root=/dev/vg00/root" or "root=3f00" (device major and minor numbers),
>   my  machine  hangs  after  "Uncompressing  Linux...  Ok,  booting  the
>   kernel.".
could you give us some more details about your setup, including actual
lines from your configuration.

>   I  have  also tried (unsuccessfully) to use an initrd image I found on
>   the 'net at [1]http://www.comedia.it/~bluca/cooker/lvm2/

There is no initrd image at that location.
What you find there is modified Mandrake rpm to support lvm2 in Mandrake
Linux 9.2/cooker, and has not been tested with anything different than
that.

>   to  see  what  I  could find out. When trying to use the Busybox "ash"
>   command  inside  the  modified evms initrd image, however, the machine
>   doesn't halt and give me a shell at all but keeps booting.
i saw this problem as well, i don't know if it is caused by some device
file missing in the initrd image or what.

L.

-- 
Luca Berra -- bluca@comedia.it
        Communication Media & Services S.r.l.
 /"\
 \ /     ASCII RIBBON CAMPAIGN
  X        AGAINST HTML MAIL
 / \

^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: [linux-lvm] Problems with initrd for LVM2 on 2.6.0-test8 and  -test9 kernels.. .
@ 2003-10-30 16:54 Weber, Geoffrey M.
  2003-10-31  2:17 ` 'Luca Berra '
  0 siblings, 1 reply; 4+ messages in thread
From: Weber, Geoffrey M. @ 2003-10-30 16:54 UTC (permalink / raw)
  To: 'Luca Berra '; +Cc: ''linux-lvm@sistina.com' '

[-- Attachment #1: Type: text/plain, Size: 6075 bytes --]

My apologies for not providing the information earlier... and for my mistake
in supplying the link to my initrd image.  I have been bookmarking sites
like mad and apparently chose the wrong one...

Here is my linuxrc inside the initrd image (this is the one based off of the
evms initrd I found on the web, since it seemed the most complete).

Please note that I still can't get the "/bin/ash" command to work properly,
though I'm working on it.  I did put in the /dev/tty* and /dev/pt* nodes
into the initrd image, but still no luck.  



-------- CUT --------

gweber@windforce:/tmp/test$ more linuxrc
#!/bin/sh
/bin/mount /proc
echo /sbin/modprobe > /proc/sys/kernel/modprobe
if test ! -e /dev/.devfsd ; then
        set -e
        MAJOR=$(/bin/sed -n 's/^ *\([0-9]\+\) \+misc$/\1/p' /proc/devices)
        MINOR=$(/bin/sed -n 's/^ *\([0-9]\+\) \+device-mapper$/\1/p'
/proc/misc
)
        if test -n "$MAJOR" -a -n "$MINOR" ; then
                /bin/mknod --mode=600 /dev/mapper/control c $MAJOR $MINOR
        fi
fi
/sbin/lvm vgchange --ignorelockingfailure -P -a y
/bin/ash
/bin/umount /proc

-------- CUT --------

Also note that I have tried "root=0a3f", "root=fe00", and
"root=/dev/vg00/root"... the major/minor numbers are listed here (from
/dev/hda4 "temporary install" root):

-------- CUT --------

gweber@windforce:~$ ls -l /dev/mapper
crw-------    1 root     root      10,  63 Oct 27 13:34 control
brw-------    1 root     root     254,   1 Oct 22 08:56 vg00-home
brw-------    1 root     root     254,   0 Oct 22 08:56 vg00-root
brw-------    1 root     root     254,   3 Oct 29 08:21 vg00-tmp
brw-------    1 root     root     254,   4 Oct 29 08:21 vg00-usr
brw-------    1 root     root     254,   2 Oct 29 08:21 vg00-var

-------- CUT --------

In order to (try to) make this work, I did copy all the "missing" binaries,
libs, and dev nodes into the evms initrd image.  I would supply that
listing, but it would be quite long...

Here is my menu.lst from grub.  I've been testing with grub just so that I
could enter changes at boot time instead of running "lilo" all over the
place.

-------- CUT --------

gweber@windforce:/tmp/test$ more menu.lst
# Author: Luis R. Rodriguez <mcgrof@ruslug.rutgers.edu>
# GRUB configuration example file

# Should give you an idea of how to use GRUB to dual boot

# This makes Linux the default ;) Use 1 if you want Windows as default
default=1

# This means that from now on, GRUB will parse / as (hd0,0)/
root    (hd0,3)

# Fun splashimage ;-)
# Check http://ruslug.rutgers.edu/~mcgrof/grub-images for a HOWTO
# on making GRUB splashimages.
#
# I recommend putting all GRUB splashimages in /boot/grub/images
# to not bloat the /boot/grub directory ;)
splashimage (hd0,0)/grub/images/debian_cooleye-dither.xpm.gz

# vga=xxx sets the framebuffer console to a specific resolution.
# Here is a table you can use so it can help you decide
# what resolution you want to use:
#       colour          depth   | 640x480  800x600  1024x768 1280x1024
#       256             (8bit)  |  769      771       773      775
#       32000           (15bit) |  784      787       790      793
#       65000           (16bit) |  785      788       791      794
#       16.7 Mill.      (24bit) |  786      789       792      795


# As you will see I have my kernels in /boot/kernels/
# I have found that GRUB allows for a easy-to-use structured and neat
# /boot/ directory. My /boot/ has:
# configs/ kernels/ initrds/ System.maps/ vmlinuxes/
# Looks much nicer than the bloated default /boot/ most distributions use :P

# Ugh... :( you poor thing
#title  Windows XP
#rootnoverify   (hd0,0)
# Windows 9x, ME line: chainloader+1
# WIndows XP line:
#chainloader = (hd0,0)+1

# Yay, viva gorditas
#title  Debian/X11/GNOME/GNU/etc Linux (2.4.18-bf2.4)
#kernel /boot/kernels/vmlinuz-2.4.18-bf2.4 root=/dev/hda5 console=ttys0
vga=791
title   Linux (2.6.0-lvm)
kernel  (hd0,0)/vmlinuz-2.6.0-test9-aa0.2 root=fe00 console=ttys0
initrd  (hd0,0)/initrd-gw.gz

title   Linux (2.6.0)
kernel  (hd0,0)/boot/vmlinuz-2.6.0-test9-aa0.2 root=/dev/hda4 console=ttys0
vga
=791
#initrd  (hd0,3)/boot/initrd-lvm-2.6.0-test8-aa0.1.gz

title   Linux (2.4.22-xfs)
kernel  (hd0,3)/boot/vmlinuz-2.4.22-xfs root=/dev/hda4 console=ttys0 vga=791
initrd  (hd0,3)/boot/initrd.gz


-------- CUT --------

Thanks in advance!!

    Geoff


 

-----Original Message-----
From: Luca Berra
To: Weber, Geoffrey M.
Cc: 'linux-lvm@sistina.com'
Sent: 10/30/2003 7:49 AM
Subject: Re: [linux-lvm] Problems with initrd for LVM2 on 2.6.0-test8 and
-test9 kernels.. .

On Wed, Oct 29, 2003 at 09:26:14AM -0600, Weber, Geoffrey M. wrote:
>   library).    As   soon  as  I  try  to  use  LILO  or  GRUB  with
the
>   "root=/dev/vg00/root" or "root=3f00" (device major and minor
numbers),
>   my  machine  hangs  after  "Uncompressing  Linux...  Ok,  booting
the
>   kernel.".
could you give us some more details about your setup, including actual
lines from your configuration.

>   I  have  also tried (unsuccessfully) to use an initrd image I found
on
>   the 'net at [1]http://www.comedia.it/~bluca/cooker/lvm2/

There is no initrd image at that location.
What you find there is modified Mandrake rpm to support lvm2 in Mandrake
Linux 9.2/cooker, and has not been tested with anything different than
that.

>   to  see  what  I  could find out. When trying to use the Busybox
"ash"
>   command  inside  the  modified evms initrd image, however, the
machine
>   doesn't halt and give me a shell at all but keeps booting.
i saw this problem as well, i don't know if it is caused by some device
file missing in the initrd image or what.

L.

-- 
Luca Berra -- bluca@comedia.it
        Communication Media & Services S.r.l.
 /"\
 \ /     ASCII RIBBON CAMPAIGN
  X        AGAINST HTML MAIL
 / \



NOTICE: This electronic mail transmission may contain confidential
information and is intended only for the person(s) named.  Any use, copying
or disclosure by any other person is strictly prohibited. If you have
received this transmission in error, please notify the sender via e-mail.




[-- Attachment #2: Type: text/html, Size: 11980 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [linux-lvm] Problems with initrd for LVM2 on 2.6.0-test8 and -test9 kernels.. .
  2003-10-30 16:54 [linux-lvm] Problems with initrd for LVM2 on 2.6.0-test8 and -test9 kernels.. Weber, Geoffrey M.
@ 2003-10-31  2:17 ` 'Luca Berra '
  0 siblings, 0 replies; 4+ messages in thread
From: 'Luca Berra ' @ 2003-10-31  2:17 UTC (permalink / raw)
  To: Weber, Geoffrey M.; +Cc: linux-lvm

On Thu, Oct 30, 2003 at 09:46:52AM -0600, Weber, Geoffrey M. wrote:
>My apologies for not providing the information earlier... and for my mistake
>in supplying the link to my initrd image.  I have been bookmarking sites
>like mad and apparently chose the wrong one...
if you even quit posting in multipart/alternative i'll be an happy man
:))))

>Here is my linuxrc inside the initrd image (this is the one based off of the
>evms initrd I found on the web, since it seemed the most complete).
>
>Please note that I still can't get the "/bin/ash" command to work properly,
>though I'm working on it.  I did put in the /dev/tty* and /dev/pt* nodes
>into the initrd image, but still no luck.  

here's the initrd i produce (shell is modified mdk/redhat nash)
note that i mount manually the root fs then i pivot_root.

-------------------------------------------------
... load modules ...
echo Mounting /proc filesystem
mount -t proc /proc /proc
echo Creating device files
mkdevices /dev
echo Activating md devices
mknod /dev/md1 b 9 1
mdassemble
echo Scanning logical volumes
vgscan
echo Activating logical volumes
vgchange -ay
echo 0x0100 > /proc/sys/kernel/real-root-dev
echo Mounting root filesystem
mount -o defaults --ro -t ext3 /dev/vg00/lvol1 /sysroot
pivot_root /sysroot /sysroot/initrd
echo Remounting devfs at correct place if necessary
handledevfs
umount /initrd/proc
-------------------------------------------------
mkdevices: creates device files based on /proc/partitions (if not devfs)
mdassemble: diet-libc version of mdadm --assemble (cannot build full
mdadm with diet-libc)
handledevfs: is described in the comment above

>Here is my menu.lst from grub.  I've been testing with grub just so that I
>could enter changes at boot time instead of running "lilo" all over the
>place.
you can append options to lilo command lines (just type 'em)

>-------- CUT --------
>
>gweber@windforce:/tmp/test$ more menu.lst
>default=1
>root    (hd0,3)
>splashimage (hd0,0)/grub/images/debian_cooleye-dither.xpm.gz
>vga=791
>title   Linux (2.6.0-lvm)
>kernel  (hd0,0)/vmlinuz-2.6.0-test9-aa0.2 root=fe00 console=ttys0
>initrd  (hd0,0)/initrd-gw.gz
                                                     ^^^^^^^^^^^^^
ttys0 ???
i tought serial console was ttyS0,<speed>

L.

-- 
Luca Berra -- bluca@comedia.it
        Communication Media & Services S.r.l.
 /"\
 \ /     ASCII RIBBON CAMPAIGN
  X        AGAINST HTML MAIL
 / \

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2003-10-31  2:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-10-30 16:54 [linux-lvm] Problems with initrd for LVM2 on 2.6.0-test8 and -test9 kernels.. Weber, Geoffrey M.
2003-10-31  2:17 ` 'Luca Berra '
  -- strict thread matches above, loose matches on Subject: below --
2003-10-29 17:53 Weber, Geoffrey M.
2003-10-30  7:50 ` Luca Berra

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.