Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ZFS with errors

1 view
Skip to first unread message

Luciano Mannucci

unread,
Apr 13, 2016, 9:01:24 AM4/13/16
to

Hello all,

I'm testing ZFS, so please forgive me for my dumb questions...
I have a pool with a zfs filesystem that shows erors. I tried to get
rid of them by removing the files listed by zpool status -v and
restoring without seeing anything different.
I tried with zpool scrub <mypool> and got only more errors.
My situation now is:
root@vodka:~ # zpool status -v
pool: expool1
state: ONLINE
status: One or more devices has experienced an error resulting in data
corruption. Applications may be affected.
action: Restore the file in question if possible. Otherwise restore the
entire pool from backup.
see: http://illumos.org/msg/ZFS-8000-8A
scan: scrub repaired 0 in 7h29m with 9 errors on Fri Apr 8 20:09:47 2016
config:

NAME STATE READ WRITE CKSUM
expool1 ONLINE 0 0 10
gptid/8ccea78c-05ef-4a3a-9502-4106ca736958 ONLINE 0 0 8
gptid/864c27ea-ecd2-4cf9-9450-1afad9065fa1 ONLINE 0 0 0
diskid/DISK-WD-WCC4M2780110s3 ONLINE 0 0 0
diskid/DISK-WD-WCC4M2780110s1 ONLINE 0 0 12

errors: Permanent errors have been detected in the following files:

expool1/mirrors:<0x600>
/var/spool/mirrors/mageia/distrib/4/x86_64/media/core/release/kde4-style-bespin-icons-0.1-0.1649svn.1.mga4.noarch.rpm
/var/spool/mirrors/mageia/distrib/4/x86_64/media/core/release/lilypond-doc-2.18.0-1.mga4.noarch.rpm
/var/spool/mirrors/mageia/distrib/4/x86_64/media/core/updates/wesnoth-data-1.10.7-2.1.mga4.noarch.rpm
expool1/mirrors:<0x6dba>
root@vodka:~ #


is there a way to see which "9 errors" did scrub find?
what I'm I suposed to do to clear the situation?

Thanks to everybody,

Luciano.
--
/"\ /Via A. Salaino, 7 - 20144 Milano (Italy)
\ / ASCII RIBBON CAMPAIGN / PHONE : +39 2 485781 FAX: +39 2 48578250
X AGAINST HTML MAIL / E-MAIL: posth...@sublink.sublink.ORG
/ \ AND POSTINGS / WWW: http://www.lesassaie.IT/
_______________________________________________
freebsd-...@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questi...@freebsd.org"

Trond Endrestøl

unread,
Apr 13, 2016, 9:42:23 AM4/13/16
to
Try:

zpool clear expool1
zpool scrub expool1

Let the scrub finish.

If the same three files reappears, then refetch those files.
The lines ending with a hexadecimal number represents deleted files,
as far as I know.

Once you have mended your files, run "clear" and "scrub" one more
time.

--
+-------------------------------+------------------------------------+
| Vennlig hilsen, | Best regards, |
| Trond Endrestøl, | Trond Endrestøl, |
| IT-ansvarlig, | System administrator, |
| Fagskolen Innlandet, | Gjøvik Technical College, Norway, |
| tlf. mob. 952 62 567, | Cellular...: +47 952 62 567, |
| sentralbord 61 14 54 00. | Switchboard: +47 61 14 54 00. |
+-------------------------------+------------------------------------+

Trond Endrestøl

unread,
Apr 13, 2016, 9:56:48 AM4/13/16
to
I noticed you have four disks in a striped configuration, aka RAID 0.

There's no redundancy in this pool, making it hard for ZFS to
automatically repair your files.

Maybe you should destroy your pool and recreate it using a mirrored
configuration. Maybe, mirror disks 1 & 2, and disks 3 & 4, e.g.

zpool create expool1 mirror gptid/8ccea78c-05ef-4a3a-9502-4106ca736958 gptid/864c27ea-ecd2-4cf9-9450-1afad9065fa1 mirror diskid/DISK-WD-WCC4M2780110s3 diskid/DISK-WD-WCC4M2780110s1
^^^^^^ ^^^^^^

Some proper disk labelling and setting the
kern.geom.label.gptid.enable tunable to 0 in /etc/loader.conf might
make it easier for you to identify each disk.

Luciano Mannucci

unread,
Apr 13, 2016, 10:23:21 AM4/13/16
to
On Wed, 13 Apr 2016 15:56:20 +0200 (CEST)
Trond Endrestøl <Trond.E...@fagskolen.gjovik.no> wrote:

> There's no redundancy in this pool, making it hard for ZFS to
> automatically repair your files.
>
> Maybe you should destroy your pool and recreate it using a mirrored
> configuration. Maybe, mirror disks 1 & 2, and disks 3 & 4, e.g.
They are of different sizes. I don't know if I can add redundancy
without loosing the bits that exeed the smallest one...
I'm a zfs newbie, just experimenting by now... :)

Thanks anyway,

Luciano.
--
/"\ /Via A. Salaino, 7 - 20144 Milano (Italy)
\ / ASCII RIBBON CAMPAIGN / PHONE : +39 2 485781 FAX: +39 2 48578250
X AGAINST HTML MAIL / E-MAIL: posth...@sublink.sublink.ORG
/ \ AND POSTINGS / WWW: http://www.lesassaie.IT/

Paul Mather

unread,
Apr 13, 2016, 11:23:34 AM4/13/16
to
Luciano,

> Date: Wed, 13 Apr 2016 16:22:51 +0200
> From: Luciano Mannucci <luc...@vespaperitivo.it>
> To: freebsd-...@freebsd.org
> Subject: Re: ZFS with errors
> Message-ID: <3qlQxr3...@baobab.bilink.it>
> Content-Type: text/plain; charset=iso-8859-1
>
> On Wed, 13 Apr 2016 15:56:20 +0200 (CEST)
> Trond Endrest?l <Trond.E...@fagskolen.gjovik.no> wrote:
>
>> There's no redundancy in this pool, making it hard for ZFS to
>> automatically repair your files.
>>
>> Maybe you should destroy your pool and recreate it using a mirrored
>> configuration. Maybe, mirror disks 1 & 2, and disks 3 & 4, e.g.
> They are of different sizes. I don't know if I can add redundancy
> without loosing the bits that exeed the smallest one...
> I'm a zfs newbie, just experimenting by now... :)
>
> Thanks anyway,
>
> Luciano.


The only way you can add redundancy to the type of pool you have (i.e., several drives concatenated together without any mirroring or raidz redundancy) is to set the "copies=..." property on datasets for which you want some redundancy:

copies=1 | 2 | 3
Controls the number of copies of data stored for this dataset. These
copies are in addition to any redundancy provided by the pool, for
example, mirroring or RAID-Z. The copies are stored on different
disks, if possible. The space used by multiple copies is charged to
the associated file and dataset, changing the used property and
counting against quotas and reservations.

Changing this property only affects newly-written data. Therefore,
set this property at file system creation time by using the -o
copies=N option.



Note the "Changing this property only affects newly-written data" part, though. You could also apply this selectively if you don't want to lose too much pool space, e.g., to impart some redundancy to files in your home directory but not to other areas where data loss can easily be remedied or isn't as much of a problem (/usr/src; /usr/ports; /usr/obj; etc.).

Cheers,

Paul.

Luciano Mannucci

unread,
Apr 13, 2016, 12:45:43 PM4/13/16
to
On Wed, 13 Apr 2016 11:15:50 -0400
Paul Mather <freebs...@gromit.dlib.vt.edu> wrote:

> The only way you can add redundancy to the type of pool you have (i.e.,
> several drives concatenated together without any mirroring or raidz
> redundancy) is to set the "copies=..." property on datasets for which you
> want some redundancy:
>
> copies=1 | 2 | 3
Good!
Seams apealing :)
I've set that and removed a big portion of the the filesystem, the one
containing errors. The srub is stll on its way, I'll relaunch it
tomorrow.

Thanks for now to all for the hints,

Luciano.
--
/"\ /Via A. Salaino, 7 - 20144 Milano (Italy)
\ / ASCII RIBBON CAMPAIGN / PHONE : +39 2 485781 FAX: +39 2 48578250
X AGAINST HTML MAIL / E-MAIL: posth...@sublink.sublink.ORG
/ \ AND POSTINGS / WWW: http://www.lesassaie.IT/

Brandon J. Wandersee

unread,
Apr 13, 2016, 7:53:02 PM4/13/16
to

Luciano Mannucci writes:

> On Wed, 13 Apr 2016 15:56:20 +0200 (CEST)
> Trond Endrestøl <Trond.E...@fagskolen.gjovik.no> wrote:
>
>> There's no redundancy in this pool, making it hard for ZFS to
>> automatically repair your files.
>>
>> Maybe you should destroy your pool and recreate it using a mirrored
>> configuration. Maybe, mirror disks 1 & 2, and disks 3 & 4, e.g.
> They are of different sizes. I don't know if I can add redundancy
> without loosing the bits that exeed the smallest one...
> I'm a zfs newbie, just experimenting by now... :)

Experimenting is good, but you've sort of dived head-first into the bad
practices deep end. A striped ZFS pool consisting of four disks of
different sizes is probably *less* reliable (and possibly less
performant) than a a single disk formatted with a traditional
filesystem. Your data has no redundancy, the pool will only perform as
well as the slowest of the four disks, and a problem with any one disk
will affect all data. Even a one-disk ZFS stripe with the "copies"
property raised is probably better than a large, multi-disk stripe.

You can read the original "ZFS Best Practices" guide for some more
info.[1] Some of it is either slightly out-of-date, or applies only to
Solaris, but most of it is still relevant to FreeBSD today.

If you're willing to spend a little money, "FreeBSD Mastery: ZFS" by
Michael W. Lucas is pretty good.[2]

[1]: http://www.solarisinternals.com/wiki/index.php/ZFS_Best_Practices_Guide
[2]: https://www.tiltedwindmillpress.com/?product=fmzfs

--

:: Brandon J. Wandersee
:: brandon....@gmail.com
:: --------------------------------------------------
:: 'The best design is as little design as possible.'
:: --- Dieter Rams ----------------------------------

Brandon J. Wandersee

unread,
Apr 13, 2016, 8:08:51 PM4/13/16
to

Brandon J. Wandersee writes:

> Even a one-disk ZFS stripe with the "copies"
> property raised is probably better than a large, multi-disk stripe.

...though I should add that a stripe of two completely identical disks
(make, model, size), while still vulnerable, will perform better than
one disk. ;)
0 new messages