You are not logged in.

#1 2013-09-23 22:16:14

plomp90
Member
Registered: 2013-09-23
Posts: 16

Wrote over Windows EFI, now I can't boot

Hello, I've been running Arch on a USB up until now and I've been trying to install it from the USB to dual-boot alongside Windows 8. I disabled secure boot, so I'm able to boot from the USB, but whenever I run "cfdisk /dev/sda" or "cfdisk /dev/sda1" (the partition I made for Arch), it comes up with "FATAL ERROR: Bad primary partition 1: Partition begins after end-of-disk".
I have Windows 8 running on a 650 gb partition of my 1 tb hard drive, and another partition I created for Arch called sda1 (with 190 gigs), as well as 160 gigs of unused space. I did "fdisk /dev/sda" and it says something like "the device presents a logical sector size that is bigger than its physical sector size".

What am I doing wrong? I'm pretty stupid concerning partitioning, and I'm an Arch newbie, so sorry if this inquiry is a little dumb.

Thanks in advance for any advice you can give.

Last edited by jasonwryan (2013-09-24 00:08:37)

Offline

#2 2013-09-23 22:26:51

headkase
Member
Registered: 2011-12-06
Posts: 1,975

Re: Wrote over Windows EFI, now I can't boot

https://wiki.archlinux.org/index.php/GU … tion_Table

I'm half guessing: your hard-disk partitions may be GPT format and fdisk is expecting MBR format.  Try cgdisk:

https://wiki.archlinux.org/index.php/Be … partitions

To interact with your partitions.

Important note: disable Windows 8 hybrid boot (it is in the Power options) or you will run the risk of corrupting your Windows partition if you access it from Linux in your dual-boot.  Hybrid boot "hibernates and powers down" Windows.  It does not fully sync the filesystem when it does that as when it comes back up it is in the state it left with.  If between the hybrid shutdown and subsequent power up if you modify the Windows partition with Linux that can cause issues.

I would also recommend using the Windows Disk Management snap-in to create some free space on your hard-drive initially and then when you boot off the Arch CD use that free space in your install.

Offline

#3 2013-09-23 23:25:07

plomp90
Member
Registered: 2013-09-23
Posts: 16

Re: Wrote over Windows EFI, now I can't boot

AAAAAAAAAAH
I did as you said (it worked, thanks) and then followed the installation instructions on the Arch wiki, and tried to write the EFI partition, but it failed and wrote over some of the Windows RE! Now Windows won't boot! Aaaaaaaaargh!

Offline

#4 2013-09-23 23:39:16

headkase
Member
Registered: 2011-12-06
Posts: 1,975

Re: Wrote over Windows EFI, now I can't boot

You're welcome.

I don't know how to restore Windows EFI record, I suggest that you edit your first post in this thread and change the title to your new issue - that way people will see that first.

Offline

#5 2013-09-24 00:00:53

2ManyDogs
Forum Moderator
Registered: 2012-01-15
Posts: 4,645

Re: Wrote over Windows EFI, now I can't boot

headkase wrote:

I suggest that you edit your first post in this thread and change the title to your new issue

AND PLEASE DON'T YELL AT US (don't post in all caps). AAAAAH and Arrrgggggh won't get you any better help any faster. Thank you, and welcome to Arch.

(edit) this post made more sense before the OP edited his topic title -- it used to be in all capitals. Thank you plomp90.

Last edited by 2ManyDogs (2013-09-24 00:10:42)


How to post. A sincere effort to use modest and proper language and grammar is a sign of respect toward the community.

Offline

#6 2013-09-24 03:14:47

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: Wrote over Windows EFI, now I can't boot

plomp90 wrote:

I did as you said (it worked, thanks) and then followed the installation instructions on the Arch wiki, and tried to write the EFI partition, but it failed and wrote over some of the Windows RE! Now Windows won't boot! Aaaaaaaaargh!

