LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   mkrescue gives error (bug?) (https://www.linuxquestions.org/questions/slackware-14/mkrescue-gives-error-bug-4175483628/)

GNU/Linux 11-06-2013 02:00 PM

mkrescue gives error (bug?)
 
Code:

root@darkstar# mkrescue --iso
mkdir: cannot create directory '/tmp/mkrescue.XXXX0tioxs': File exists
Could not create temporary directory.

Commenting out the following block (in /usr/sbin/mkrescue script) gets rid of the issue (and I get rescue.iso in pwd), as suggested in this Debian bug report
Code:

# mkdir $tmpbase || {
#    echo "Could not create temporary directory."
#    exit 1
# }

Is this solution ok?

Alien Bob 11-06-2013 03:10 PM

Something must be wrong on your computer with regard to creating temporary directories with mktemp. I ran "mkrescue --iso" multiple times. However, later on in the process, the ISO creation falls flat on its nose anyway:
Code:

mkrescue --iso
16384+0 records in
16384+0 records out
16777216 bytes (17 MB) copied, 0.0388587 s, 432 MB/s
Partitioning HD file  (this will take a minute)
bsize = 16352
Making filesystem
mke2fs 1.42.8 (20-Jun-2013)
Discarding device blocks: done
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
Stride=0 blocks, Stripe width=0 blocks
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

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

Mounting filesystem
Copying files...
‘/boot/initrd_3.10.17.gz’ -> ‘/tmp/mkrescue.XXXXwPKDta/mkrescue-flp/initrd’
‘/boot/vmlinuz-generic-3.10.17’ -> ‘/tmp/mkrescue.XXXXwPKDta/mkrescue-flp/linux’
done.

Running /sbin/lilo ...
Warning: Ignoring entry 'boot'
Added linux  +  *
Added hard_disk
One warning was suppressed.
done.

START MakeISOFS:

/usr/sbin/mkrescue: line 673: genisoimage: command not found

END MakeISOFS:  output is in  'rescue.iso'


The bootable CD can be burned with the 'cdrecord' or 'wodim' utility
using a command of the form:

        cdrecord [<options>] [dev=<device>] rescue.iso
        wodim [<options>] [dev=<device>] rescue.iso

All done.

I do not know if Slackware ever had a "genisoimage" program. It does not have one in 13.37 and newer releases.

Eric

GNU/Linux 11-07-2013 03:57 AM

Here's what I get:
Code:

root@darkstar# mkrescue --iso
16384+0 records in
16384+0 records out
16777216 bytes (17 MB) copied, 0.0638111 s, 263 MB/s
Partitioning HD file  (this will take a minute)
bsize = 16352
Making filesystem
mke2fs 1.42.6 (21-Sep-2012)
Discarding device blocks: done                           
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
Stride=0 blocks, Stripe width=0 blocks
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

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

Mounting filesystem
Copying files...
'/boot/initrd.gz' -> '/tmp/mkrescue.XXXXBKKMkf/mkrescue-flp/initrd'
'/boot/vmlinuz-generic-smp-3.2.45-smp' -> '/tmp/mkrescue.XXXXBKKMkf/mkrescue-flp/linux'
done.

Running /sbin/lilo ...
Warning: Ignoring entry 'boot'
Added linux  +  *
Added hard_disk
One warning was suppressed.
done.

MKISOFS
Setting input-charset to 'ISO-8859-1' from locale.
Size of boot image is 32768 sectors -> Emulating a hard disk
Warning: partition does not start at 0/1/1.
 59.80% done, estimate finish Thu Nov  7 14:50:04 2013
Total translation table size: 2488
Total rockridge attributes bytes: 450
Total directory bytes: 0
Path table size(bytes): 10
Max brk space used 21000
8376 extents written (16 MB)

END MKISOFS:  output is in  'rescue.iso'


The bootable CD can be burned with the 'cdrecord' utility
using a command of the form:

        cdrecord [<options>] [dev=<device>] rescue.iso

All done.

I'm running Slackware 14, with 3.2.45-smp. mkrescue version 3.2.

Quoting from Debian bug link:
Quote:

the earlier line
tmpbase="`mktemp -dt $(basename $0).XXXXXXXXXX`" || exit

would have already created the directory if there were no errors, correct?
So later in the script when it tries to create the same directory again, we get the error (post 1). Commenting this block would get rid of the error.

NeoMetal 11-07-2013 10:19 AM

Quote:

Originally Posted by Alien Bob (Post 5059609)
Something must be wrong on your computer with regard to creating temporary directories with mktemp. I ran "mkrescue --iso" multiple times. However, later on in the process, the ISO creation falls flat on its nose anyway:
Code:

mkrescue --iso
16384+0 records in
16384+0 records out
16777216 bytes (17 MB) copied, 0.0388587 s, 432 MB/s
Partitioning HD file  (this will take a minute)
bsize = 16352
Making filesystem
mke2fs 1.42.8 (20-Jun-2013)
Discarding device blocks: done
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
Stride=0 blocks, Stripe width=0 blocks
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

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

Mounting filesystem
Copying files...
‘/boot/initrd_3.10.17.gz’ -> ‘/tmp/mkrescue.XXXXwPKDta/mkrescue-flp/initrd’
‘/boot/vmlinuz-generic-3.10.17’ -> ‘/tmp/mkrescue.XXXXwPKDta/mkrescue-flp/linux’
done.

Running /sbin/lilo ...
Warning: Ignoring entry 'boot'
Added linux  +  *
Added hard_disk
One warning was suppressed.
done.

START MakeISOFS:

/usr/sbin/mkrescue: line 673: genisoimage: command not found

END MakeISOFS:  output is in  'rescue.iso'


The bootable CD can be burned with the 'cdrecord' or 'wodim' utility
using a command of the form:

        cdrecord [<options>] [dev=<device>] rescue.iso
        wodim [<options>] [dev=<device>] rescue.iso

All done.

I do not know if Slackware ever had a "genisoimage" program. It does not have one in 13.37 and newer releases.

Eric


Hmm, Looks like the use of genisoimage is new to the mkrescue/lilo version in current

mancha 11-07-2013 12:51 PM

GNU/Linux: You're absolutely right, you've found a bug in lilo as shipped in Slackware 14.0. Your change is OK but I've improved it a bit to make it more informative. The patch below fixes:

lilo-23.2-mkrescue-fix.diff

Also, in so doing, you've revealed an issue in Slackware-current's mkrescue. It now invokes genisoimage from cdrkit (a Debian fork of cdrtools) rather than mkisofs. The patch below makes it Slackware-compatible:

lilo-24.0-mkrescue-fix.diff

Thanks for this report; two birds with one stone.

--mancha

mancha 12-30-2013 03:01 PM

I never heard back from the OP on this and I've seen no bug-fix patches for lilo on 14.0 or 14.1 so it seems the thread didn't percolate up to Pat.

If "mkrescue" is relatively esoteric then it probably doesn't matter, otherwise someone might want to send smoke signals to the appropriate people.

--mancha


All times are GMT -5. The time now is 03:19 PM.