Hi again maintainer,

I've attached a patch that adds a systemd unit file in the hopes that
it's helpful. It's working nicely on our ~100 systems running jessie.

I've also put a diff of the unscd package which also packages the newest
upstream (#795618) and adds a manpage (#789871) in addition to adding
the unit file here just in case that's helpful:
https://gist.github.com/chriskuehl/028df2a1b6ee183d104d

Obviously feel free to ignore my patches, just including in case they
are helpful.

Thanks!
Chris

On Sat, Aug 15, 2015 at 02:19:03PM -0700, Chris Kuehl wrote:
> Package: unscd
> Version: 0.51-1+b2
> Severity: wishlist
> 
> Howdy maintainer,
> 
> It would be convenient to provide a systemd unit file; this would make
> it a little easier to manage and check the status of the running daemon,
> and would allow it to be restarted automatically by systemd if it were
> to crash.
> 
> Many thanks for your work!
> Chris
> 
> 
> -- System Information:
> Debian Release: 8.1
>   APT prefers stable-updates
>   APT policy: (500, 'stable-updates'), (500, 'stable')
> Architecture: amd64 (x86_64)
> 
> Kernel: Linux 3.16.0-4-amd64 (SMP w/8 CPU cores)
> Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
> Shell: /bin/sh linked to /bin/dash
> Init: systemd (via /run/systemd/system)
> 
> Versions of packages unscd depends on:
> ii  libc6  2.19-18
> 
> unscd recommends no packages.
> 
> unscd suggests no packages.
> 
> -- Configuration Files:
> /etc/nscd.conf changed:
> debug-level 0
> enable-cache passwd yes
> positive-time-to-live passwd 3600
> negative-time-to-live passwd 20
> check-files passwd yes
> enable-cache group yes
> positive-time-to-live group 3600
> negative-time-to-live group 60
> check-files group yes
> enable-cache hosts yes
> positive-time-to-live hosts 30
> negative-time-to-live hosts 30
> check-files hosts yes
> 
> 
> -- no debconf information
--- unscd-0.51/debian/control	2013-10-21 15:41:49.000000000 -0700
+++ unscd-0.52/debian/control	2015-08-15 14:02:26.000000000 -0700
@@ -1,8 +1,8 @@
 Source: unscd
 Section: admin
 Priority: extra
 Standards-Version: 3.9.3
-Build-Depends: debhelper (>= 9), groff-base
+Build-Depends: debhelper (>= 9), groff-base, dh-systemd
 Maintainer: Don Armstrong <d...@debian.org>
 Vcs-Browser: http://git.donarmstrong.com/unscd.git
 Vcs-Git: git://git.donarmstrong.com/unscd.git
diff -Nru unscd-0.51/debian/help2man unscd-0.52/debian/help2man
diff -Nru unscd-0.51/debian/rules unscd-0.52/debian/rules
--- unscd-0.51/debian/rules	2013-10-21 17:05:19.000000000 -0700
+++ unscd-0.52/debian/rules	2015-08-15 14:13:30.000000000 -0700
@@ -1,7 +1,7 @@
 #!/usr/bin/make -f
 
 %:
-	dh $@
+	dh $@ --with systemd
 
 override_dh_auto_clean:
 	rm -f nscd
diff -Nru unscd-0.51/debian/service unscd-0.52/debian/service
--- unscd-0.51/debian/service	1969-12-31 16:00:00.000000000 -0800
+++ unscd-0.52/debian/service	2015-08-15 14:12:34.000000000 -0700
@@ -0,0 +1,10 @@
+[Unit]
+Description=Name Service Cache Daemon
+
+[Service]
+User=root
+ExecStart=/usr/sbin/nscd -d
+Restart=always
+
+[Install]
+WantedBy=multi-user.target

Reply via email to