Failed to issue method call: Unit .service failed to load – RHEL7 Linux error

Symptom

When trying to start a service with service or systemctl commands on the Redhat 7 Linux system the following error message can appear on the screen:

Failed to issue method call: Unit service_name.service failed to load: No such file or directory.

Solution

This error message is shown when you are trying to start or enable service which is either not installed on your Linux system or your have entered an incorrect service name. To fix this problem make sure that the service you are trying to run is installed and that you are referring to it with a correct service name. To do this simply list all available services on your Redhat 7 system using below command and find the service you are trying to run. The service name does not always corresponds to a package name thus it may confuse you.

[root@rhel7 ~]# systemctl list-units --type=service

The list of the services can be quite long thus piping the output to a grep command to search a particular keyword can be also handy eg:

[root@rhel7 ~]# systemctl list-units --type=service | grep at\..*service

list services at example rhel7