Find the answer to your Linux question:
Results 1 to 10 of 10
It appears if I wipe out Linux, it takes the grub bootloader with it and I get that error 22 message. Is there a way I can prevent the grub ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jun 2009
    Posts
    9

    Installing grub on a boot partition


    It appears if I wipe out Linux, it takes the grub bootloader with it and I get that error 22 message. Is there a way I can prevent the grub bootloader from being wiped out whenever I format and remove a linux OS? I was thinking of having the grub bootloader on a tiny dedicated boot partition that holds all this boot information to all the wonderful Linux distros. Just not sure how to do it since I'm new to this.

  2. #2
    Linux Engineer b2bwild's Avatar
    Join Date
    Jul 2008
    Location
    Behind You!
    Posts
    1,108
    You can't use same /boot partition for multiple distros. X_X
    In most of the cases, if you try to force install on /boot partition without formatting.
    Important files will be overwritten.

    To avoid this, You can install the grub on the /boot or / partition itself, instead of MBR. and install the last distro having grub on MBR, which will keep all the entries for other installations.
    Never make any misteaks.

    Read my Blog at --> Penguin Inside Subscribe Feed

  3. #3
    Just Joined!
    Join Date
    Jun 2009
    Posts
    9
    and if this "last" distro (seeing how it now carries the latest MBR) was removed I would get an error 22 on startup? I'm trying to avoid that error 22 message.

  4. #4
    Linux Engineer b2bwild's Avatar
    Join Date
    Jul 2008
    Location
    Behind You!
    Posts
    1,108
    However you need a active and working MBR on a Disk.
    as the BIOS can't boot from specifc partition, but only from the MBR of disk.
    Never make any misteaks.

    Read my Blog at --> Penguin Inside Subscribe Feed

  5. #5
    Linux User
    Join Date
    Dec 2007
    Location
    Idaho USA
    Posts
    359

  6. #6
    Just Joined!
    Join Date
    Apr 2009
    Posts
    33
    Quote Originally Posted by Linux_user123 View Post
    It appears if I wipe out Linux, it takes the grub bootloader with it and I get that error 22 message. Is there a way I can prevent the grub bootloader from being wiped out whenever I format and remove a linux OS? I was thinking of having the grub bootloader on a tiny dedicated boot partition that holds all this boot information to all the wonderful Linux distros. Just not sure how to do it since I'm new to this.
    you could either
    1. have a stable linux partition where resides your grub files
    and then add other linux systems in the other available partitions
    in which case you should make sure that the new linux systems don't install
    a boot loader that wipes out the MBR
    otherwise you can restore it from a linux live system that provides grub
    (such as RIPlinux, grml)

    2. when the pcs had floppy drives, it was possible to install grub on a floppy
    and boot from it to boot on one the partitions in the hard drive
    (whenever a new linux system was added or removed
    in the hard drive, all you had to do is edit the grub file menu in the floppy)
    I suppose it's possible to do an equivalent thing on a usb stick

  7. #7
    Just Joined!
    Join Date
    Jun 2009
    Posts
    9
    Ok after reading through all these online guides I think I got it. Now I need a guide on menu.lst that explains clearly what each line does.

  8. #8
    Linux User
    Join Date
    May 2009
    Location
    Big River, Sask, Canada
    Posts
    342
    Registered Linux User #420832

  9. #9
    Just Joined!
    Join Date
    Jun 2009
    Posts
    9
    I have a question. If I installed the grub bootloader in Ubuntu's root directory (/dev/sda5) rather than hd0 (MBR), and installed grub in its own dedicated boot partition (/dev/sdb9) and setting it to hd0, will uninstalling Ubuntu do something to the MBR?

    Second question. Is it important as to where the boot partition is located on the disk? It's located nearly at the end of the disk. I have a modern 2007 laptop. I hope the limitation won't be an issue. edit: nope, doesn't look like it because I booted up just fine.

    Can someone recommend me an up-to-date gui grub editor?

  10. #10
    Linux User vickey_20's Avatar
    Join Date
    Mar 2009
    Location
    Mumbai, India
    Posts
    493
    Quote Originally Posted by Linux_user123 View Post
    It appears if I wipe out Linux, it takes the grub bootloader with it and I get that error 22 message.
    If you delete Linux completely then all partitions created are destroyed including the one holding the grub. So that's when you get the error 22
    Quote Originally Posted by Linux_user123 View Post
    Is there a way I can prevent the grub bootloader from being wiped out whenever I format and remove a linux OS?
    You will have to preserve the boot partition so that grub works fine
    Quote Originally Posted by Linux_user123 View Post
    I was thinking of having the grub bootloader on a tiny dedicated boot partition that holds all this boot information to all the wonderful Linux distros. Just not sure how to do it since I'm new to this
    The grub in case you keep the /boot partition alive will hold info of the OS that were installed when the Linux system was present on ur pc. If you want to have grub handle all ur OS every time you install a new one, you will have to manually edit the grub.conf file or menu.lst( which is a symblink to grub.conf)
    Only if I could understand the man pages
    Registered Linux user #492640
    OS: RHEL4,5 ,RH 9,Ubuntu

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •