Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
ZFS Questions
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
FastTurtle
Guru
Guru


Joined: 03 Sep 2002
Posts: 431
Location: Flakey Shake & Bake Caliornia, USA

PostPosted: Sat Jan 04, 2020 8:20 am    Post subject: ZFS Questions Reply with quote

Doing lots of reading in regards to ZFS and one feature I don't like is the stripping across all drives in the pool since it appears to be a variant of Raid 0. Docs indicate that loosing any drive in a pool looses the entire pool and that's not a good thing when dealing with Solid State Disks.

My big question is, can this be disabled - either in settings or through using a single drive in a pool? Main thing I want is the Checksum capability right now and in the future I'll add drives to the pool and get the increased speeds but using Raid 1 (Mirror) setup.

Is it possible to recover data from a Pool when one of the drives has died if it's not in a Raid setup?
Back to top
View user's profile Send private message
bunder
Bodhisattva
Bodhisattva


Joined: 10 Apr 2004
Posts: 5910

PostPosted: Sat Jan 04, 2020 11:12 am    Post subject: Reply with quote

you don't have to use striping, that only applies to multiple vdevs (of single disks, mirrors, or raidz arrays). eg:

single disk pool (no redundancy)
Code:
zpool create mypool sda


striped pool (traditional raid 0 - no redundancy)
Code:
zpool create mypool sda sdb


mirrored pool (traditional raid 1 - redundancy as long as one disk survives)
Code:
zpool create mypool mirror sda sdb


raidz pool (traditional raid 5 - redundancy as long as n-1 disks survive)
Code:
zpool create mypool raidz1 sda sdb sdc


striped raidz2 pool (two raid 6's striped together - redundancy as long as n-2 disks survive per raidz2 set)
Code:
zpool create mypool raidz2 sda sdb sdc sdd raidz2 sde sdf sdg sdh


cheers
_________________
Neddyseagoon wrote:
The problem with leaving is that you can only do it once and it reduces your influence.

banned from #gentoo since sept 2017


Last edited by bunder on Sat Jan 04, 2020 3:46 pm; edited 2 times in total
Back to top
View user's profile Send private message
FastTurtle
Guru
Guru


Joined: 03 Sep 2002
Posts: 431
Location: Flakey Shake & Bake Caliornia, USA

PostPosted: Sat Jan 04, 2020 3:23 pm    Post subject: Reply with quote

You have the "- stripes" in that first line of code; is that what I want?
Back to top
View user's profile Send private message
bunder
Bodhisattva
Bodhisattva


Joined: 10 Apr 2004
Posts: 5910

PostPosted: Sat Jan 04, 2020 3:38 pm    Post subject: Reply with quote

sorry, i could have made that easier to parse, i edited my post and included a single disk setup as well.
_________________
Neddyseagoon wrote:
The problem with leaving is that you can only do it once and it reduces your influence.

banned from #gentoo since sept 2017
Back to top
View user's profile Send private message
FastTurtle
Guru
Guru


Joined: 03 Sep 2002
Posts: 431
Location: Flakey Shake & Bake Caliornia, USA

PostPosted: Sat Jan 04, 2020 3:43 pm    Post subject: Reply with quote

So the only way to avoid the stripping is the single disk pool. Damn and the ZFS docs basically indicate the same thing. Stripping is baked so deep that you can't have multiple disks in a pool without it.

I do like the idea of using the Raid 1 feature as it saved my back with a failed drive. Not pretty but that was a spinner and I'm now all SSD and I backup on a regular schedule - which has saved me from a reinstall recently. Screwed something up and couldn't boot the system.


Last edited by FastTurtle on Sun Jan 05, 2020 3:09 pm; edited 1 time in total
Back to top
View user's profile Send private message
bunder
Bodhisattva
Bodhisattva


Joined: 10 Apr 2004
Posts: 5910

PostPosted: Sat Jan 04, 2020 3:46 pm    Post subject: Reply with quote

striping doesn't apply to mirrors unless you stripe multiple mirrors together.
_________________
Neddyseagoon wrote:
The problem with leaving is that you can only do it once and it reduces your influence.

banned from #gentoo since sept 2017
Back to top
View user's profile Send private message
FastTurtle
Guru
Guru


Joined: 03 Sep 2002
Posts: 431
Location: Flakey Shake & Bake Caliornia, USA

PostPosted: Sat Jan 04, 2020 4:01 pm    Post subject: Reply with quote

If Pendantic: Stripping is part of Raid 1 as it writes to both drives at the same time with the same size stripe.

Seriously though, the only way and it is not recomended is to have a single drive in the pool but once you add another drive to that pool, it will stripe across them as that feature was baked in from the beginning. As I'm not a programmer - not even a script kiddy - I have no clue if it's even possible to pull it out without starting fresh and at that point, the primary feature we want is the checksums. Oh well, as I said, I'll be doing routine backups followed by a Raid 1 setup when I get the additional drives. At least I can get the Check Sum feature though I'll have to look into how to confiugre my 2TB external SSD with ZFS to enable the checksums. Makes backups very nice
Back to top
View user's profile Send private message
bunder
Bodhisattva
Bodhisattva


Joined: 10 Apr 2004
Posts: 5910

PostPosted: Sat Jan 04, 2020 4:13 pm    Post subject: Reply with quote

you can add a disk to a single disk pool and it will become either a stripe or a mirror.

given a pool consisting of just sda:

turning a single disk into a mirror
Code:
zpool attach mypool sda sdb


turning a single disk into a stripe
Code:
zpool add mypool sdb


cheers
_________________
Neddyseagoon wrote:
The problem with leaving is that you can only do it once and it reduces your influence.

banned from #gentoo since sept 2017
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 15294

PostPosted: Sat Jan 04, 2020 4:47 pm    Post subject: Reply with quote

To be pedantic, stripping is for reducing program size by removing unnecessary sections. Striping is for data layout. ;)

To be helpful, if you really hate having zfs stripe your data and you don't want mirroring, you could use the device mapper to combine your multiple physical devices into a single logical device, then give zfs that one logical device. It will see that it has "1 disk" and not engage in striping.
Back to top
View user's profile Send private message
mrbassie
Guru
Guru


Joined: 31 May 2013
Posts: 592

PostPosted: Sat Jan 04, 2020 6:08 pm    Post subject: Reply with quote

FastTurtle wrote:
So the only way to avoid the stripping is the single disk pool. Damn and the ZFS docs basically indicate the same thing. Stripping is baked so deep that you can't have multiple disks without it.


You can have multiple pools.
Back to top
View user's profile Send private message
FastTurtle
Guru
Guru


Joined: 03 Sep 2002
Posts: 431
Location: Flakey Shake & Bake Caliornia, USA

PostPosted: Sun Jan 05, 2020 3:38 am    Post subject: Reply with quote

Hu: Hadn't thought about using Device Mapper and going with a JBOD setup. From what I've read about JBOD it has the same issue as Raid 0 - Loose a drive and the entire pool is gone.

mrbassie: I was able to determine that the only way to prevent ZFS from stripping is to have single drive pools until I can get the additional drives for Raid 1 (Mirror). Did edit the comment you quoted about single drive pool to clarify it included multple single drive pools.

Another option that may be worth testing is putting a pair of 3TB drives into a Raid 1 Mirror and see what kind of speed I can get. That allows me to configure the pair of 1TB SSDs as cache drives as my current build (Ryzen 5 1600 - 1st Gen) has the full 64GB of Ram for performance. The big issue I have is the fact that my current board only has 4 sata ports, so I'm not going to be able to do much testing unless I give up my Optical Drive and since I haven't used it in over a year, it wouldn't be a great loss.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum