Ronald Kuehn writes:
> On Sunday, August 26, 2007 at 16:36:26 CEST, Rainer J.H. Brandt wrote:
> 
> > Ronald Kuehn writes:
> > > No. You can neither access ZFS nor UFS in that way. Only one
> > > host can mount the file system at the same time (read/write or
> > > read-only doesn't matter here).
> > 
> > I can see why you wouldn't recommend trying this with UFS
> > (only one host knows which data has been committed to the disk),
> > but is it really impossible?
> > 
> > I don't see why multiple UFS mounts wouldn't work, if only one
> > of them has write access.  Can you elaborate?
> 
> Hi,
> 
> UFS wasn't designed as a shared file system. The kernel
> always assumes it is the only party accessing or modifying
> any on-disk data structures. With that premise it uses caching
> quite heavily. The view of the file system (cached structures + on-disk
> state) is consistent. The on-disk state alone isn't while the
> file system is mounted. Any other system accessing the on-disk
> state w/o taking into consideration the data cached on the original
> host will probably see inconsistencies. This will lead to data corruption
> and panics. If only one system mounts the file system read/write
> and other hosts only mount it read-only the read-only hosts will
> get an inconsistent view of the file system because they don't know
> what's in the cache of the r/w host.
> 
> These approaches exist to solve this problem:
> - Only allow one host to directly access the file system. Other
>   systems access it by talking over the network to this host:
>   + NFS
>   + the pxfs layer of Sun Cluster (global file system)
> - Use a file system designed with some kind of co-ordination for parallel
>   access to the on-disk data structures built in:
>   + QFS (Shared mode uses a meta data server on one host to
>     manage the right to access certain parts of the on-disk structures.
>     The operation on the data itself then takes place over the storage
>     path. In that case multiple systems can modify on-disk structures
>     directly. They only need to ask the meta data server for permission.)
> 
> I hope that helps,
> Ronald

Yes, thank you for confirming what I said.

So it is possible, but not recommended, because I must take care
not to read from files for which buffers haven't been flushed yet.

Rainer Brandt
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to