Use the following procedure to disable a service. The service status change is recorded in the service configuration repository. Once the service is disabled, the disabled state will persist across reboots. The only way to get the service running again is to enable it.
Become superuser or assume a role that includes the Service Management rights profile.
Roles contain authorizations and privileged commands. For more information about roles, see Configuring RBAC in System Administration Guide: Security Services.
Check the dependents of the service you want to disable.
If this service has dependents that you need, then you cannot disable this service.
# svcs -D FMRI |
Disable the service.
# svcadm disable FMRI |
The output from the first command shows that the rlogin service has no dependents. The second command in this example disables the rlogin service. The third command shows that the state of the rlogin service instance is disabled.
# svcs -D network/login:rlogin # svcadm disable network/login:rlogin STATE STIME FMRI # svcs network/login:rlogin STATE STIME FMRI disabled 11:17:24 svc:/network/login:rlogin |