Announcement

Collapse
No announcement yet.

Windows 8 inaccessible after installing Kubuntu 12.10

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Frank616
    replied
    My thanks to both of you as well. I've learned a lot about dual booting on a Win8 machine. Not that I'll ever do it, of course. However, the efforts of both of you to follow this through gave me a lot of insight into UEFI.

    Longnosemonkey: If you have another machine, be sure to put Linux on that on the bare metal. It is always safer to learn on a non-production machine. I wish I could give you one of the three that I just retired at my place of work.

    Frank.

    Leave a comment:


  • Jonas
    replied
    Sorry that I don't have anything of value to add to this thread but I'd wish to say that this is an exciting thread!
    As others, I can't stop applaud Steve for the time invested and the experience showed. Also usually frustration with trouble tend to make the poster drop out and give in because of frustration - I doubt I'd have the patience that longnosemonkey have here. Real life work stuck it's real nose in and stopped further investigation(for now).

    All in all this is a valuable thread, though without the hardware at hand I can't figure out all the ins and outs going on. I would love a mock-up thread, if this isn't all covered in Steves excellent UEFI section(?).

    Booting and MBR/BIOS/UEFI will be important for me to know as I consider to make a 'gratis' evening course for newbie transition from windows to Free/Open Software. At the moment I have a draft what to include in the course and course folder (once I have it ready and translated I'll post it here).

    Either way this is definitely something that I will need to know how to solve for the participants. Thank you all and especially Steve for your effort!

    b.r

    Jonas

    Leave a comment:


  • longnosemonkey
    replied
    I used the factory reset option inside Windows and it scrubbed everything, but left the partitions intact. The Kubuntu partition is now empty and NTFS formatted. There is no Windows Boot Manager or GRUB or even the image from post 78 at boot, it just goes straight into Windows.

    I learnt a lot from all this, and I hope this thread will be instructive to others. I will come back to Linux land when a few of the latest problems have been ironed out. SteveRiley and all others who helped me - thank you. You've helped during the holiday season and I won't forget it. I'll pass it on.

    Leave a comment:


  • longnosemonkey
    replied
    SteveRiley, I have important events at work this week so I've made a decision. I've spent two weeks trying to troubleshoot this laptop but I need a functional laptop now. I can't spend any more time on workarounds.

    I plan to reset the laptop to factory settings and using GParted from the Ubuntu LiveCD, partition the drive to prepare the partitions I mentioned before. I'll leave the Linux partition empty for now, and wait until there official support for SecureBoot. I think Kubuntu 13.04 or 13.10 will do it.

    But I will be back. I'm excited for the future of Linux. It really has a chance of sprouting this year. Valve again confirmed that Linux-based Steam boxes will be out this year.

    SteveRiley, if you'll bear with me, can you explain how I could create the partitions in the most safest possible way. I want to use GParted on Ubuntu LiveCD. But if you have better tools, we'll use that.

    Leave a comment:


  • SteveRiley
    replied
    1. Boot your computer with the Kubuntu Live USB. You will need to be connected to wired Ethernet during this procedure.

    2. When you see the Welcome screen, where you can choose either "Try Kubuntu" or "Install Kubuntu," don't do either. Instead, press Ctrl+Alt+F2.

    3. At the kubuntu@kubuntu:~$ prompt, enter
    Code:
    sudo -i
    You are now running as root, and the prompt will change to root@kubuntu:~#

    4. Enter each of the following. From post #70, /dev/sda7 is your root partition, correct? I made an edit to that post based on info from earlier posts. If my edit is wrong, then substitute the correct one in the first item below. You don't need to type the bits after the # marks.
    Code:
    mount /dev/sda7 /mnt  # change /dev/sda7 if necessary
    
    mount /dev/sda2 /mnt/boot/efi
    
    for i in /dev /dev/pts /proc /sys; do mount -B $i /mnt$i; done
    
    cp /etc/resolv.conf /mnt/etc/
    
    modprobe efivars  # stop if this fails and let me know
    
    chroot /mnt
    You are now running in what's called a "chrooted" environment. Essentially, you've mounted the Kubuntu on your hard drive and transferred into it. It's a very neat concept that has no parallel in the Windows world.

    5. Now reinstall and update GRUB:
    Code:
    apt-get install --reinstall grub-efi-amd64
    APT will download a fresh copy of GRUB and run the post installation script. This includes writing an updated /boot/grub/grub.cfg and -- crucially -- correctly setting and ordering the UEFI NVRAM boot variables. You will see two outputs that look a lot like the results of running the efibootmgr command. The second one should contain a BootNNNN* ubuntu entry, and that NNNN number should be the first item in the BootOrder list.

    6. Now get out of the chroot and umount everything. Enter each of the following:
    Code:
    exit
    
    for i in /sys /proc /dev/pts /dev; do umount /mnt$i; done
    
    umount /mnt/boot/efi
    
    umount /mnt
    7. Finally, restart your computer:
    Code:
    reboot
    Does GRUB appear upon boot?

    Leave a comment:


  • SteveRiley
    replied
    Oh, OK.

    Stick around for a moment, I will post step-by-step instructions for recovering GRUB.

    Leave a comment:


  • longnosemonkey
    replied
    I can press F12 to boot into InsydeH20. I don't know of any other relevant prompts I can get into. The UEFI/BIOS prompt that I talked about was probably the black DOS-like screen of Windows Boot Manager. I think that's what I was talking about. It popped up like GRUB at boot. I had no control of it.

    Leave a comment:


  • SteveRiley
    replied
    Way back in post #4, you mentioned knowledge of a "BIOS/UEFI prompt." Did you have to press a key during boot to make that appear? That's what I was referring to when I wrote
    However, during reboot, I can press F12 to bring up the UEFI boot manager. This is for ThinkPads; I have no idea what the key would be for your computer.

    Leave a comment:


  • longnosemonkey
    replied
    That doesn't work for me because, if I choose ubuntu from the Windows blue boot screen (from post#78), the black DOS screen of Windows Boot Manager tells me that Windows failed to start. I don't know why it says Windows failed to start when I chose ubuntu, but that's what it says. (as explained in Post #96)

    I can choose Windows in the first blue screen, and that boots up Windows 8. Would I be able to change the boot order with EasyBCD or a similar utility?

    Leave a comment:


  • SteveRiley
    replied
    OK. After I ran through the refresh, my GRUB also disappeared. I never saw the kind of menu that I showed in post #78, however. When I chose refresh, the following happened:

    * I was prompted to insert installation media (in my case, a bootable USB with Windows 8)
    * After I did that, a "Refresh" button appeared, which I clicked
    * The PC rebooted, and the GRUB menu appeared
    * I choose "Windows 8," and the refresh process started

    The refresh process has just finished. Indeed, GRUB appears to be missing: the computer boots directly to Windows 8.

    However, during reboot, I can press F12 to bring up the UEFI boot manager. This is for ThinkPads; I have no idea what the key would be for your computer. The list shows both Windows Boot Manager and ubuntu, which means the UEFI NVRAM variable for Kubuntu is still intact.

    When I choose that, voila! GRUB appears, and looks like it did before: It contains Ubuntu and Windows 8 entries. Selecting Ubuntu brings me to the Kubuntu desktop.

    Consulting the output of sudo efibootmgr -v, I can see what's changed: the ubuntu and Windows Boot Manager entries have swapped location, and the line that begins with BootOrder indicates that the Windows NVRAM boot variable is first. If we change the value of BootOrder, we should be able to restore previous behavior.

    The following is a generic example for how to do this. Assume the output of sudo efibootmgr is:
    Code:
    BootCurrent: 00
    Timeout: 0 seconds
    BootOrder: 0006,0005,0002,0003,0004
    Boot0000  Setup
    Boot0001  Boot Menu
    Boot0002* Network
    Boot0003* CD-ROM
    Boot0004* USB
    Boot0005* ubuntu
    Boot0006* Windows Boot Manager
    I want to flip the boot order of 0006 and 0005, while preserving the others. The command for that is
    Code:
    sudo efibootmgr -o 5,6,2,3,4
    (Yes, you can omit leading zeros.)

    Note the asterisks in the list: these indicate bootable items. We don't want to disable any current bootableness, we simply want to swap the items in the first and second positions in the BootOrder entry. However, there's no command to do just that; we have to completely specify the full boot order. Hence, my example command will do exactly that. When you press Enter, the full list of variables will be displayed again, and you can verify that the first and second items in the BootOrder line have changed places, while the others remained where they were. Note that the ordering of the individual BootNNNN lines does not change.

    When you do this on your own computer, please make sure you substitute appropriately, but follow the basic guidelines in my example above. I don't want to guess that what you listed in post #83 is still correct. You may or may not have different BootNNNN variables for ubuntu and Windows Boot Manager. The others -- 2003, 2001, 2002 -- shouldn't have changed. Therefore, your command is most likely going to take the form
    Code:
    sudo efibootmgr -o [I]A[/I],[I]B[/I],2003,2001,2002
    Where A is the NVRAM boot number for ubuntu and B is the NVRAM boot number for Windows Boot Manager.

    Finally, reboot your computer. GRUB should load, and everything should behave as before.

    Let me know whether this works for you. If so, then we can finally fix the glitchy Windows Boot Manager itself.
    Last edited by SteveRiley; Dec 30, 2012, 10:29 PM.

    Leave a comment:


  • SteveRiley
    replied
    Originally posted by longnosemonkey View Post
    I refreshed Windows 8 (instead of restoring to factory defaults) to get rid of all the crap I installed to diagnose problems. But apparently it did something to the boot record.
    Damn Windows and its assumption that there is no rest-of-world >

    Let me try this refresh thing to see what kind of damage it does. BRB.

    Leave a comment:


  • longnosemonkey
    replied
    I ran bcdedit after the refresh.

    There was a Windows Boot Manager and Windows Boot Loader section. There are also 4 Firmware Application sections: ubuntu, EFI USB, DVD/CD and Network entries.

    Very similar to the entries I'm offered now on boot (picture in #78.)

    Leave a comment:


  • longnosemonkey
    replied
    At this point, the NVRAM variables contain exactly what they should, and nothing more. Longnosemonkey's variable structure matches the from-scratch dual-boot build I was experimenting with last night. I wouldn't recommend to reinstall now, unless Longnosemonkey wants more hands-on experience.
    *groan*
    I think I'm about to get some hands-on experience.

    I refreshed Windows 8 (instead of restoring to factory defaults) to get rid of all the crap I installed to diagnose problems. But apparently it did something to the boot record.

    I'm getting a screen similar to the one you posted in post #78. I have the option of booting Windows 8 or Ubuntu. Choosing Ubuntu fails and takes me to the Windows Boot Manager page where I got errors. I've explained it above. But choosing Windows 8 works.

    However, GRUB never pops up and the Ubuntu partition no longer shows within Windows. So my Kubuntu partition is now inaccessible.

    SteveRiley... help please?

    Leave a comment:


  • SteveRiley
    replied
    Longnosemonkey: let's get your Windows Boot Manager fixed up. I have a couple ideas. I think it's an artifact from your attempt at using Wubi.

    Please boot into Windows. Start an elevated command prompt (that is, run as administrator). Enter bcdedit. Reply here with the output of that command. I suspect you'll have only two sections: "Windows Boot Manager" and a single "Windows Boot Loader," but I want to be sure first.
    Last edited by SteveRiley; Dec 30, 2012, 06:52 PM.

    Leave a comment:


  • sealbhach
    replied
    Great work there Steve. I think we're going to be seeing a lot of these type of threads in the future so it's all valuable information for people coming along later.

    .

    Leave a comment:

Users Viewing This Topic

Collapse

There are 0 users viewing this topic.

Working...
X