Creare un floppy disk di boot

Da MEPIS Documentation Wiki.

Jump to: navigation, search
  • Procedimento

Inserire il floppy nell'unità (nei nostri esempi sarà /dev/fd0 ed il mount point /media/floppy). Formattare il floppy in ext o fat (usando ad esempio mkfs.ext2, mkfs.vfat, mke2fs o altro). Sono equivalenti. Va anche bene il floppy in FAT come viene preformattato.

  • Montare il floppy
mount /media/floppy
  • Commutare sull'utente root
 su 
  • Copiare per intero la directory /boot/grub all'interno del floppy
cp -R /boot/grub /media/floppy/grub
  • Smontare il floppy
umount /media/floppy
  • Avviare grub
  • Nel prompt di grub dare i comandi:
root (fd0)
setup (fd0)
quit
  • Il floppy di grub è pronto :-)

Questo floppy potrà essere usato anche come floppy di grub generico richiedendo, prima del boot, la console col tasto C oppure rimuovendo il file menu.lst dal floppy.


Create Boot Floppies (official how-to)


How to create a GRUB diskette:

  1. Type "kdesu kwrite" in "Run Command" and enter the root pasword.
  2. Copy the following code into kwrite windows:
#!/bin/sh 
# 
# This script formats the floppy and writes the current grub configuration to floppy. 
# A write-enabled floppy must be in the drive.  Its present contents will be lost.
# 
mkfs.ext3 /dev/fd0 
mount /dev/fd0 /mnt/floppy 
cd /mnt/floppy 
mkdir boot 
cd boot 
mkdir grub 
cd /boot/grub 
cp * /mnt/floppy/boot/grub
umount /dev/fd0 
grub --batch --device-map=/dev/null <<EOF 
device (fd0) /dev/fd0 
root (fd0) 
setup (fd0) 
quit 
<<EOF

Then: File -> Save as -> /sbin/makegrubfloppy

Next, make the file executable:

  1. Open konqueror as root (File Manager - Super User Mode)
  2. Right click on /sbin/makegrubfloppy file and select Properties
  3. Select the Permissions tab of the Properties dialog
  4. Click on the check box for Is executable
  5. Click OK
  6. Close File Manager (konqueror)

Alternatively, you can make it executable in konsole:

su (enter root password)
chmod +x /sbin/makegrubfloppy

You can now insert a floppy disk into the drive, open KMenu > System > Terminal - Super User Mode and execute the command makegrubfloppy to create a bootable floppy disk that will provide exactly the same boot menu you have when booting from your hard drive.

Personal tools