Fix crash when restarting crashed background services

Since the commmit 5fa518a1 "Move SMTP credentials into new file owned by
root", background service restarting has been broken.  Specifically, if a
background service crashed, or was restarted manually, the whole service
manager background service would crash instead.

Extend the existing /services page test (009-services.py) to actually
check that services are running correctly, and that they (and the whole
service manager) can be restarted via the /restartservice operation.