Corrupted/destroyed my Linux install after resize

User discussion and information resource forum for Image products.
Post Reply
Gary Seven
Posts: 61
Joined: Mon Sep 05, 2011 2:17 pm
Location: Tarragona, Spain

Corrupted/destroyed my Linux install after resize

Post by Gary Seven »

I don't know where to start here. Today I used BootItBM to resize/slide my /home partition to give more space to my root (/) partition, and it seemed to work after rebooting into Linux Mint. I simply don't know what happened after that. After closing Linux and booting later in the day, boot failed. I then tried to restore my old setup using my Timeshift backups, but those failed too. Just get a screen warning me of "emergency" and giving me command line. On a whim I decided to reinstall Linux Mint 19.1 using my original partition structure, which is:

/boot
/
swap
/home

Of course "/" is the root or OS install directory. The reinstall went fine. But of course, everything I had in my /home partition was lost. I had a backup of the original /home partition, which I was able to restore using IFL. Upon reboot, Linux again complained and kicked me into a command line scenario calling it "emergency." Seems to me I've hosed everything, and Timeshift and/or IFL restores don't work. I just don't know WTF I am doing wrong!!

Edit: Forgot to mention I am doing all of this using original Bootit BM and/or IFL. No UEFI here. All MBR.
Brian K
Posts: 2214
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: Corrupted/destroyed my Linux install after resize

Post by Brian K »

Gary Seven wrote:

> I had a backup of the original /home partition, which I was able to restore
> using IFL. Upon reboot, Linux again complained and kicked me into a
> command line scenario calling it "emergency."

Gary,

This is worth trying. Maybe it will help. Restore that /home partition with the latest IFL. 3.26
Gary Seven
Posts: 61
Joined: Mon Sep 05, 2011 2:17 pm
Location: Tarragona, Spain

Re: Corrupted/destroyed my Linux install after resize

Post by Gary Seven »

Brian K wrote:
> Gary Seven wrote:
>
> > I had a backup of the original /home partition, which I was able to restore
> > using IFL. Upon reboot, Linux again complained and kicked me into a
> > command line scenario calling it "emergency."
>
> Gary,
>
> This is worth trying. Maybe it will help. Restore that /home partition with the
> latest IFL. 3.26
No good. Did the same thing after partition restore and kicks me back to this Linux "killed it" screen.
Gary Seven
Posts: 61
Joined: Mon Sep 05, 2011 2:17 pm
Location: Tarragona, Spain

Re: Corrupted/destroyed my Linux install after resize

Post by Gary Seven »

This is the screen I'm seeing after trying to restore my /home partition to my fresh Linux Mint 19.1 install. I'm quite a novice at Linux and don't know what commands to type in, even to get me to my boot or root partition. Pretty sure my SSD is called dev/sd1 with boot, root, swap and home called dev/sd1, dev/sd2, dev/sd3, and dev/sd4? Aren't there commands I can try to get Linux to attempt a file system repair?

At the very least, I'd like to get some notes and files that are in my /home partition image so as to use them again in the new install. Looks like I've totally hosed my system and I have to start over again from zero. All this because of a god-damned partition resize and slide operation. Very frustrated!
Attachments
Linux screen after failed Restore
Linux screen after failed Restore
IMG_8468.JPG (185.35 KiB) Viewed 3769 times
Brian K
Posts: 2214
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: Corrupted/destroyed my Linux install after resize

Post by Brian K »

Gary,

Do you have a TeraByte Entire Drive image backup of the SSD? A backup when everything was OK.
Gary Seven
Posts: 61
Joined: Mon Sep 05, 2011 2:17 pm
Location: Tarragona, Spain

Re: Corrupted/destroyed my Linux install after resize

Post by Gary Seven »

