Well....I deleted my /boot/efi partition accidently

So a little back story, I have made the full switch to Linux now for and FULL switch for about a week. I love to tinker and learn. I was loath to do it but I really wanted to play black ops 4…to no avail could I get the game to launch and not crash so I installed windows…in the process I accidently deleted manjaro efi partition. Any tips on how to get this back, i’m currently thinking simply reinstalling manjaro is the simplest way, plus its more time to learn how to re set up all my programs etc…thanks and sorry if this is a simple answer, I’m going to live boot and see if I can resize the partition of Linux and then create a /boot/efi mount point and do a simple grub install…

THanks guys, great community and I know I haven’t posted but I do lurk and learn a LOT!

You only need one efi partition for Windows and Linux. It is hard to say without more information but it is normal for Windows to “take over” your efi partition if you install Windows second.

It may be as simple as booting into your Manjaro install and running update-grub.

I’m in a live boot at the moment, what I did was in the windows install I was all willy nilly deleting partitions on my SSD and clicked the wrong partition and deleted it…thus I can’t even select manjaro when I load my bios boot menu

Can we see the output of sudo parted -l

That will give us some insight into what your disks look like.

I’m very novice in the linux world but its a fun journey for me so please, I do apologize for being a complete blind man in this

I will in one second, I was resizing my manjaro partition to make a 300mb efi partition but its been taking over 5 minutes thus far, and the sudo parted -l isn’t working. I gather it won’t work while the KDE partition program is trying to run.

Resizing a partition can take a while. Don’t cancel or interrupt it in the middle.

Yes that I would never do haha!

Thanks for the speedy help though, I really do appreciate it. I have to say, the linux OS is just so much superior and I can’t believe I hadn’t made the switch sooner.

1 Like
Model: ATA WDC WD10EADS-11M (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  530GB   530GB  ext4         steamgames
 2      530GB   1000GB  470GB  ntfs         Basic data partition  msftdata


Model: ATA ST31000424CS (scsi)
Disk /dev/sdb: 1000GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system  Name                          Flags
 1      17.4kB  16.8MB  16.8MB               Microsoft reserved partition  msftres
 2      16.8MB  1000GB  1000GB  ntfs         Basic data partition          msftdata


Model: ATA ST1000LM010-9YH1 (scsi)
Disk /dev/sdc: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type     File system  Flags
 1      1049kB  1000GB  1000GB  primary  ntfs         boot


Model: Generic USB Flash Disk (scsi)
Disk /dev/sdd: 15.7GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type     File system  Flags
 2      2143MB  2148MB  4194kB  primary               esp


Model: ATA WDC WD10JPVT-00A (scsi)
Disk /dev/sde: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system  Name                  Flags
 1      1049kB  1000GB  1000GB  ntfs         Basic data partition  msftdata


Model: ATA SAMSUNG SSD CM87 (scsi)  <----- My dual boot drive
Disk /dev/sdf: 128GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system  Name                          Flags
 1      1049kB  524MB   523MB   ntfs         Basic data partition          hidden, diag
 2      524MB   629MB   105MB   fat32        EFI system partition          boot, esp
 3      629MB   646MB   16.8MB               Microsoft reserved partition  msftres
 4      646MB   54.4GB  53.7GB  ntfs         Basic data partition          msftdata
 5      54.4GB  128GB   73.3GB

I’m starting to read through the arch wiki on the EFI system partition to get a better understanding of this.

OK.

Is this right?

You have 4 1TB drives
ATA WDC WD10EADS-11M contains you primary linux install and some Windows data.
ATA ST31000424CS contains some Windows data
ATA ST1000LM010-9YH1 contains Windows data. It is also marked as bootable. Was this your primary Windows drive at some point in the past?
ATA WDC WD10JPVT-00A contains some windows data

You have a 128GB SSD, containing your efi partition, windows install and windows recovery partition.

If all this is correct you have a couple of choices.

  1. You could simply install grub into your existing efi partition on /dev/sdf2
  2. You could create a seperate efi partition for Linux on /dev/sda

So, I have 4 1TB drives, They all came from and all windows install and windows was always installed to the 128GB SSD. I then formatted the SSD and installed manjaro (I could never figure out how to clear, or rathe safely clear the windows "bootable, or bootloaders from the 1TB drives)

I resized the SSD and went to install windows but in the process I deleted the manjaro EFI partition and I really don’t know how the hell I didn’t realize as I clicked to delete it.

The 1TB drive that has ext4 I simply used half for linux steam games and then half for some of windows games if I needed.

One of the drives was for downloads and some apps from previous windows and one is all for media and then the last one is all Learning videos and courses I’ve bought from lynda learning

So partition 5 above is your linux install? Hopefully it looks like that because you had a resize operation happening at the time.

Model: ATA SAMSUNG SSD CM87 (scsi)
Disk /dev/sdf: 128GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags:

Number Start End Size File system Name Flags
1 1049kB 524MB 523MB ntfs Basic data partition hidden, diag
2 524MB 629MB 105MB fat32 EFI system partition boot, esp
3 629MB 646MB 16.8MB Microsoft reserved partition msftres
4 646MB 54.4GB 53.7GB ntfs Basic data partition msftdata
5 54.4GB 128GB 73.3GB ext4

post resize, I did the sudo parted -l again

and YES partition 5 is the linux install ***

Looks better.

Option #1 above still applies, it is the “standard” dual-boot scenario. The alternative is to have separate efi partitions.

The advantage of separate efi partitions is that Windows should stay out of that partition stopping this from happening the next time you get a version upgrade from Windows. The downside is that you need to use your BIOS to select what OS to boot or get more elaborate with your bootloaders.

I can’t boot into Linux though, I must be missing something.

Even the bios boot menus doesn’t list it, think I will simply format and reinstall Manjaro again and set up from scratch now that I have windows installed and let Linux bootloader handle it.

I thought I had read before that installing Linux after windows the the most fluid way to handle a dual boot situation

You need to chroot into your installation from the live disk. There are a couple of tutorials on how to do that around here.

That will also resolve the situation if there is no important data you need to maintain :grin:

That is true, although to be more specific, it is installing the Linux bootloader afterwards that is really important.

1 Like

Ahh yes “chroot” I’ve played with this before when getting my steamgames partition and some other things. I’ll search that and see if I can’t get in doing that, thanks for all the tips here, again I really appreciate it!

I tend to “break” things a lot and have tons of fun fixing it haha.

1 Like

Me too. It is one of the best ways to learn.

1 Like

If you have just ‘formatted’ your $esp partition, not deleted that partition, just use this link. the [Simple First Start] will do.

However if you have deleted $esp, at livecd OS or another OS, change the fstab of the $esp to the correct UUID. Then follow the above same steps in paragraph above.

No need to chroot.

3 Likes

Forum kindly sponsored by Bytemark