[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Netlink configuration and predefined export names



Ping?


-------- Oorspronkelijk bericht --------
Onderwerp: Netlink configuration and predefined export names
Van: Wouter Verhelst
Aan: jbacik@fb.com
Cc: nbd@other.debian.org


Hi Josef,

I've been looking at merging your patches to nbd-client so that I can
use netlink rather than ioctl() in nbd-client. However, I've run into a
bit of a snag.

In order to properly support systemd, I updated nbd-client a while back
so that you could add a configuration file (${SYSCONFDIR}/nbdtab by
default), configure NBD devices there by device name, and then run
"nbd-client nbd0". That way, and with a bit of systemd glue, you can now
say "systemctl start nbd@nbd0", and things will just work.

With the netlink interface, however, you can't force a particular device
minor number to be used. That's a good thing (I'm not suggesting we
bring it back), but it does mean that managing such devices through
systemd isn't possible with the current setup.

How hard would it be to modify the netlink interface to add a device
name? That way, I can tell users to use a symbolic name in nbdtab (e.g.,
by doing something like "nbd-client -L home"), which would then create a
device name symlink '/dev/nbd/home' or some such, rather than /dev/nbdX.
The systemd tooling can then be modified so that it uses the
/dev/nbd/ name rather than /dev/nbdX. If userspace doesn't provide
such a name, it could default to the same nbdX name.

Thanks,

--
Could you people please use IRC like normal people?!?

-- Amaya Rodrigo Sastre, trying to quiet down the buzz in the DebConf 2008
Hacklab



Reply to: