Rc-service
From GhostBSD Wiki
Welcome to Rc-service. |
OpenRC | ||
---|---|---|
Scripts | ||
/etc/rc rc - shell |
/etc/rc.devd The generic hook into OpenRC. |
/sbin/rcorder Ordering rc-scripts |
/etc/init.d Scripts to run OpenRC |
/usr/local/etc/init.d Scripts to run OpenRC |
|
/etc/rc.d Scripts automatically executed at boot and shutdown |
/usr/local/etc/rc.d Special scripts |
|
Configuration | ||
/etc/devd.conf Configuration file for devd(8) |
/etc/conf.d Initscript Configuration Files |
/etc/rc.conf.d Smaller configuration files |
/etc/defaults/rc.conf Specifies the default settings for all the available options. |
/etc/rc.conf The global OpenRC configuration file |
/etc/rc.conf.ghostbsd GhostBSD specific configurations |
Tools/Helper | ||
/usr/sbin/sysrc Safely edit system rc files |
/bin/rc-status Shows which services are running |
/sbin/rc-update Add or delete services |
/sbin/rc-service Locate and run an OpenRC service |
||
Back to the System |
Manual[edit]
NAME
rc-service – locate and run an OpenRC service with the given arguments
SYNOPSIS
rc-service [-c, --ifcrashed] service cmd [...] rc-service -d, --debug service cmd [...] rc-service -D, --nodeps service cmd [...] rc-service [-i, --ifexists] service cmd [...] rc-service [-I, --ifinactive] service cmd [...] rc-service [-N, --ifnotstarted] service cmd [...] rc-service [-s, --ifstarted] service cmd [...] rc-service [-S, --ifstopped] service cmd [...] rc-service -e, --exists service rc-service -Z, --dry-run service cmd [...] rc-service -l, --list rc-service -r, --resolve service
DESCRIPTION
Service scripts could be in different places on different systems. rc-service locates the specified service and runs it with the given arguments. If -i, --ifexists is given then rc-service returns 0 even if the service does not exist. If -I, --ifinactive or -N, --ifnotstarted is given then rc-service returns 0 if the service exists but is in the wrong state.
If given the -l, --list argument then rc-service will list all available services.
-e, --exists return 0 if it can find service, otherwise -1. -r, --resolve does the same and also prints the full path of the service to stdout.
-d, --debug sets -x when running the service script(s).
-D, --nodeps ignores dependencies when running the service.
-Z, --dry-run displays commands rather than executing them.