LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   mkrescue Fatal: device-mapper: only linear boot device supported (http://www.linuxquestions.org/questions/slackware-14/mkrescue-fatal-device-mapper-only-linear-boot-device-supported-694078/)

Molly 12-31-2008 12:08 PM

mkrescue Fatal: device-mapper: only linear boot device supported
 
i am trying to accomplish creation of a lilo boot cd or rescue disk prior to reinstalling my winxp partition for dual boot.

first some system info:
kernel 2.6.27.10
slackware 12.1
encrypted root filesystem using the luks method outlined here: http://slackware.osuosl.org/slackwar...ADME_CRYPT.TXT



Code:

[root@virek] ~)) cat /etc/fstab
/dev/mapper/cryptroot /                ext3        defaults        1  1
/dev/mapper/cryptswap  swap      swap          defaults  0  0
/dev/hda3        /boot            ext3        defaults        1  2
/dev/hda1    /win    ntfs-3g      users  1  1


Code:

[root@virek] ~)) df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/cryptroot  39G  15G  23G  40% /
/dev/hda3              99M  40M  54M  43% /boot
/dev/hda1            108G  21G  88G  19% /win
tmpfs                442M    0  442M  0% /dev/shm


Code:

[root@virek] ~)) cat /etc/crypttab
cryptroot  /dev/hda4
cryptswap  /dev/hda2  none  swap

[root@virek] ~)) ls /dev/mapper
control  cryptroot  cryptswap


here are the pertinent lines of /etc/lilo.conf
Code:

boot = /dev/hda

# Linux bootable partition config begins
image = /boot/vmlinuz
initrd = /boot/initrd.gz
root = /dev/mapper/cryptroot
label = virek
read-only
#old safe config
image = /boot/vmlinuz.good
initrd = /boot/initrd.good.gz
root = /dev/mapper/cryptroot
label = goodold
read-only
#new good testing
image = /boot/vmlinuz.new
initrd = /boot/initrd.new.gz
root = /dev/mapper/cryptroot
label = new
read-only

# Windows bootable partition config begins
other = /dev/hda1
label = expee
table = /dev/hda
# Windows bootable partition config ends


running lilo to install to mbr as usual goes through fine as you can see:

Code:

[root@virek] ~)) lilo
Warning: '/proc/partitions' does not match '/dev' directory structure.
    Name change: '/dev/dm-0' -> '/dev/mapper/cryptroot'
Warning: Name change: '/dev/dm-1' -> '/dev/mapper/cryptswap'
Added virek *
Added goodold
Added new
Added expee
2 warnings were issued.


so i now attempt to create bootable floppy which fails due to space restrictions.. obviously too large to fit on floppy!

Code:

[root@virek] ~)) mkrescue

Insert a blank floppy into /dev/fd0
All information on this floppy will be destroyed
Press [Enter] to proceed, ^C to abort

Formatting /dev/fd0 with ext2 filesystem...
1+0 records in
1+0 records out
512 bytes (512 B) copied, 1.27602 s, 0.4 kB/s
done.

Copying files...
`/boot/initrd.gz' -> `/tmp/mkrescue_2633/mkrescue-flp/initrd'
`/boot/vmlinuz' -> `/tmp/mkrescue_2633/mkrescue-flp/linux'
cp: writing `/tmp/mkrescue_2633/mkrescue-flp/linux': No space left on device
done.

Running /sbin/lilo ...
map_insert_data: map write: No space left on device
LILO version 22.8 failure.


now then i will try to create an iso for boot cd and here is what happens:

Code:

[root@virek] ~)) mkrescue --iso --size HD
16384+0 records in
16384+0 records out
16777216 bytes (17 MB) copied, 0.101502 s, 165 MB/s
Partitioning HD file  (this will take a minute)
bsize = 16352
Making filesystem
mke2fs 1.40.8 (13-Mar-2008)
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
32 inodes, 16352 blocks
817 blocks (5.00%) reserved for the super user
First data block=1
Maximum filesystem blocks=16777216
2 block groups
8192 blocks per group, 8192 fragments per group
16 inodes per group
Superblock backups stored on blocks:
        8193

Writing inode tables: done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 23 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.
Mounting filesystem
Copying files...
`/boot/initrd.gz' -> `/tmp/mkrescue_2719/mkrescue-flp/initrd'
`/boot/vmlinuz' -> `/tmp/mkrescue_2719/mkrescue-flp/linux'
done.

Running /sbin/lilo ...
Warning: Ignoring entry 'boot'
Added linux *
Fatal: device-mapper: only linear boot device supported
LILO version 22.8 failure.


Where do I go from here? :cry:
thanks for any help!

mostlyharmless 12-31-2008 03:05 PM

Looks like you almost did what they wrote about here:

http://www.linuxquestions.org/questi...oot-cd-186385/

but not quite...hope that helps

(hint -size HD is for floppies not CD, just use -iso)

Molly 12-31-2008 11:57 PM

I've also already tried that. The reason I added the --side HD option becomes apparent here:


Code:

[root@virek] ~)) mkrescue --iso
2880+0 records in
2880+0 records out
2949120 bytes (2.9 MB) copied, 0.017304 s, 170 MB/s
Making filesystem
mke2fs 1.40.8 (13-Mar-2008)
/tmp/mkrescue_4671/mkrescue-emu is not a block special device.
Proceed anyway? (y,n) Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
24 inodes, 2880 blocks
144 blocks (5.00%) reserved for the super user
First data block=1
Maximum filesystem blocks=3145728
1 block group
8192 blocks per group, 8192 fragments per group
24 inodes per group

Writing inode tables: done                           
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 31 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.
Mounting filesystem
Copying files...
`/boot/initrd.gz' -> `/tmp/mkrescue_4671/mkrescue-flp/initrd'
`/boot/vmlinuz' -> `/tmp/mkrescue_4671/mkrescue-flp/linux'
cp: writing `/tmp/mkrescue_4671/mkrescue-flp/linux': No space left on device
done.

Running /sbin/lilo ...
Warning: Ignoring entry 'boot'
map_insert_data: map write: No space left on device
LILO version 22.8 failure.


any other ideas ?

thanks

mostlyharmless 01-01-2009 04:03 PM

Quote:

cp: writing `/tmp/mkrescue_4671/mkrescue-flp/linux': No space left on device
done
Where's your /tmp directory? It's filling up or just not allowing writes (could be a permissions problem). I don't think it has anything to do with the CD or the iso size.

Molly 01-05-2009 12:24 AM

I'm sorry to say but you are misunderstanding the operation of mkrescue.. it is actually creating a filesystem that is only 2880 blocks (k) unless you use the --size HD option which designates this filesystem be 16384 blocks (k).... thus if you are trying to use modern kernel AND initrd the 2880k limitation is quickly surpassed. This sizing issue is not the problem I was facing here.. the problem seems to be how mkrescue scripting is interacting with the device mapper.

In any case .. I have given up on this and just went ahead and ripped/rebuilt/upgraded the system using with fresh slackware 12.2 install but thanks for trying to offer advice.

mostlyharmless 01-06-2009 05:35 PM

Quote:

I'm sorry to say but you are misunderstanding the operation of mkrescue..
You're right, my error; glad you got it fixed despite my efforts :)


All times are GMT -5. The time now is 08:15 PM.