Results 1 to 9 of 9

Thread: yet another grub 22 error thread

  1. #1
    Join Date
    Jul 2007
    Beans
    61

    yet another grub 22 error thread

    Ok here is the thing, In recently did a complete wipe of my HDD and installed ubuntu formatting the whole drive.

    However, when I reboot I get error 22. I had at one time Vista installed on this but I installed ubuntu over the whole drive, so it shouldn't even have installed grub.

    please help

    I have tried doing

    Code:
    sudo grub
    find /boot/grub/stage1
    But I get in return:

    Code:
    Error 15: File not found
    thanks

  2. #2
    Join Date
    Sep 2008
    Location
    127.0.0.1
    Beans
    225
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: yet another grub 22 error thread

    Check to see whats in your /boot/grub/ directory. I have a feeling its empty, if it can´t find stage1.

    If this is the case, let me know. You will have to mount the hard drive, change root, install grub, and update grub to get a menu.lst generated.

  3. #3
    Join Date
    Jul 2007
    Beans
    61

    Re: yet another grub 22 error thread

    Code:
    ubuntu@ubuntu:/boot$ cd grub
    bash: cd: grub: No such file or directory
    :/

    EDIT:

    I realize now that that is only the live CD install. In the HDD under places there is no folder "/boot/grub" either
    Last edited by jijin; October 8th, 2008 at 05:07 AM.

  4. #4
    Join Date
    Sep 2008
    Location
    127.0.0.1
    Beans
    225
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: yet another grub 22 error thread

    You are in the LiveCD file system not your installed ubuntu file system.

    Please provide output of

    Code:
    sudo fdisk -l
    for better help.

  5. #5
    Join Date
    Jul 2007
    Beans
    61

    Re: yet another grub 22 error thread

    Code:
    Disk /dev/sda: 80.0 GB, 80026361856 bytes
    255 heads, 63 sectors/track, 9729 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0x95744b99
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1               1        9327    74919096   83  Linux
    /dev/sda2            9328        9729     3229065    5  Extended
    /dev/sda5            9328        9729     3229033+  82  Linux swap / Solaris

  6. #6
    Join Date
    Sep 2008
    Location
    127.0.0.1
    Beans
    225
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: yet another grub 22 error thread

    From the LiveCD mount your hard drive and change root

    Code:
    sudo mkdir /mnt/root
    mount -t ext3 /dev/sda1 /mnt/root
    sudo mount -t proc none /mnt/root/proc
    sudo mount -o bind /dev /mnt/root/dev
    sudo chroot /mnt/root bin/bash
    The command prompt should now look like this

    root@ubuntu:/#

    Now reinstall and update grub (make sure you regenerate menu.lst)

    sudo grub-install /dev/sda1
    sudo update-grub
    ls /boot/grub

    This will provide you with a grub folder with all the required files including regenerating menu.lst file.

  7. #7
    Join Date
    Jul 2007
    Beans
    61

    Re: yet another grub 22 error thread

    Ok I'm not sure if the commands you give below "Now reinstall and update grub (make sure you regenerate menu.lst)" do that but not aptitude is no longer working either.

    Note: It might say unable to resolve ubuntu, but my internet is working. I am posting this from the live CD.

    Code:
    root@ubuntu:/# sudo grub-install /dev/sda1
    sudo: unable to resolve host ubuntu
    sudo: grub-install: command not found
    root@ubuntu:/# sudo apt-get remove grub
    sudo: unable to resolve host ubuntu
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    Package grub is not installed, so not removed
    0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
    I can and don't mind reinstalling from scratch, but I want to make sure I don't have the same issue all over again.

    EDIT: I'm going to reinstall it from scratch
    Last edited by jijin; October 8th, 2008 at 05:47 AM.

  8. #8
    Join Date
    Oct 2008
    Location
    Bay Area, California
    Beans
    33
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: yet another grub 22 error thread

    Pardon me if you already checked this, but I fixed a Grub error 22 by correcting my drive cabling. My Sata drive motherboard sockets were populated (clue was from from start up bios report):
    Sata1: empty
    Sata2: empty
    Sata3: master 1
    Sata4: master 2

    Grub was happy after this:
    Sata1: master 1
    Sata2: master 2
    Sata3: empty
    Sata4: empty

    When I first built the system I did not think it mattered to plug the cables in strict order (or my old eyes misread the small print). Apparently, the later versions of Ubuntu are picky at load about cabling. This can happen from plugging the IDE in reversed (drive header into motherboard socket) also. The install CDROM worked fine, as did XP, but not the Grub loader from the actual installation. Even with the first two Motherboard Sata sockets empty, the CDROM Kubuntu numbered them sda and sdb.

    Hope this helps, cheers

    "We sleep soundly in our beds because rough men stand ready in the night to visit violence on those who would do us harm." - Winston Churchill
    PhenomIIx3 720 GIGABYTE GA-MA785GM-US2H; wf:AMD 5050e GA-MA78GM-US2H ub10.04; Svr2:Athlon II X2 250 Regor 3.0GHz, GA-790XT-USB3, CORSAIR XMS3 2Gx2 DDR3, 1600, Ub10.04; Svr3:AMD 4850e, M3A78, 2Gx2 OCZ 1066, Ub10.04

  9. #9
    Join Date
    Sep 2008
    Location
    127.0.0.1
    Beans
    225
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: yet another grub 22 error thread

    This might be a problem with the CD you are using. Here is some general tips regarding the CD

    Download the standard Ubuntu 8.04.1 32 bits iso image, torrent is recommended
    http://releases.ubuntu.com/releases/...sktop-i386.iso
    http://releases.ubuntu.com/releases/...86.iso.torrent

    Check the md5sum of your downloaded Ubuntu .iso image file https://help.ubuntu.com/community/HowToMD5SUM
    and compare with http://releases.ubuntu.com/8.04.1/MD5SUMS

    Burn it on a CD rom with low speed 4X and then check the md5sum of the burnt CD

    Try to perform the "Memory test" and the "Check CD for defects" to be sure the CD is read without errors by the destination PC CD rom driver

    Then reinstall your Ubuntu

    Hope this helps

Bookmarks

Posting Permissions

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