Robert Milkowski wrote:
Robert Milkowski wrote:
Hi,
When deploying ZFS in cluster environment it would be nice to be able
to have some SSDs as local drives (not on SAN) and when pool switches
over to the other node zfs would pick up the node's local disk drives
as L2ARC.
To better clarify what I mean lets assume there is a 2-node cluster
with 1sx 2540 disk array.
Now lets put 4x SSDs in each node (as internal/local drives). Now
lets assume one zfs pool would be created on top of a lun exported
from 2540. Now 4x local SSDs could be added as L2ARC but because they
are not visible on a 2nd node when cluster does failover it should be
able to pick up the ssd's which are local to the other node.
L2ARC doesn't contain any data which is critical to pool so it
doesn't have to be shared between node. SLOG would be a whole
different story and generally it wouldn't be possible. But L2ARC
should be.
Perhaps a scenario like below should be allowed:
node-1# zpool add mysql cache node-1-ssd1 node-1-ssd2 node1-ssd3
node-1-ssd4
node-1# zpool export mysql
node-2# zpool import mysql
node-2# zpool add mysql cache node-2-ssd1 node-2-ssd2 node2-ssd3
node-2-ssd4
This is assuming that pool can be imported when some of its slog
devices are not accessible.
That way the pool always would have some L2ARC/SSDs not accessible but
would provide L2ARC cache on each node with local SSDs.
btw:
mi...@r600:/rpool/tmp# mkfile 200m f1
mi...@r600:/rpool/tmp# mkfile 100m s1
mi...@r600:/rpool/tmp# zpool create test /rpool/tmp/f1
mi...@r600:/rpool/tmp# zpool status test
pool: test
state: ONLINE
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
test ONLINE 0 0 0
/rpool/tmp/f1 ONLINE 0 0 0
errors: No known data errors
mi...@r600:/rpool/tmp# zpool add test cache /rpool/tmp/s1
cannot add to 'test': cache device must be a disk or disk slice
mi...@r600:/rpool/tmp#
is there a reason why a cache device can't be set-up on a file like
for other vdevs?
mi...@r600:/rpool/tmp# zfs create -V 100m rpool/tmp/ssd1
mi...@r600:/rpool/tmp# zpool add test cache /dev/zvol/rdsk/rpool/tmp/ssd1
cannot use '/dev/zvol/rdsk/rpool/tmp/ssd1': must be a block device or
regular file
mi...@r600:/rpool/tmp# zpool add test cache /dev/zvol/dsk/rpool/tmp/ssd1
mi...@r600:/rpool/tmp#
So when I try to add a cache device on-top of a file I get an error that
a cache device must be a disk or a disk slice, so when I try to add a
cache device on a rdsk I get an error that it bust be a block device or
regular file which suggest a regular file should work... (dsk works fine).
--
Robert Milkowski
http://milek.blogspot.com
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss