Filesystem corruption
Volker Wysk
post at volker-wysk.de
Wed Jun 26 11:10:06 UTC 2019
Am Mittwoch, den 26.06.2019, 11:10 +0200 schrieb Ralf Mardorf via
ubuntu-users:
> > Now i'm wondering if I should buy a new hard disk, before I
> > reinstall
> > Ubuntu...
>
> 3 ½ years could be a long time for a HDD, if it often needed to spin
> down and spin up. IOW if the machine is running 24/7, then 3½ years
> isn't old. If you shut down/power off and start up the machine
> several
> times a day or the HDD goes asleep and you or for example the evil
> gvfs
> of your GNOME install (or KDE's equivalent) wakes up the drive
> several
> times a day, than the drive could be old, already after ½ year or
> earlier.
Never heard of this.
It's virtually running 24/7. I'm not sure if it goes asleep and is
waken up all the time. Never heard of the evil GVFS... Isn't there a
tool or setting, which ensures that the harddisk isn't going into sleep
mode?
> > And I wonder if my backup is corrupted too. Probably...
>
> You are probably using a bad backup strategy. You should be able to
> restore from different old backups. The files from the latest backups
> are most likely corrupted, too, but a backup from 4 weeks ago might
> be
> ok.
That's the backup strategy I'm using. I've written a program for that.
I'm using several "generations", for backups with different age and
hence size. When the time is up in a generation, a new backup in that
generation is done. Afterwards a backup in the more frequent generation
is made, which is incremental to the last less-frequent generation.
It's a little hard to explain.
> On Wed, 26 Jun 2019 08:52:22 +0200, Volker Wysk wrote:
> > This is for /dev/sdb, which is an SSD
>
> Your SSD is not in the smartctl data base.
I think it is. "sudo smartctl -a /dev/sdb" prints this (among other
things):
=== START OF INFORMATION SECTION ===
Model Family: Western Digital Red
Device Model: WDC WD40EFRX-68WT0N0
Serial Number: WD-WCC4E7LACSDS
LU WWN Device Id: 5 0014ee 20b871f92
Firmware Version: 82.00A82
User Capacity: 4.000.787.030.016 bytes [4,00 TB]
Sector Sizes: 512 bytes logical, 4096 bytes physical
Rotation Rate: 5400 rpm
Device is: In smartctl database [for details use: -P show]
ATA Version is: ACS-2 (minor revision not indicated)
SATA Version is: SATA 3.0, 6.0 Gb/s (current: 3.0 Gb/s)
Local Time is: Wed Jun 26 12:41:07 2019 CEST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled
(Look at "Device is:")
> The SSDs I'm using are also
> not in its data base. The vendor of my SSDs provides proprietary,
> but free as in beer Linux software.
>
> If I run
>
> sudo ocz-ssd-utility
That's a propriety tool by Toshiba. I'm using a Samsung, which someone
(an acquaintance of my father) with much experience endorses.
>
> or gksudo..., I can access smart data, update the firmware while the
> SSDs are used etc., for Arch Linux I'm using a PKGBUILD from the AUR,
> https://aur.archlinux.org/packages/ocz-ssd-utility/.
There is no such tool in the Ubuntu package sources...
> If you take a look
> at the PKGBUILD, it's just a script, you can see the source,
>
https://ssd.toshiba-memory.com/download/software/ssd-utility/${pkgver}/SSDUtility_${pkgver}_Linux.zip
> replace "${pkgver}" with "2.3.2963", IOW use
>
https://ssd.toshiba-memory.com/download/software/ssd-utility/2.3.2963/SSDUtility_2.3.2963_Linux.zip
> assuming you should have an OCZ SSD.
It's a Samsung.
> The raw value for the Current_Pending_Sector attribute of your HDD
> should be 0.
It is.
> For the SSD all smart "functunality" related values should be 0,
> resp.
> my SSDs show idiotic unexpected power loss count values and I ignore
> those values, but the bad block count etc. values are 0 and should be
> 0
> for your SSD, too.
The Runtime_Bad_Block is 0.
The "Vendor Specific SMART Attributes with Thresholds" of the SSD
has the following attributes, all being zero:
Reallocated_Sector_Ct, Used_Rsvd_Blk_Cnt_Tot,
Program_Fail_Cnt_Total, Erase_Fail_Count_Total,
Runtime_Bad_Block, Uncorrectable_Error_Cnt, ECC_Error_Rate,
CRC_Error_Count.
The "WHEN_FAILED" value was "-" for all attributes.
These attributes have values other than zero: Power_On_Hours,
Power_Cycle_Count, Wear_Leveling_Count, Airflow_Temperature_Cel,
POR_Recovery_Count, Total_LBAs_Written.
> On what drive are the corrupted files?
Two drives are involved. I'm having a big HDD (4 TB), and use a 500 GB-
SSD as a persistent cache. It's all in one, encrypted file system. It
works (worked??) very well.
I think the SSD shouldn't be the reason.
> Are you using SATA cables with or without clips?
> I don't know if you should purchase a new drive, but it doesn't harm
> to
> reconnect the SATA and power cables and to replace SATA cables
> without
> clips by those with clips.
I've peeked inside my box, and it seems there are no clips. Just flat
plugs. And a lot of cables, which are bound together. Looks hard to
replace...
Isn't there a tool, which scans a harddisk for bad blocks, or for
corruption?
Bye
Volker
More information about the ubuntu-users
mailing list