[systemd-devel] remote-fs ordering, iSCSI and _netdev

Karel Zak kzak at redhat.com
Fri Oct 31 01:32:57 PDT 2014


On Thu, Oct 30, 2014 at 03:04:59PM -0700, Chris Leech wrote:
> On Thu, Oct 30, 2014 at 12:10:16PM +0100, Karel Zak wrote:
> > On Tue, Oct 28, 2014 at 02:29:35AM +0100, Lennart Poettering wrote:
> > > On Mon, 27.10.14 14:10, Chris Leech (cleech at redhat.com) wrote:
> > > 
> > > > So for any mounts to remote block devices (unlike remote file system
> > > > protocols which are detected by the fs name), unless there is an fstab
> > > > entry at the time fstab-generator is run they get treated like local fs
> > > > mounts and connectivity to the storage target may be disrupted before
> > > > unmounting (possibly resulting in file system errors).
> > > > 
> > > > I'm currently at a loss for how to handle this, other than to claim that
> > > > if filesystems are going to be left mounted they should be added to
> > > > fstab and a daemon-reload is required.
> > > 
> > > IIRC mount nowadays stores the full mount option string, including all
> > > the "userspace-only" options in /run. We could either read those
> > > directly from there in systemd, or we could make systemd make use of
> > > libmount to get that information.
> >  
> > _netdev is information about device rather than about filesystem.
> > Would be possible to have this info ("this is iSCSI") in udev db? 
> 
> Yes, the _netdev option is ugly.  For iSCSI specifically, we'd have to
> trace the block device back to the scsi_host, then match that up with an
> iscsi_host from the transport class.  Or come up with some change to
> make that process easier.  And it would need to work for dm/md device
> over the actually scsi device.

 It would be really better to have within systemd a generic function
 is_net_blkdev() than rely on external fragile configuration. I have
 doubts that anyone uses -o _netdev on command line when manually
 mounts filesystem.
  
 Not sure, maybe it's possible to detect this by scsi info in /sys.

    Karel


-- 
 Karel Zak  <kzak at redhat.com>
 http://karelzak.blogspot.com


More information about the systemd-devel mailing list