LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 02-20-2023, 11:30 AM   #1
Pen guin
Member
 
Registered: Oct 2019
Posts: 178

Rep: Reputation: Disabled
Dual booter erased c: drive by mistake...now what?


Fortunately, I insisted on a non OEM Windows 10 CD as part of the sale of the computer from the Co. I bought it from, so I have that albeit from 2017.

On the NVMe (1TB) I have my Debian Bullseye installation.



The thing is, if I understand it correctly, if I install Windows now, with a Linux OS pre-existing, as it was explained to me, Windows will want to "take control of everything," and it would require a massive amount of time to work with GRUB boot loader, which for me is a pretty tall order at this point.



However, my saving grace may be that I have a 6 year old SSD 1 TB drive with Windows 10 on it as of Dec. 22. Perhaps I could reinstall that drive, would that make things easier?
Thanks in advance,



Pen guin
 
Old 02-20-2023, 11:55 AM   #2
fatmac
LQ Guru
 
Registered: Sep 2011
Location: Upper Hale, Surrey/Hants Border, UK
Distribution: One main distro, & some smaller ones casually.
Posts: 5,872

Rep: Reputation: Disabled
Yes, if you put the old SSD in as first disk, Windows will work, then you can add your nvme drive also, but you will need to use your computers boot menu to choose between the two.

(I'm not sure how Windows treats other OS these days, but it always tries to format any disk that isn't its own!)
 
Old 02-20-2023, 01:20 PM   #3
Pen guin
Member
 
Registered: Oct 2019
Posts: 178

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by fatmac View Post
Yes, if you put the old SSD in as first disk, Windows will work, then you can add your nvme drive also, but you will need to use your computers boot menu to choose between the two.

(I'm not sure how Windows treats other OS these days, but it always tries to format any disk that isn't its own!)


I can confirm that's still the case in 2023, as it was explained to me earlier today.

The only reason I have a Windows installation, at all is for my use of flight simulation software, which requires to be natively installed on a Windows OS, for best performance. If it wasn't for my interest in aviation, and flying, I too would be Windowless. Grrrr!

Last edited by Pen guin; 02-20-2023 at 01:22 PM.
 
Old 02-20-2023, 05:03 PM   #4
Brains
Senior Member
 
Registered: Apr 2009
Distribution: All OS except Apple
Posts: 1,591

Rep: Reputation: 389Reputation: 389Reputation: 389Reputation: 389
My older laptop has Windows 10, Linux Debian, Linux Fedora and FreeBSD on a 250 GB NVME. Quad boot.

Windows 10 puts out a new release twice a year via Windows update. For me, upgrading this way always puts on a few extra pounds to Windows so I just reinstall from the latest Windows 10 CD image to get the latest version of Windows 10 without any crud from previous version(s) and no need to apply updates as would be the case using a 6 year old Windows CD.
My data is on a separate drive.

I use DISM command in the old Windows installation before installing the new to retrieve a copy of all OEM drivers. Burn the new Windows 10 ISO file to USB stick with Rufus, then boot it up, select install, select/highlight the original C drive, format it and click install while it's highlighted, reboot, go to Device Manager and install any missing drivers from the Drivers I extracted from the previous installation.

It don't affect any other OS on the drive in my UEFI system.

I typically leave Windows as the default OS to boot, but I'm guessing if you had a different OS set as default in firmware settings it would leave that as is, a OEM restore would likely change it back to Windows as default boot item.
 
Old 02-21-2023, 01:49 AM   #5
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,394

Rep: Reputation: 2712Reputation: 2712Reputation: 2712Reputation: 2712Reputation: 2712Reputation: 2712Reputation: 2712Reputation: 2712Reputation: 2712Reputation: 2712Reputation: 2712
Quote:
The thing is, if I understand it correctly, if I install Windows now, with a Linux OS pre-existing, as it was explained to me, Windows will want to "take control of everything,"
If this is an EFI install, windows will create a Microsoft directory on the EFI partition with its boot files and will not damage the EFI files of your Debian install. When installing windows, it will likely put itself as first in boot order in the BIOS firmware so you would need to set the boot priority there to Debian and run grub-mkconfig from Debian to include the windows entry to boot both systems from Grub.
 
