Perform service availability checks first for all service states

This commit makes service states return more meaningful/accurate
information by first checking if the service is available before trying
to do anything. Fixes #5464.