Brian K wrote:
> Gary,
>
> Do you have a TeraByte Entire Drive image backup of the SSD? A backup when
> everything was OK.
Unfortunately, no. All I had was an IFL image of my /home partition, plus the daily Timeshift backups. This was an experimental setup I had installed on a separate SSD inside my desktop box that also houses my current Win7 install on a completely separate SSD. I've been using the Linux OS since November in preparation to move away from Windows, and had installed tons of packages and done tons of stuff on it all to get used to it and improve my overall command of Linux. I never really got into learning the CLI very well (except for spoon fed instructions when installing this or that package or whatever), but in the process I had tons of notes to myself and URL's and holy shit the list goes on, and thought I was safe with both Timeshift and a IFL copy of the /home partition. I was under the impression that if I hosed my OS, I could reinstall it as new without affecting the /home partition. That is expressly why I divided my Mint install into the four individual partitions as described above.

Timeshift SHOULD have been able to recover me. But clearly something happened when I shrunk my /home partition by 10GB and slid the free space over to where the root (/) was, and then resized root. I don't know what failed here but it was big time. Don't know if it was me or simply the fact that the Linux FS behaves different than Windows.

So I've learned my lesson when I finally make the switch to Linux as my primary family (and business) OS. I will do imaging a little differently, and if I can avoid it NEVER do partition resize work on Linux (ext4) partitions ever again. I will also use the baked in app that comes with Mint to backup the /home partition to another drive on top of all the other backups I plan to do. This is freakin unreal. In all the 15 years I've done partition work with my various Windows installations, I've never experienced what happened yesterday.
Brian K
Posts: 2214
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: Corrupted/destroyed my Linux install after resize

Post by Brian K »

viewtopic.php?f=2&t=3021

Sorry, I realize this doesn't help you now.
DrTeeth
Posts: 1289
Joined: Fri Aug 12, 2011 6:58 pm

Re: Corrupted/destroyed my Linux install after resize

Post by DrTeeth »

On Sun, 10 Feb 2019 11:17:49 PST, just as I was about to take a herb,
Gary Seven disturbed my reverie and wrote:

>So I've learned my lesson when I finally make the switch to Linux as my primary family (and business) OS. I will do imaging a little differently, and if I can avoid it NEVER do partition resize work on Linux (ext4) partitions ever again. I will also use the baked in app that comes with Mint to backup the /home partition to another drive on top of all the other backups I plan to do. This is freakin unreal. In all the 15 years I've done partition work with my various Windows installations, I've never experienced what happened yesterday.

I have resized many ext4 partitions and never borked anything. I have
8 distros installed and I am forever rearranging by OS drive. I do not
use a separate home partition for all distros as different versions of
apps in each distro can cause problems with configs. I keep most data
files on a partition that is accessible to all my OSs

I do one IFW backup a day of my whole OS drive and can recover almost
anything. FWIW, I have just seen that Timeshift should be used to
backup the OS in a similar way to Windows System restore points
(https://forums.linuxmint.com/viewtopic.php?f=47&t=287735&p=1593033&hilit=%2Fhome#p1593033)
--
Cheers,

DrT

** Amateurs built the Ark, but professionals built the Titanic.**
TeraByte Support
Posts: 3598
Joined: Thu May 05, 2011 10:37 pm

Re: Corrupted/destroyed my Linux install after resize

Post by TeraByte Support »

after you restore, you can access the partition with IFL via mount, or you
can also just open the image in TBIView (from windows).



"Gary Seven" wrote in message news:16584@public.image...

This is the screen I'm seeing after trying to restore my /home partition to
my fresh Linux Mint 19.1 install. I'm quite a novice at Linux and don't
know what commands to type in, even to get me to my boot or root partition.
Pretty sure my SSD is called dev/sd1 with boot, root, swap and home called
dev/sd1, dev/sd2, dev/sd3, and dev/sd4? Aren't there commands I can try to
get Linux to attempt a file system repair?

At the very least, I'd like to get some notes and files that are in my /home
partition image so as to use them again in the new install. Looks like I've
totally hosed my system and I have to start over again from zero. All this
because of a god-damned partition resize and slide operation. Very
frustrated!

Post Reply