1

Long story short , i inserted a windows 10 bootable USB deleted all partitions previously were installed , did this in command prompt :

diskpart
select disk 0
clean

then installed a windows 10 on the machine .
after that made a new bootable USB with ubuntu 16.04 , after booting the USB , before installing i had a warning saying somthing like :

another operatin system (windows 10) is installed , using legacy BIOS and you are trying to install ubuntu through uefi , if you continue you might not be able to load the other operating system

i ignored it and went to install ubuntu, created a new partition alongside windows created a swap partition , and i the bootloader partition i think was the hard disk itself .
after finishing the installation i couldnt see windows entry in grub menu .
after searching i booted again into windows 10 usb and in command prompt i did :

bootsect /nt60 c: /mbr  

this command deleted ubuntu grub and now im only able to load into windows 10 .
how can set up grub with both ubuntu and windows 10 entries ?

2

what i did is , using Rufus for creating a windows 10 and ubuntu 16.04 bootable images ,
important : when creating the usb under partition scheme select only UEFI with GPT disk (for both ubuntu 16.04 and windows 10) .

Turn on PC and :

  • plug windows 10 usb into the machine
  • click Esc (or your setup key) then Enter setup menu
  • in BIOS settings disable secure boot (search for it under the tabs)
  • enable CSM feature (under boot tab) this will let you boot from USB
  • click f10 to exit and save changes .
  • click Esc (or your setup key) then you USB should appear here
  • click the usb and boot into windows 10 installation , on the screen install now click shift+alt+f10 this will open command prompt , do the following :

    diskpart select disk 0 - (in my case i wanted to install on disk 0) you can whatever you have clean - this will clean any disk type (MBR or GPT)

  • after you can partion and install windows 10 as you like .

  • after installing windows 10 , remove windows 10 usb and insert ubuntu (created as above ).

  • install ubuntu as you would do normally .

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.