debian: stop ceph-mds before uninstalling ceph-mds

Fixes: #4384
Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 9eb0d91b867ab980135d7c6ff6347d69d0a8a794)
debian: only start/stop upstart jobs if upstart is present

This avoids errors on non-upstart distros (like wheezy).

Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 030bf8aaa15837f898e453161eeaf1d52fc5779d)

Conflicts:
	debian/ceph-mds.postinst