You are not logged in.
Situation: I have a Windows + Arch dual boot setup, and 2 drives, 1 ssd and 1 hdd.
Both systems are installed on the ssd, and the hdd is divided into 2. I wanted to move some space from arch's hdd partition to windows' one, but ran into an issue. I was too lazy to make a gparted live install so I tried doing it while my arch system was running (after doing umount -l, with cfdisk).
When I try to boot into my arch system, I get this error:
[FAILED] Failed to start File System Check on /dev/disk/by-uuid/blah-blah
[DEPEND] Dependency failed for /hdd
[DEPEND] Dependency failed for Local File Systems.after that I get placed into emergency mode, but my root password doesn't work, I assume it's due to some keyboard layout shenanigans. (it won't allow me to log into my normal account)
I've also made a gparted live install, but I can't even use the unallocated space to expand my windows partion. It's a double lose situation.
The data on the corrupted disk is not crucial, but I wouldn't want to lose it, if it can be recovered. Any ideas?
Last edited by diniamo (2022-12-02 14:58:14)
Offline
Boot a live usb and fix your fstab so that the /hdd mount isn't fatal - or just remove it entirely from your fstab for now. Then you'll be able to boot and look into what's wrong with the device and / or run a manual fsck to get more details.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
How do I do the first part? Also my priority is getting the unallocated space into my windows partition, how can I do that?
Offline
Use a live Arch ISO or any other live distro, mount your Arch root partition and edit /etc/fstab to comment out the hdd. Then you can boot into Arch and focus on the hdd.
You'll need more information about the state of the hdd before you can decide how to deal with the problem. If you only care about allocating the space to Windows, you can obviously just re-partition the hdd. But obviously you'll lose everything on the hdd in that case, so it isn't an option if you want to recover data as you indicated originally.
CLI Paste | How To Ask Questions
Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L
Offline
And how exactly do I 'focus on the hdd'? What do I do after I booted succesfully?
Oh? It wasn't obvious to me. So I just broke my system for nothing, it's not possible at all without erasing the disk?
Offline
And how exactly do I 'focus on the hdd'? What do I do after I booted succesfully?
Not "how", "when" - after you can boot the system, to be precise.
You can get yourself a headstart by posting the outputs of
fdisk -land
lsblk -fFrom
I was too lazy to make a gparted live install so I tried doing it while my arch system was running (after doing umount -l, with cfdisk).
I suspect you didn't move/shrink the filesystem (depending on the actual layout, this can be hazardous, so I suggest you don't get creative here) and just altered the partition table.
In that case, simply restoring the previous partition table will get you back your filesystem - and is a necessary step to properly do what you wanted to do.
But first: comment the /hdd entry in your fstab and boot the system.
Offline
How do I do the first part?
The same way you did when you first installed your arch system. You did actually install archlinux, right? Or is this some derivative distro or "easy-installer" system?
Also my priority is getting the unallocated space into my windows partition, how can I do that?
Ah ... well, then you should probably tell us something about that if that's what you want help with. Your first post only vaguely referenced attempting to resize partitions on the hdd, then you showed the errors trying to boot the arch system - that made it seem like you wanted to first fix the problem with booting arch, which would also seem the sensible priority to me.
In any case, if you don't care about arch not booting, but you just want to finish what you started with th hdd, then you'll have to actually describe what you did*. You said you used cfdisk, that's it. What did you do in cfdisk exactly? Did you to anything to resize the filesystems either before or after your cfdisk use?
(*although at that point you are no longer working on the issue in an arch system, and it is no longer for and arch system, so it begs the question of how suited it even is for these forums.)
Last edited by Trilby (2022-12-01 14:23:51)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
I managed to boot the system.
fdisk -l: https://0x0.st/okz0.txt
lsblk -f: https://0x0.st/okzD.txt
(scd and sdd are usb drives)
and just altered the partition table.
Yes, I'm pretty sure that's what I did.
simply restoring the previous partition table will get you back your filesystem
How do I do that?
You did actually install archlinux, right? Or is this some derivative distro or "easy-installer" system?
Yes, it's completely vanilla arch, didn't even use archinstall.
Ah ... well, then you should probably tell us something about that if that's what you want help with.
I want help with both, but I wanted to do this in the first place because I don't have space for some software on my Windows install that I need for a deadline.
What did you do in cfdisk exactly?
I shrank the size of the linux hdd partition by 100GiBs (it was like 99,6 or something because I can't do math), then pressed write and quit because I couldn't modify the size of the windows partition.
(*although at that point you are no longer working on the issue in an arch system, and it is no longer for and arch system, so it begs the question of how suited it even is for these forums.)
Well I'm sorry if that's the case, but I've found the people of this forum the most helpful, so of course it's where I'm going to look for help, even if it's not fully related to Arch.
Offline
<49,17,III,I> Fama di loro il mondo esser non lassa;
<50,17,III,I> misericordia e giustizia li sdegna:
<51,17,III,I> non ragioniam di lor, ma guarda e passa.
Offline
How do I do that?
You change the partition table to the layout it had before you resized the partitions.
Offline
So I did, but I still get the same error message on boot.
Offline
updated lsblk/fdisk outputs?
This time please make sure to run fdisk as root.
Offline
fdisk: https://0x0.st/ok-E.txt
lsblk: https://0x0.st/ok-6.txt
For clarity: I executed both with sudo, and piped with |& in zsh shell
Offline
Disk /dev/sda: 931,51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: WDC WD10EZRZ-00H
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: 2FEFFDF6-0487-407B-96D0-3877A3499337
Device Start End Sectors Size Type
/dev/sda1 34 976762879 976762846 465,8G Microsoft LDM data
/dev/sda2 976762880 1953262990 976500111 465,6G Linux filesystem
/dev/sda3 1953262991 1953265038 2048 1M Microsoft LDM metadata
/dev/sda4 1953265039 1953525134 260096 127M Microsoft reserved
Partition 1 does not start on physical sector boundary.
Partition 3 does not start on physical sector boundary.
Partition 4 does not start on physical sector boundary.I severely doubt that this has been your previous partition layout.
You can use testdisk to search the drive for filesystems & partitions
https://archlinux.org/packages/extra/x86_64/testdisk/
https://www.cgsecurity.org/wiki/Menu_An … n_recovery
Offline
OK wow testdisk just fixed it while being the most straight-forward tool I've ever used. I find that crazy.
Thank god I got it back.
Now, how can I achieve my original goal?
Offline
1. have a backup
2. using gparted
What you want to do involves shrinking and then moving the linux filesystem before changing the partition table and growing the windows partition.
One can do that manually, but I suggest you don't and rely on an abstracting tool (even with a gui) for this.
And you still better have backups.
Offline
OK uh, somehow my windows partition is gone, and appears as unallocated space. When I boot windows it's just not there.
Uhh what do I do?
Offline
Thank god test disk fixed it again
Offline
It took a while (for gparted), but I did it!
You are an absolute legend seth, thank you so much!
Offline