Fedora Linux Support Community & Resources Center
  #1  
Old 8th January 2017, 07:51 AM
allocated Offline
Registered User
 
Join Date: Jan 2017
Location: india
Posts: 7
linuxfedorachrome
Windows 10 is gone after installing Fedora workstation 25

Hello everyone! I installed Fedora workstation on my Laptop a couple of moths ago. OK first of all let me start by stating the fact that I am a complete linux noob. The DVD that i used to install it wouldn't show up on my boot device list so i did it in "Legacy Mode"

The installation was done and good. But after i did a restart, windows 10 wouldn't appear on grub.

I started googling about this problem and found lots and lots of similer posts like this however none of them seemed REALLY SOLVED! Except one which said "Reinstall using UEFI mode and it will get fixed".

I did that. But guess what? It wasn't fixed. I kept trying and trying using the internet. Now I will show what I have done so far in my attempt to fix this problem

1. I have tried to edit the /etc/grub.d/40_custom file and manually entered a windows 10 boot entry which chainloads the bootmgfwr.efi file. It didn't work then I found out that the bootmgfwr.efi file wassn't actually present in the /boot/efi/EFI/fedora directory so i copied it from /dev/sda5/Windows/Boot . But it doesn't work anyway.

2. Then I tried to reset and reinstall grub2 using

rm /etc/grub.d/*
rm /etc/sysconfig/grub

then
yum reinstall grub2-efi shim


but after that, when i'm running grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg

it gives me an error message

Generating grub configuration file ...
Script `/boot/grub2/grub.cfg.new' contains no commands and will do nothing
Syntax errors are detected in generated GRUB config file.
Ensure that there are no errors in /etc/default/grub
and /etc/grub.d/* files or please file a bug report with
/boot/grub2/grub.cfg.new file attached.

this is my parted -l


Model: ATA ST1000LM024 HN-M (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:

Number Start End Size File system Name Flags
1 1049kB 211MB 210MB fat16 EFI System Partition boot, esp
2 525MB 567MB 41.9MB fat32 Basic data partition hidden
3 567MB 701MB 134MB Microsoft reserved partition msftres
4 701MB 1488MB 786MB ntfs Basic data partition hidden, diag
5 1488MB 497GB 495GB ntfs Basic data partition msftdata
6 497GB 497GB 494MB ntfs hidden, diag
7 497GB 970GB 473GB ntfs Basic data partition msftdata
9 970GB 970GB 1049kB bios_grub
10 970GB 971GB 524MB ext4 msftdata
11 971GB 972GB 1074MB ext4
12 972GB 991GB 19.4GB lvm
8 991GB 1000GB 8837MB ntfs Microsoft recovery partition hidden, diag


This is my fdisk-l

Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 1BF27811-0A83-4083-9256-7054E88391B3

Device Start End Sectors Size Type
/dev/sda1 2048 411647 409600 200M EFI System
/dev/sda2 1026048 1107967 81920 40M unknown
/dev/sda3 1107968 1370111 262144 128M Microsoft reserved
/dev/sda4 1370112 2906111 1536000 750M Windows recovery environment
/dev/sda5 2906112 969771245 966865134 461G Microsoft basic data
/dev/sda6 969773056 970737663 964608 471M Windows recovery environment
/dev/sda7 970737664 1895307263 924569600 440.9G Microsoft basic data
/dev/sda8 1936263168 1953523119 17259952 8.2G Windows recovery environment
/dev/sda9 1895307264 1895309311 2048 1M BIOS boot
/dev/sda10 1895309312 1896333311 1024000 500M Microsoft basic data
/dev/sda11 1896333312 1898430463 2097152 1G Linux filesystem
/dev/sda12 1898430464 1936263167 37832704 18G Linux LVM

Partition table entries are not in disk order.




Disk /dev/mapper/fedora-root: 16.1 GiB, 17272143872 bytes, 33734656 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/mapper/fedora-swap: 2 GiB, 2097152000 bytes, 4096000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Please Please.... PLEASE someone help me! I need my windows back, I really do. If no solution is available. please atleast tell me how to get back into my old windows atleast. I'll bid good bye to fedora and be happy with it. But please... I need to log back in to windows.


P.S. whoever solves this gets a cookie!!!!
Reply With Quote
  #2  
Old 8th January 2017, 08:26 AM
topiwala Online
Registered User
 
Join Date: Aug 2011
Location: India
Age: 31
Posts: 323
linuxfedorafirefox
Re: Windows 10 is gone after installing Fedora workstation 25

Which brand laptop?

Are you able to boot into fedora in UEFI mode?
Reply With Quote
  #3  
Old 8th January 2017, 08:50 AM
allocated Offline
Registered User
 
Join Date: Jan 2017
Location: india
Posts: 7
linuxfedorachrome
Re: Windows 10 is gone after installing Fedora workstation 25

Hello topiwala! Thanks for your fast response

It is a Dell inspiron 3000 series. And yes I am able to boot into fedora currently in UEFI mode. However I can not boot into any windows CD/DVD/USB in UEFI mode.
Reply With Quote
  #4  
Old 8th January 2017, 09:01 AM
topiwala Online
Registered User
 
Join Date: Aug 2011
Location: India
Age: 31
Posts: 323
linuxfedorafirefox
Re: Windows 10 is gone after installing Fedora workstation 25

Ok do not panic

First boot into fedora and backup data into external drives and shutdown.

Power On and press your UEFI boot device selection key its F12 as far i know but every vendor has different key.

After UEFI boot device selector is opened guide it to Windows Boot UEFI file.

See if windows Boots and tell us the results.

---------- Post added at 02:31 PM ---------- Previous post was at 02:31 PM ----------

Ok do not panic

First boot into fedora and backup data into external drives and shutdown.

Power On and press your UEFI boot device selection key its F12 as far i know but every vendor has different key.

After UEFI boot device selector is opened guide it to Windows Boot UEFI file.

See if windows Boots and tell us the results.





EDIT: The file will be located on UEFI partition

Last edited by topiwala; 8th January 2017 at 09:03 AM. Reason: added info
Reply With Quote
  #5  
Old 8th January 2017, 09:37 AM
allocated Offline
Registered User
 
Join Date: Jan 2017
Location: india
Posts: 7
linuxfedorachrome
Re: Windows 10 is gone after installing Fedora workstation 25

I did what you told me and this is what happened------>

http://imgur.com/a/d1FAK
Reply With Quote
  #6  
Old 8th January 2017, 10:06 AM
topiwala Online
Registered User
 
Join Date: Aug 2011
Location: India
Age: 31
Posts: 323
linuxfedorafirefox
Re: Windows 10 is gone after installing Fedora workstation 25

OK. Few questions which file you selected what was its name try every single .efi file which is present on the efi partition other than the fedora folder ones. When i broke my installation doing dual boot one of the files worked rest didnt. Post results here.
Reply With Quote
  #7  
Old 8th January 2017, 03:46 PM
PabloTwo Offline
"Registered User" T-Shirt Winner
 
Join Date: Mar 2007
Location: Seville, FL
Posts: 7,476
linuxchrome
Re: Windows 10 is gone after installing Fedora workstation 25

Some pointers on your series of mistakes:
Quote:
The DVD that i used to install it wouldn't show up on my boot device list so i did it in "Legacy Mode"
Yes, you've already learned that installing Fedora in Legacy mode when Windows is installed in UEFI mode makes Windows unbootable until you switch the bios back to UEFI mode. Fedora, in Legacy mode, cannot see a UEFI install.
Quote:
1. I have tried to edit the /etc/grub.d/40_custom file and manually entered a windows 10 boot entry which chainloads the bootmgfwr.efi file. It didn't work then I found out that the bootmgfwr.efi file wassn't actually present in the /boot/efi/EFI/fedora directory so i copied it from /dev/sda5/Windows/Boot . But it doesn't work anyway.
The filename is bootmgfw.efi, not bootmgfwr.efi
The Windows boot files would not be in /boot/efi/EFI/fedora directory. They would be in their own directory... /boot/efi/EFI/Windows.....
Quote:
2. Then I tried to reset and reinstall grub2 using

rm /etc/grub.d/*
rm /etc/sysconfig/grub

then
yum reinstall grub2-efi shim
Reinstalling grub2-efi and shim packages did not reinstall anything you deleted. For that, you needed to reinstall the grub2-tools package.
Code:
$ rpm -qf /etc/grub.d /etc/sysconfig/grub
grub2-tools-2.02-0.38.fc25.x86_64
grub2-tools-2.02-0.38.fc25.x86_64
The /etc/grub.d/ directory holds all the grub2 scripts, including the os-prober script, which is responsible for finding other OS's on the system. Without it, there is no chance in ell Fedora could find Windows (or any other OS) when running grub2-mkconfig, which is what triggers all those scripts to run.

If you don't see /boot/efi/EFI/Windows (or maybe Dell), then you probably reformatted the /dev/sda1 EFI System Partition during the install of Fedora and your Windows 10 boot files were vaporized.
Reply With Quote
  #8  
Old 9th January 2017, 06:17 AM
allocated Offline
Registered User
 
Join Date: Jan 2017
Location: india
Posts: 7
linuxfedorachrome
Re: Windows 10 is gone after installing Fedora workstation 25

Originally (after the fedora 25 installation in UEFI, my /boot/efi/EFI/ contained 2 directories

BOOT and fedora and neither of them had a bootmgfw.efi(sorry for the typo in the previous post) on them. So i created a directory structure like this /boot/efi/EFI/Microsoft/Boot and copied the bootmgfw.efi on it as well. And i tried linking it in the 40_custom as well. But with no surprise that too didn't work.

Presently i don't even have a 40_custom file in my system. Because when i enter gedit /etc/grub.d/40_custom it gives a completely blank text file

Quote:
Originally Posted by PabloTwo View Post
If you don't see /boot/efi/EFI/Windows (or maybe Dell), then you probably reformatted the /dev/sda1 EFI System Partition during the install of Fedora and your Windows 10 boot files were vaporized.

yeah I think that's exactly what has happened to my system.

Grub2-tools are already installed in my system.

So, what do i do now then??? Is there any way out of this??? To be honest i am not even trying to fix this anymore, not that i don't welcome a fix; but even if that's not possible i'm okay with it. I just really want to get my windows stuff back

Can you help with that?
Reply With Quote
  #9  
Old 9th January 2017, 06:46 AM
topiwala Online
Registered User
 
Join Date: Aug 2011
Location: India
Age: 31
Posts: 323
linuxfedorafirefox
Smile Re: Windows 10 is gone after installing Fedora workstation 25

First of be clear about few things. Is secure boot enabled on your system?

Did you tried booting .efi files as i said from the UEFI selector(which as far i know for dell appears by pressing F12) and not using grub.

Second every vendor has different implementation of UEFI.

Third situation is recoverable IMO. You have to make a windows10 Live USB and boot in it in secure boot mode and repair the boot or the installation.

You will have to be patient and do not panic. What i was trying to do was to look that if windows can be booted from uefi boot selection which was the case with me. So one by one you will have to select every .efi file and try from UEFI selection list not from grub. If you did tried it and was not able to boot so as far as i understand you have to use windows10 ISO USB/DVD to repair the boot. The ISO is downloadable from windows website.

Reply With Quote
  #10  
Old 9th January 2017, 07:05 AM
allocated Offline
Registered User
 
Join Date: Jan 2017
Location: india
Posts: 7
linuxfedorachrome
Re: Windows 10 is gone after installing Fedora workstation 25

No topiwala, i tried every .efi file there were in my boot/efi but all of them prompts me to the usual grub menu with two fedora entries in them to pick from. And the windows one just gives me the screen i posted two posts earlier.

Let me explain how external drives are behaving in my system currently ----

1. Legacy

When i insert a CD/DVD or a bootable USB I can see it in my bootable device list on BIOS but when I try to boot from them, The screen goes complete black for 15 or some seconds then the OLD grub menu shows up, the one where I installed fedora in legacy mode but when I select one of them, the initial loading screen appears but the loading bar never finishes loading. I think it means that even though the OS has been replaced by a new installation of fedora (in UEFI mode), the legacy grub still exists but when i select an OS to boot into it can't find one.

2. UEFI

Now, in UEFI : Let's say I have a windows DVD and a windows USB and a Fedora DVD.

When i enter the fedora dvd then restart my machine, the CD/DVD shows up in my bootable device list and guess what? I CAN boot from it.

But when I do the same with my windows DVD , it doesn't even show up in the BIOS bootable device list
Reply With Quote
  #11  
Old 9th January 2017, 07:12 AM
topiwala Online
Registered User
 
Join Date: Aug 2011
Location: India
Age: 31
Posts: 323
linuxfedorafirefox
Smile Re: Windows 10 is gone after installing Fedora workstation 25

Quote:
Originally Posted by allocated View Post

But when I do the same with my windows DVD , it doesn't even show up in the BIOS bootable device list

So it can mean that your USB was not made properly and will not boot. Try testing it on another UEFI secure boot laptop. Post results here.

If it works on other laptop than try "Add boot option" if it is present in your bios setup on the UEFI page.
Reply With Quote
  #12  
Old 9th January 2017, 02:06 PM
PabloTwo Offline
"Registered User" T-Shirt Winner
 
Join Date: Mar 2007
Location: Seville, FL
Posts: 7,476
linuxchrome
Re: Windows 10 is gone after installing Fedora workstation 25

Quote:
Originally Posted by allocated
Presently i don't even have a 40_custom file in my system. Because when i enter gedit /etc/grub.d/40_custom it gives a completely blank text file
That's because you deleted all the files in /etc/grub2.d. Just deleting some files installed by a package does not uninstall the package.
Quote:
Originally Posted by allocated
Grub2-tools are already installed in my system.
You could delete every file installed by a package and the system would still think the package is installed. You need to tell dnf to "reinstall" the grub2-tools package to get the files in /etc/grub.d/ directory back.
Reply With Quote
  #13  
Old 9th January 2017, 04:39 PM
allocated Offline
Registered User
 
Join Date: Jan 2017
Location: india
Posts: 7
linuxfedorachrome
Re: Windows 10 is gone after installing Fedora workstation 25

Thanks again PabloTwo, I did that

After successfully reinstalling my grub2-tools I ran this command grub2-mkconfig -o /boot/grub2/grub.cfg

The output was this --->

Generating grub configuration file ...
Found linux image: /boot/vmlinuz-4.8.15-300.fc25.x86_64
Found initrd image: /boot/initramfs-4.8.15-300.fc25.x86_64.img
Found linux image: /boot/vmlinuz-4.8.6-300.fc25.x86_64
Found initrd image: /boot/initramfs-4.8.6-300.fc25.x86_64.img
Found linux image: /boot/vmlinuz-0-rescue-0c4fad282d7042ffaa5bd85d92dcfadd
Found initrd image: /boot/initramfs-0-rescue-0c4fad282d7042ffaa5bd85d92dcfadd.img
done


How do I make grub to detect the windows 10??
Reply With Quote
  #14  
Old 9th January 2017, 05:06 PM
PabloTwo Offline
"Registered User" T-Shirt Winner
 
Join Date: Mar 2007
Location: Seville, FL
Posts: 7,476
linuxchrome
Re: Windows 10 is gone after installing Fedora workstation 25

Quote:
Originally Posted by allocated
How do I make grub to detect the windows 10??
Since we already agreed that you probably reformatted the ESP partition (/dev/sda1), which would have totally destroyed your W10 boot information, the grub2 os-prober script cannot detect your Windows install on a UEFI system.

Your either have to find a way to reinstall W10 in UEFI mode or manually place all the necessary and critical Windows 10 boot files into the /dev/sda1 EFI/Windows[/BOOT] directories.

Your probably better off asking on a Windows forum for advice on how to reinstall Windows rather than here on this forum. In the "Guides" section of the forum is a thread called "EFI Cheet Sheet", which describes how to create a new Windows boot entry into the ESP, but you'll still need to manually install the necessary Windows *.efi files into the proper places in the ESP partition going that route.

If nothing else, you can just mount your existing W10 partition that holds your personal data files (your "stuff") and copy them to your Fedora install for safe keeping.
Reply With Quote
  #15  
Old 10th January 2017, 05:16 AM
topiwala Online
Registered User
 
Join Date: Aug 2011
Location: India
Age: 31
Posts: 323
linuxfedorafirefox
Re: Windows 10 is gone after installing Fedora workstation 25

If your windows cannot boot using EFI manager than it will not using Grub. I would advise you to make a windows 10 usb/dvd and repair installation.
Reply With Quote
Reply

Tags
fedora, grub 2, installing, windows, workstation

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
checksum Fedora-Workstation-netinst on Windows wolfv Installation, Upgrades and Live Media 8 2nd February 2016 05:55 PM
Installing Fedora 17 in VM Workstation kcwong13 Installation, Upgrades and Live Media 0 4th August 2012 02:31 PM
help - installing fedora 8 to VM ware workstation 6.01 in windows xp poor Installation, Upgrades and Live Media 3 16th March 2008 01:50 PM
Installing Fedora core 5 as guest in VMware workstation 5.5 running on windows XP pro holmen Installation, Upgrades and Live Media 5 30th September 2006 11:56 AM
Installing Fedora Core 4 (x86) on Vmware Workstation 5.0 on Windows XP fedoraamd64 Using Fedora 6 23rd June 2005 12:36 PM


Current GMT-time: 04:19 (Friday, 28-04-2017)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat