Rocksolid Light

Welcome to RetroBBS

mail  files  register  newsreader  groups  login

Message-ID:  

Portability should be the default. -- Larry Wall in <199711072201.OAA01123@wall.org>


computers / comp.misc / Re: Repairing an XFS partition that uses V1 inodes....

SubjectAuthor
o Re: Repairing an XFS partition that uses V1 inodes....SH

1
Re: Repairing an XFS partition that uses V1 inodes....

<u9dtr2$38cj2$1@dont-email.me>

  copy mid

https://www.rocksolidbbs.com/computers/article-flat.php?id=2692&group=comp.misc#2692

  copy link   Newsgroups: comp.misc alt.comp.misc uk.comp.misc
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: i.love@spam.com (SH)
Newsgroups: comp.misc,alt.comp.misc,uk.comp.misc
Subject: Re: Repairing an XFS partition that uses V1 inodes....
Date: Fri, 21 Jul 2023 13:31:30 +0100
Organization: A noiseless patient Spider
Lines: 125
Message-ID: <u9dtr2$38cj2$1@dont-email.me>
References: <u98esj$23rjv$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Fri, 21 Jul 2023 12:31:30 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="29fa63801fded2f546c6d3b06c51205f";
logging-data="3420770"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18UUx0XRJzJ4zn/Idkaako+P72ASaYqzlA="
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.13.0
Cancel-Lock: sha1:yAJaQl4zj6wNmMl7AKEAWL/xpwY=
In-Reply-To: <u98esj$23rjv$1@dont-email.me>
 by: SH - Fri, 21 Jul 2023 12:31 UTC

On 19/07/2023 11:45, SH wrote:
> Right....
>
> I have a CCTV recorder with 5 hard discs.
>
> This recorder created 2 XFS partitions on every 1 of the 5 hard discs.
>
> The CCTV recorder started reporting that one of the hard discs had gone
> offline.
>
> I've pulled this disc out and placed another hard disc in its place. So
> the DVR is now back in business.
>
> Howver, the pulled disc contains 17 days worth of footage from 8 cameras
> that is no longer available to the DVR by virtue of being pulled out.
>
> The Pulled disc was then connected to a PC ruuning a Live instance of
> Ubuntu. There are two partitions on the pulled disc both XFS, as sdb1
> and sdb2.
>
> Using GParted to interrogate the SMART data and also used SMARTCTL in
> the terminal box indicates the hard disc has no defects at all.
>
> I then tried to mount both of the two XFS partitions.
>
> It reported that neither partition could be mounted as:
>
> Error mounting filesystem /dev/sdbN cant read superblock on /dev/sdbN
>
> Where N is 1 or 2.
>
> So I then tried to use xfs_repair on these two partitions in a terminal
> window.
>
> XFS-Repair comes back with V1 indoes unsupported, please try an older
> XFSprogs.
>
> I then downloaded Centos 5 Live CD as this has an older version of
> xfs-progs.  However, this will not laod on any PC as it ends with a
> Kernal panic and hangs with a page of text after the Centos splash screen.
>
> I then rebooted into ubuntu live with a another spare HDD I also
> happened to have to hand.
>
> I proceeded to use DDrescue to recover the data from the pulled disc.
> This has now completed with absolutely no errors and I now have a IMG
> file on the 2nd HDD.
>
> So it appears all my files are intact, its a bad superblock both of teh
> XFS partitions on the pulled hard disc
>
> So I would like ot be able to do one of two things:
>
> 1. Somehow repair the XFS partition with a program that supports W1
> inodes with a linux distro that will (a) boot without a kernel panic and
> (b) has an old enough xfsprogs
>
> 2. or somehow mount & open the test.img file on the 2nd HDD so I can
> then view the video files within. I tried to do this but it reports an
> unsupported FS even though both Debian and Ubuntu both support XFS
> partitions.
>
> Stephen.
>
>
>

UPDATE!

I discovered that GPartEd is available as a Live CD download and that
previous versions were still available.

So I downloaded GPartEd Live v0.23.0-1 which had support for XFS with v1
inodes.

So I booted up this via Ventoy with the pulled 4 TB disc and another 4
TB disc (formatted to XFS with inode version > 1.) as this disc had the
IMG image of the pulled disc via DDrescue.

GPartEd could see both hard discs.

There was no yellow exclaimation marks against the pulled disc in
GPartEd but it was unmountable.

So I ran xfs_repair sda1 and xfs_repair sdz2.

Both proceeded well and then I was able to mount both partitions and
view the files within both partitions in a file explorer.

GPartEd Live v0.23.0-1 reported it could not recognise the partition on
the 2nd HDD.

That is hardly surprising as this version of GPartEd live was compatible
with v1 inodes, and thie version of GPartED Live v0.23.0-1 predates any
later versions of XFS supporting inode versions > v1.

(The 2nd HDD had been formatted to a later version of XFS using inode
version > 1)

I then put the pulled disc back into my DVR recorder and lo and behold,
the 17 days of footga ei snow available!

Several lessons from this:

What caused the XFS superblock corruption in the first place? A failing
PSU or momentary main supply glitch? I shall investigate puttign a UPS
on it.

The DVR clearly is unable to do its own hard disc housekeeping with
xfs_repair or even FSCK and just reports check disc or failed disc.

The DVR clearly running a version of Linux that predates 2007 (as thats
when XFS with inode version > 1 came out.

Theer is currently no means of backup from the DVR to say a Network NAS
or an eSATA hard disc so that there is footage available should a HDD
fail again. So I will have to investigate this.

As it happens the DVR does have some eSATA ports on the back, so with
the 5 x 4 TB drives within, I'm looking at a 20 TB external eSATA drive
or working out how to get the DVR to back up over a network to a NAS.
The video files within are of SSF format, but when backed up to CD/DVD
or memory stick become AVI or SEC files. SO I'm not sure what it will
get saved as if backed up to eSATA.

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor