On Tue, Oct 20, 2015, at 14:08, Daniel Pocock wrote:
> If postinst or one of the other scripts does a service restart and the
> restart operation fails, should the postinst abort or should it mask the
> error, continue and return success?

Whatever makes more sense for that particular service, as in "safer". 
And by safer I do mean: smaller chance of aggravating already present
damage, causing security issues, or data loss".

> If it continues, is there any other convention for reporting the
> problem, e.g. stderr?

You report errors and warnings to stderr, yes.  For sysvinit there is a
shell API that can be used for that.  Systemd might have its own
convention for unit files.

A better way to get error/warning information to the user would be
welcome, but it needs to be properly planned (headless nodes, unattended
upgrades, desktops with crippled local mail delivery/routing, etc).

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique de Moraes Holschuh <h...@debian.org>

Reply via email to