1 members found this post helpful.
Old 02-21-2023, 10:54 AM   #6
Pen guin
Member
 
Registered: Oct 2019
Posts: 178

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by yancek View Post
If this is an EFI install, windows will create a Microsoft directory on the EFI partition with its boot files and will not damage the EFI files of your Debian install. When installing windows, it will likely put itself as first in boot order in the BIOS firmware so you would need to set the boot priority there to Debian and run grub-mkconfig from Debian to include the windows entry to boot both systems from Grub.
I was under the impression, that if a secondary OS was on the system, in my case Debian Bullseye 11.60, *and then* you installed Windows, Windows would commandeer the entire system, i.e. take control of, and make it very difficult to install another operating system. As it was explained to me yesterday, under these circumstances, I'd have to modify the GRUB boot loader somehow via the command line.

Or am I misunderstanding something?
 
Old 02-21-2023, 04:09 PM   #7
mrmazda
LQ Guru
 
Registered: Aug 2016
Location: SE USA
Distribution: openSUSE 24/7; Debian, Knoppix, Mageia, Fedora, OS/2, others
Posts: 6,502
Blog Entries: 1

Rep: Reputation: 2232Reputation: 2232Reputation: 2232Reputation: 2232Reputation: 2232Reputation: 2232Reputation: 2232Reputation: 2232Reputation: 2232Reputation: 2232Reputation: 2232
Quote:
Originally Posted by Pen guin View Post
Or am I misunderstanding something?
UEFI changed Windows' behavior. The UEFI BIOS is much smarter. Instead of loading a boot sector to get the ball rolling, its job is to load a file from a special VFAT filesystem called the ESP. When GPT partitioning and EFI booting are used, it's only after the specified file loads that any OS's bootloader gets control. When Windows' installer changes the RAM selection order, you change it back the way you want it via a quick visit to BIOS setup, or use your BBS hotkey to make a non-default selection, and instruct your Linux OS's efibootmgr to change the order to your liking. Windows won't disturb any content on the ESP that isn't in a directory whose name it owns. All the standard FOSS boot files placed there by debian, mint, ubuntu, opensuse, fedora, manjaro, slackware and the rest, except one placed there for fallback purposes, are safe against replacement, corruption and removal by Windows.
 
Old 02-21-2023, 05:37 PM   #8
Arnulf
Member
 
Registered: Jan 2022
Location: Hanover, Germany
Distribution: Slackware
Posts: 312

Rep: Reputation: 112Reputation: 112
Quote:
Originally Posted by Pen guin View Post
if a secondary OS was on the system, […] *and then* you installed Windows, Windows would commandeer the entire system
To avoid this, it is required to disable "secure boot" in UEFI *before* installing Windows. Depending on your UEFI, "secure boot" settings may be a little bit hidden. Disabling "secure boot" works for Windows 11 too. Windows 11 requires an UEFI that *supports* "secure boot" but it can be installed and it works with "secure boot = disabled".
TPM can be left enabled in UEFI. It isn't problematic in this context.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Advice needed for partitioning hard drive. Fresh install multi booter. theKbStockpiler Linux - Newbie 2 01-09-2020 06:44 PM
How to install GRUB loader or dual booter paintedbull Linux - Newbie 6 04-12-2011 01:25 AM
I erased glibc-2.3.6 from my LFS-6.2 by mistake using PACO. Compiled replace needed. linux-geek Linux From Scratch 3 06-10-2008 04:42 PM
Dual booter won't load fatherg Linux - Newbie 9 01-27-2005 07:01 AM
Erased files by mistake Linucec Linux - General 5 05-21-2004 08:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 10:35 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration