1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Unable to boot into Ubuntu

Discussion in 'Linux and Unix' started by g.ramesh, Jun 8, 2010.

Thread Status:
Not open for further replies.
Advertisement
  1. g.ramesh

    g.ramesh Thread Starter

    Joined:
    May 8, 2003
    Messages:
    222
    Hi

    Sometime back I installed Ubuntu 10.04 thru WUBI on to one of the partitions of my HD (which is already installed with Win xp sp3).

    Y'day when I tried to boot into Ubuntu the following message is displayed:

    "
    Windows could not start because the following file is missing or corrupt:
    <Windows root>\system32\hal.dll

    Please re-install a copy of the above file.
    "

    1. I checked up under " C:\WINDOWS\system32 " the file with the name HAL.DLL is present.

    2. My boot.ini file is as follws"

    [boot loader]
    timeout=30
    default=multi(0)disk(0)rdisk(0)partition(1)\WINDOW S
    [operating systems]
    multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Micro soft Windows XP Professional" /noexecute=optin /fastdetect
    C:\wubildr.mbr = "Ubuntu"

    what could be the reason for non starting of Ubuntu?
     
  2. Elvandil

    Elvandil

    Joined:
    Aug 1, 2003
    Messages:
    51,988
    Can you still boot to Windows?

    Do you see a copy of wubildr.mbr in your root directory? Has anything on the drive been moved or changed? Have you run any commands on the drive or changed partitions in any way?
     
  3. saikee

    saikee

    Joined:
    Jun 11, 2004
    Messages:
    3,768
    I did a search and this is the word from the horse's mouth.
     
  4. g.ramesh

    g.ramesh Thread Starter

    Joined:
    May 8, 2003
    Messages:
    222
    Yes I am able to boot into win xp now also.

    root directory means system32 directory ? I checked there I could not find any such file there. No nothing has been moved or changed and not run any commands to change partition.
     
  5. TerryNet

    TerryNet Terry Moderator

    Joined:
    Mar 23, 2005
    Messages:
    69,519
    In Windows "root directory" means directly on the C: drive (except in those rare cases where the system drive is something else).
     
  6. g.ramesh

    g.ramesh Thread Starter

    Joined:
    May 8, 2003
    Messages:
    222
    In that case, I did not see any wubildr.mbr in root directory.

    I just want to want to know that is it ok to have " noexecute=optin /fastdetect " wording in my boot.ini which I shown above ?
     
  7. flan_suse

    flan_suse

    Joined:
    Apr 25, 2010
    Messages:
    74
    Is that a typo above? I see WINDOW S instead of WINDOWS.
     
  8. TerryNet

    TerryNet Terry Moderator

    Joined:
    Mar 23, 2005
    Messages:
    69,519
    Yes, that in my boot.ini for Windows XP Pro.

    Note the last line in yours. That, I assume, is why Elvandil asked about the wubildr.mbr file. If it's not there Ubuntu is not going to boot.
     
  9. g.ramesh

    g.ramesh Thread Starter

    Joined:
    May 8, 2003
    Messages:
    222
    Hi Terrynet

    is the wording noexecute ok in boot.ini file?

    If wubildr.mbr is not present in root directory what is the solution?
     
  10. saikee

    saikee

    Joined:
    Jun 11, 2004
    Messages:
    3,768
    I hate distro trying to help by distorting a standard installation thus a user ending up knowing neither the standard method and the special method to rescure a Linux should anything help to it.

    Don't use Wubi myself but the layout suggests the file "wubildr.mbr" is the first 512 bytes of the Ubuntu partition. See Task E4 of Just booting tips for the standard way making a NT version of Windows to boot a Linux. Vista and Win7 are no different in requiring the same thing but their boot loader is "bootmgr".

    I suspect the Ubuntu CD may have a utility to copy the Ubuntu's MBR but the following is the what I regard as the "standard" method that works in every version of NT version of the MS Windows of Win2k and Xp that use NTLDR as the boot loader.

    Officially MS Windows has never been engineered to read a Linux partition so in order to boot it the first 512 bytes (equivalent to the MBR) of the Linux partition is placed in the "C" drive so that its boot loader can fire it up. It is the MBR inside the "C" drive that actually boots the Ubuntu Linux. Therefore to get it follow the following steps:

    (1) Boot up Ubuntu CD and use it as a Live CD. In fact any Linux Live CD will do but the commands here are wriiten for Ubuntu family distros.

    (2) Check which partition has Windows and which one has Linux by command
    Code:
    sudo su
    fdisk -l
    The Windows partition must be bootable so it will be marked witha "*". A ntfs partition is Type 7 so these two together mean a bootable Windows system inside. It should be among the first one or two. Let' say it is device /dev/sda1. The first Linux partition should be Ubuntu. All Linux partitions must be type 83. If Ubuntu has been installed with several partition the bootable one /boot should always be in the first one. Lest say it is /dev/sda3.

    (3) Make two mounting points in /mnt (of the boot up Live CD) to mount WIndows and Linux partitions and then mount them
    Code:
    mkdir /mnt/sda1
    mkdir /mnt/sda3
    mount /dev/sda1 /mnt/sda1
    mount /dev/sda3 /mnt/sda3
    (4) I have omitted preceeding the commands with "sudo" because in the first line "sudo su" I have already claimed the Super user position. Now verify the contents of the two partitions by
    Code:
    ls /mnt/sda1
    ls /mnt/sda3
    Linux see all hidden files inside a WIndows partition so Wubidr.mbr could still be there with the usual hidden files like boot.ini and NTLDR etc. Wubidr.mbr could be corrupted so it pays to redo it again.

    The Ubuntu partition will have /boot, /home, /dev etc. The bootable one must have /boot.

    (5) To copy the first 512 bytes of Ubuntu partition into Windows partition. This must be done by a sector to sector copying command dd available only in Linux or Unix.
    Code:
    dd if=/dev/sda3 of=/mnt/sda1/wubidr.mbr bs=512 count=1
    The above copy "1" record of size specified by "bs" from an input file sda3, which is a device directly, to an output file /mnt/sda1/wubidr.mbr. Make ajustment if your Windows and Ubuntu are in different partitions. Steps (4) is only for verification and can be omitted if you know where are your WIndows and Ubuntu. Basically you only need to mount the WIndows partition to deliver wubidr.mbr there.

    It pays to understand the concept which is the same for all MS Windows booting a Linux. Thus if you install several Linux you simply repeat the steps and set your own filenames like Linux1.mbr, Linux2.mbr etc and amend boot.ini accordingly.

    In general no need to touch the boot.ini or anything in Windows once the set up has been done. All NTLDR needs is the file "wubidr.mbr" available inside the partition that holds boot.ini
     
  11. TerryNet

    TerryNet Terry Moderator

    Joined:
    Mar 23, 2005
    Messages:
    69,519
    Yes. The boot.ini I checked is just like yours, except I don't have Wubi installed so don't have the last line of yours.

    With Ubuntu installed using Wubi there is no separate partition for Linux. Looking from the "outside" all you see is a large file in the Windows partition; when you boot to Ubuntu this large file becomes the Linux partition and from within the booted Ubuntu it looks like a separate partition.

    For this reason I don't have my usual extreme confidence that saikee's procedure will work. But it's certainly worth a try. If it doesn't work report back details of what happened and he may be able to amend the instructions.
     
  12. saikee

    saikee

    Joined:
    Jun 11, 2004
    Messages:
    3,768
    I don't use Wubi. If what you said the Ubuntu is just a guest system inside Windows in which case there should be no necessity to boot a guest system which must operate wholly inside a host system, as a virtual machines does.

    I run a portable Ubuntu that is fired up inside a MS Windows.

    The Step (2) I put in is to check if such a system exists. In which case there should be no partition type 83 visible and so it would be impossible to proceed to Step (3) if Ubuntu is just a file inside the MS Windows. I act on the entry on boot.ini as that is the normal way to get NTLDR to boot a Linux, by having its mbr inside the "C" drive.
     
  13. TerryNet

    TerryNet Terry Moderator

    Joined:
    Mar 23, 2005
    Messages:
    69,519
    Wubi does not make Ubuntu a guest system like when using VirtualBox or VMware or other virtual machines. Wubi installs as a Windows application, un-installs with Add/Remove programs, but you actually get a dual boot. So, we'll just have to see how well your procedure works with this special case.
     
  14. Lezley

    Lezley

    Joined:
    Jun 8, 2010
    Messages:
    37
    I'd totally re-partition and install Ubuntu all over again =P
     
  15. g.ramesh

    g.ramesh Thread Starter

    Joined:
    May 8, 2003
    Messages:
    222
    Hi thanks to all of you for your replies.

    Now problem seems to be increased as I am not able to boot into win xp either. It is showing hal.dll is missing.

    Then I tried the following.

    1) when tried to use recovery console , it is showing C:\> after some time.
    Then I issued the command expand h:\i386\hal.dl_ c:\windows\system32\hal.dll.

    2)Then it displayed " Access is denied ".


    Then I tried to run chkdsk with /r option after 50% completion is showed "the system has unrecoverable errors"

    At last I booted thru a live CD of Ubuntu 10.04 and checked for computer. It is displaying the three of my original partitions of my HD but none of them are being mounted and are showing the following message:

    Error mounting: mount exited with exit code 13: ntfs_attr_pread_i: ntfs_pread failed: Input/output error
    Failed to read NTFS $Bitmap: Input/output error
    NTFS is either inconsistent, or there is a hardware fault, or it's a
    SoftRAID/FakeRAID hardware. In the first case run chkdsk /f on Windows
    then reboot into Windows twice. The usage of the /f parameter is very
    important! If the device is a SoftRAID/FakeRAID then first activate
    it and mount a different device under the /dev/mapper/ directory, (e.g.
    /dev/mapper/nvidia_eahaabcc1). Please see the 'dmraid' documentation
    for more details.

    Please tell me whether my win xp has gone bust?
     
  16. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/927875