First, the post-mortem analysis: You should have backed up the ESP before doing anything else. (That advice should probably be in the wiki somewhere....) The ESP holds your boot loaders, and is written to from multiple OSes, so it's both unusually sensitive to damage and unusually susceptible to damage -- a dangerous combination!

Second, your complaint is extremely scarce on details. You haven't said precisely what steps you followed or precisely what symptoms you're experiencing. ("Windows won't boot" is imprecise -- it could be that the system doesn't power on, that you see a Windows option in some (unspecified) boot loader that fails the moment it's selected, that you see a Windows splash screen followed by a BSOD, that you see a screenful of error messages, etc. People here can be very helpful, but that depends on their having information.

If you're not sure what sort of information to provide, I recommend starting with the Boot Info Script. Run it from a Linux emergency disc. It will produce a file called RESULTS.txt. Post that file here, either between code tags or as a link to the file on your own Web site or on a pastebin site. (Do not post it directly without using code tags, since important parts will be rendered nearly illegible by the forum's normal reformatting.)

Offline

#7 2013-09-24 09:10:32

Padfoot
Member
Registered: 2010-09-03
Posts: 381

Re: Wrote over Windows EFI, now I can't boot

While it is not exactly clear in the Arch Wiki UEFI page, you can, and I recommend you do, have multiple EFI System Partitions. I have two on my system since I dual boot Windows and Arch. The Windows ESP is completely untouched by Linux and the Linux ESP is completely untouched by Windows.

This keeps both OSes in total isolation from each other so updates to one will not inadvertently bork the other.

All you need besides this is your UEFI firmware being able to recognise both ESPs and thus boot from them, or use a UEFI "boot loader" (it's technically not a boot loader in the same way as Grub for instance) like Refind or Gummiboot.

Cheers.

Offline

#8 2013-09-24 19:39:30

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: Wrote over Windows EFI, now I can't boot

Padfoot wrote:

While it is not exactly clear in the Arch Wiki UEFI page, you can, and I recommend you do, have multiple EFI System Partitions. I have two on my system since I dual boot Windows and Arch. The Windows ESP is completely untouched by Linux and the Linux ESP is completely untouched by Windows.

This keeps both OSes in total isolation from each other so updates to one will not inadvertently bork the other.

I disagree. The problem is that the Windows installer (at least as of Windows 7; I've not tried Windows 8) becomes confused if it sees multiple ESPs. The result is that re-installing Windows in this way may be difficult. It's conceivable that some tools within a running Windows 8 installation will become confused, too, although I don't know of any specific examples. Microsoft explicitly states that they don't support systems with more than one ESP. To be sure, this is unfortunate, and the EFI spec explicitly says that multiple ESPs are allowed, so Microsoft is narrowing the playing field with this restriction. Still, if you install Windows on the computer, you've got to live with its limitations.

If you do run with multiple ESPs, you should be aware of this problem, and be prepared to adjust the partition table to change the type code of the non-Windows ESP(s) should you ever need to re-install Windows or should you have problems within Windows that you suspect may be caused by this configuration.

All you need besides this is your UEFI firmware being able to recognise both ESPs and thus boot from them, or use a UEFI "boot loader" (it's technically not a boot loader in the same way as Grub for instance) like Refind or Gummiboot.

Boot loaders load kernels into memory and boot managers give the user a choice of what OS to boot. They're entirely different types of programs, but the most popular Linux boot programs in BIOS (LILO, GRUB Legacy, and GRUB 2) all provide the functionality of both program types. In the EFI world, rEFInd and gummiboot are both boot managers but not boot loaders. ELILO and the EFI stub loader are both boot loaders but not boot managers (except insofar as ELILO enables you to select between different Linux kernels). GRUB 2, just as under BIOS, does both jobs.

Offline

#9 2013-09-26 09:24:52

Padfoot
Member
Registered: 2010-09-03
Posts: 381

Re: Wrote over Windows EFI, now I can't boot

srs5694 wrote:

All you need besides this is your UEFI firmware being able to recognise both ESPs and thus boot from them, or use a UEFI "boot loader" (it's technically not a boot loader in the same way as Grub for instance) like Refind or Gummiboot.

Boot loaders load kernels into memory and boot managers give the user a choice of what OS to boot. They're entirely different types of programs, but the most popular Linux boot programs in BIOS (LILO, GRUB Legacy, and GRUB 2) all provide the functionality of both program types. In the EFI world, rEFInd and gummiboot are both boot managers but not boot loaders. ELILO and the EFI stub loader are both boot loaders but not boot managers (except insofar as ELILO enables you to select between different Linux kernels). GRUB 2, just as under BIOS, does both jobs.

I know this, that is why I said it is technically not a bootloader, whereas many a lay person will simply recognise it as a bootloader, so simply using terms people would be more familiar with.

srs5694 wrote:
Padfoot wrote:

While it is not exactly clear in the Arch Wiki UEFI page, you can, and I recommend you do, have multiple EFI System Partitions. I have two on my system since I dual boot Windows and Arch. The Windows ESP is completely untouched by Linux and the Linux ESP is completely untouched by Windows.

This keeps both OSes in total isolation from each other so updates to one will not inadvertently bork the other.

I disagree. The problem is that the Windows installer (at least as of Windows 7; I've not tried Windows 8) becomes confused if it sees multiple ESPs. The result is that re-installing Windows in this way may be difficult. It's conceivable that some tools within a running Windows 8 installation will become confused, too, although I don't know of any specific examples. Microsoft explicitly states that they don't support systems with more than one ESP. To be sure, this is unfortunate, and the EFI spec explicitly says that multiple ESPs are allowed, so Microsoft is narrowing the playing field with this restriction. Still, if you install Windows on the computer, you've got to live with its limitations.

If you do run with multiple ESPs, you should be aware of this problem, and be prepared to adjust the partition table to change the type code of the non-Windows ESP(s) should you ever need to re-install Windows or should you have problems within Windows that you suspect may be caused by this configuration.

Fair enough, if the case is you are installing windows after linux. For most this would not be the case. Windows is already installed, or if it is not, I am sure the same advice still applies of always installing windows first as we all know how selfish windows is when it comes to the boot process.

Cheers.

Offline

#10 2013-09-26 16:50:52

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: Wrote over Windows EFI, now I can't boot

Padfoot wrote:
srs5694 wrote:
Padfoot wrote:

While it is not exactly clear in the Arch Wiki UEFI page, you can, and I recommend you do, have multiple EFI System Partitions.

I disagree. The problem is that the Windows installer (at least as of Windows 7; I've not tried Windows 8) becomes confused if it sees multiple ESPs.

Fair enough, if the case is you are installing windows after linux. For most this would not be the case. Windows is already installed, or if it is not, I am sure the same advice still applies of always installing windows first as we all know how selfish windows is when it comes to the boot process.

First, few Windows installations survive long without needing re-installation. Thus, setting up two ESPs, even if Windows is already installed, is likely to cause problems down the road. This problem can be worked around by adjusting the ESP type codes, but by the time Windows needs to be re-installed, the user is likely to have forgotten the details of what needs to be done.

Second, there may be tools within a running Windows installation that make assumptions about the number of ESPs on the disk. I don't know this for a fact, but as Microsoft explicitly says that they don't support multiple ESPs, it's better to err on the side of caution on this score.

Offline

#11 2013-09-27 09:01:41

Padfoot
Member
Registered: 2010-09-03
Posts: 381

Re: Wrote over Windows EFI, now I can't boot

Fair enough. All I can say is I have been running multiple ESPs with windows 8 for quite a while now, and have suffered 0 issues.

Offline

Board footer

Powered by FluxBB