0

My father is trying to move into Ubuntu, and has been playing around for a few months now. This morning he told me that the PC had crashed, and sent me these pictures:

picture 1

picture 2

  1. Is this a hardware error or a software error?

  2. If the latter, is a reinstall the only solution or can we expect to be able to save some files?

  3. If the former, is there any way to recover the data? He tells me that there are several files with no backup that he'd like to save, if possible.

karel
  • 114,770
BigCrash
  • 3
  • 2
  • 1
    Text is best included in the question not as screen shots. How was Ubuntu installed in the first place? Do you have the install live CD or USB that was used? – David Feb 12 '21 at 14:42
  • This is a hardware error. The system partition (something like C: in windows) has errors. The drive may be too old and failing or it may be something that can be fixed with fsck (something like chkdsk command in Windows). It is best to run fsck from a live USB/DVD. – user68186 Feb 12 '21 at 14:46
  • Thank you very much y'all, I'll send this to my father and cross my fingers :-) – BigCrash Feb 12 '21 at 14:48
  • I don't see an indication of a hardware problem (yet as not enough info to go off of). I would though run the manual fsck like it is stating to do fsck /dev/sda1. If it fails, I would recommend a backup of the important data then a clean install of the OS. If that fails, then you could be looking at a bad drive. – Terrance Feb 12 '21 at 15:07
  • @Terrance "If it fails, I would recommend a backup of the important data" Except for if the user data was on the problematic partition. If fsck fails on that partition, then how could one backup the data? – Levente Feb 12 '21 at 15:10
  • @Levente An inconsistency does not mean hardware failure. Just means that something in the software ain't right. If it is a problematic partition, they may not be able to access it all. fsck failing doesn't mean that the partition isn't accessible it just means that it can't fix whatever problems it is experiencing. I work around thousands of systems that run Linux on a daily basis and this inconsistency is nothing new. – Terrance Feb 12 '21 at 15:30
  • @Terrance would you say there is a chance of mounting this partition as is, before running fsck on it, from a live USB session? – Levente Feb 12 '21 at 15:31
  • @Levente Before or after would be fine. I have yet to see fsck destroy a partition to the point of non-recovery. Either way, we really don't know what we are up against. All we can give is suggestions to try to recover the boot of the system and that is about it. We know nothing else like OS version, hardware that the person is running Ubuntu on, etc. It is like the blind leading the blind. – Terrance Feb 12 '21 at 15:41

1 Answers1

1

Seems like a disk problem: so hardware.

Depending on how bad the problem is with the disk, there may still be hope to recover most if not all of the data.

The thing says that the problem is on the /dev/sda1 partition, which is the root filesystem.

With Ubuntu, it's a traditional choice to install the root filesystem in one partition, while installing user data, the so-called home filesystem on another, dedicated partition.

If this user-data-oriented home section is indeed located on its separate, dedicated partition, then there is a very high chance of full recovery of data.

If however the home section was installed together with the (now-problematic) root filesystem (on the same partition), the outlook may be quite different.

One thing to keep in mind: it's best to exhaust all options at copying the data out before running the fsck repair utility on a partition containing user data, because there is some chance that fsck ends up not being able to repair the partition, and then it would leave you in a worst state than before.

So it's a kind of all-or-nothing with fsck.

Update on this last sentece: according to high number of upvotes on this answer (suggested by @steeldriver), there seems to be a decent chance that fsck can deal with the problem.

Nevertheless, even in the case of success, there should be a lesson learned, and from then on important data should be regularly backed up to an independent device.


For the data recovery attempt, I would use a Live USB device, the one, or a similar one, that was used to install the OS in the first place.

These Live USB installer devices have a function: "Try Ubunutu without installing". If you use this feature, it gives you an Ubuntu operating system running on the computer that's operating entirely from the USB device, bypassing the faulty hard drive.

While using this USB-provided OS instance, it is possible to "mount" (connect) the internal HDD's partition that contains the user data (if it's indeed a dedicated partition separate from the problematic root filesystem). From then on it would be only a matter of attaching another storage medium to which the files can be copied.

Levente
  • 3,961
  • Thank you very much (can't vote!), I'll explain this to my father, hopefully we'll be able to fix it! – BigCrash Feb 12 '21 at 14:50