[Nix-dev] Handling NSS modules

Ludovic Courtès ludo at gnu.org
Mon Mar 17 15:07:50 CET 2008


Hello,

I added support for `nss-mdns' [0] to NixOS.  Since this requires
applications to be able find the various `libnss_mdns' shared objects,
my current solution is to add `nssModulesPath' to `LD_LIBRARY_PATH' in
`/etc/profile'.

However, this is not satisfying: upon `nixos-rebuild' after adding an
NSS module, `/etc/nsswitch.conf' is updated to use the new NSS module,
but running applications can't load the module because they don't have
the new updated `LD_LIBRARY_PATH', which may cause DNS lookup failure.

In contrast, on a "regular" GNU system, NSS modules are installed in
"standard locations" so that changes to `nsswitch.conf' can immediately
take effect for all running and newly-launched applications.

Any idea how to address this?

Thanks,
Ludovic.

[0] http://0pointer.de/lennart/projects/nss-mdns/




More information about the nix-dev mailing list