Gparted "move left" breaks install, no way to regenerate Grub

Hello, I recently used a Gparted LiveCD to move my bazzite partition left to extended it further as I was running out of space; and no longer needed the NTFS partition on the drive. Upon rebooting, I was able to see bazzite ostree listings as per usual, but upon booting it up I was forced into recovery mode and had a "root user account locked" error, preventing me from using the terminal. I proceeded to follow this tutorial: https://docs.fedoraproject.org/en-US/quick-docs/root-account-locked/ Which requires me to follow the steps here: https://docs.fedoraproject.org/en-US/quick-docs/grub2-bootloader/#_restoring_the_bootloader_using_the_live_disk But upon trying to chroot into /mmt, I recieve the error:
chroot: failed to run the command '/bin/bash' No such file or directory
chroot: failed to run the command '/bin/bash' No such file or directory
I have tried this a few different times with a few different live CDs. I am currently using Fedora-KDE-Live though. I have also tried running boot-repair-livecd which runs boot-repair via the terminal; and it provided me with the information that GRUB is looking for the partition starting at a data point much higher than what the actual start point is for that partition. I assume I have to update the partition table somehow, but I have no idea where this is... Now for completion sake, I have sdh4 which is my /boot drive, that's formated with FAT32 which contains an "EFI" and "System Volume Information" folder at it's root. SDH5 is an EXT4 "extended data" partition that is 1GB in size that has a "boot" (link), "efi", "grub2", "loader" (link), "loader.1", "lost+found" and an "ostree folder SDH6 is my home folder / bazzite folder which hosts my "boot", "dev", "home", "ostree", "proc", "root", "run", "sys", "tmp" and "var" folders. When following the instructions, I only used folders from SDH6 and SDH4 as I do not understand wat the SDH5 folders are. The EFI folder it has is entirely empty, and I don't want to break anything from my lack of understanding.
Fedora Docs
Root Account Locked
Phenomenon Cannot open access to console, the root account is locked in emergency mode (dracut emergency shell) Reason This is a known problem. It happens Fedora releases 28 and newer,…
Fedora Docs
The GRUB2 Bootloader – Installation and Configuration
GRUB2 is the latest version of GNU GRUB, the GRand Unified Bootloader. A bootloader is the first software program that runs when a computer starts. It is responsible for loading…
14 Replies
Dewm
Dewm•2w ago
Any other route I should be taking to fix this? Am I doing something worng or missing something? I am NOT using LUKS or any RAID for this. This is just a standard SSD setup. I managed to find /bin/sh within sdh6/root/ostree/boot.1.1/default/<LONG-STRING>/0/bin/sh. Is this safe to use? Or could this cause serious issues. I have also found this post, which explains something similar https://mildred.fr/quick-posts/2020-04-28-moving-fedora-silverblue-to-another-hdd/
wolfyreload
wolfyreload•2w ago
I suspect that in moving the drive it either failed halfway or the UUID of the drive changed somehow while it was getting moved. The other possibility is that your NTFS partition was listed in your /etc/fstab file which is now making your system fail to boot because it's gone. I would use a Live USB for Fedora/Mint/Ubuntu backup any important stuff from your user folder before doing anything. I did create a video for getting your system out of emergency mode https://ublue-os.github.io/bazzite/Advanced/Auto-Mounting_Secondary_Drives/?h=auto+mount#emergency-mode-after-mounting which might or might not help you.
Dewm
Dewm•2w ago
Ah shoot, you're right... I did have the fstab before with that partition that was deleted listed...
wolfyreload
wolfyreload•2w ago
Ah ok. Then still backup your stuff but try the video, I think it will help
Dewm
Dewm•2w ago
I was able to follow this and finally get it to chroot But yeah, I'm gonna try and see if I can edit the fstab and get in, or try an external grub If all else fails, backup and reinstall
wolfyreload
wolfyreload•2w ago
If you edit the fstab file externally from a live USB then sometimes os-tree would freak out. If you get in from grub then it tended to work nicely. If you managed to chroot then you probably fine
Dewm
Dewm•2w ago
hmmm Noted So grub first, got it.
wolfyreload
wolfyreload•2w ago
Good luck 🙂
Dewm
Dewm•2w ago
Cheers! Is there any way to regenerate the boot partition or something? I'm able to chroot, but I think I've managed to break my grub2 fully by this point. I know what mistakes I've made and how to do it right; but now I seem to be SOL on getting this booting.... I can get grub-install to work, but that's only for EFI; is there a way to get dnf to work in chroot? Or is there another method?
HikariKnight
HikariKnight•2w ago
there is no dnf in ostree idk the options fedora uses when it installs grub with ostree, but we have an ujust for regenerating grub, idk if it works in recovery mode but worth a shot if you have reinstalled grub ujust regenerate-grub but re-installing grub should not be neccessary unless you nuked your EFI partition from orbit but if you have messed around on the system from a live boot environment (and not the emergency mode) it will be way easier to just reinstall at that point.. if the original issue was just the missing ntfs partition then we could have just had you gone into recovery mode and edit the fstab and problem would been solved.
Dewm
Dewm•2w ago
Yeah, I realized that last bit now... I over complicated the issue. Everything I've done has been through chroot, but I have no access to ostree that way.
HikariKnight
HikariKnight•2w ago
touching anything through chroot or live environment can break the ostree
Dewm
Dewm•2w ago
Mhm I was able to get grub working, but but no entires listed and haven't had much success manually setting up a boot Is there a list of what I should backup? Or is it possible to keep some of my petitions and mount them?
HikariKnight
HikariKnight•2w ago
anything in your home directory that you want to keep. you are only reformating the bazzite partitions, youre not touching your other disks/partitions your home directory is in /var/home on the bazzite partition
Want results from more Discord servers?
Add your server