1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-06-05 13:26:01 +02:00

openrc, rc-status, rc-service, rc-update: add pages (#3800)

* rc-status: add page

* openrc: add page

* rc-service: add page

* rc-update: add page

* rc-status: add list all runlevels example

* openrc: fix travis errors

* rc-status: fix travis errors again

* Update pages/linux/rc-update.md

Co-Authored-By: Zlatan Vasović <zlatanvasovic@gmail.com>

* Update pages/linux/rc-status.md

Co-Authored-By: Zlatan Vasović <zlatanvasovic@gmail.com>

Co-authored-by: Zlatan Vasović <zlatanvasovic@gmail.com>
This commit is contained in:
Starbeamrainbowlabs 2020-01-27 13:13:47 +00:00 committed by Zlatan Vasović
parent ac0e7625a2
commit a0d7c46e80
4 changed files with 97 additions and 0 deletions

13
pages/linux/openrc.md Normal file
View file

@ -0,0 +1,13 @@
# openrc
> The OpenRC service manager.
> See also `rc-status`, `rc-update`, and `rc-service`.
> More information: <https://wiki.gentoo.org/wiki/OpenRC>.
- Change to a specific runlevel:
`sudo openrc {{runlevel_name}}`
- Change to a specific runlevel, but don't stop any existing services:
`sudo openrc --no-stop {{runlevel_name}}`

32
pages/linux/rc-service.md Normal file
View file

@ -0,0 +1,32 @@
# rc-service
> Locate and run OpenRC services with arguments.
> See also `openrc`.
- Show a service's status:
`rc-service {{service_name}} status`
- Start a service:
`sudo rc-service {{service_name}} start`
- Stop a service:
`sudo rc-servie {{service_name}} stop`
- Restart a service:
`sudo rc-service {{service_name}} restart`
- Simulate running a service's custom command:
`sudo rc-service --dry-run {{service_name}} {{command_name}}`
- Actually run a service's custom command:
`sudo rc-service {{service_name}} {{command_name}}`
- Resolve the location of a service definition on disk:
`sudo rc-service --resolve {{service_name}}`

32
pages/linux/rc-status.md Normal file
View file

@ -0,0 +1,32 @@
# rc-status
> Show status info about runlevels.
> See also `openrc`.
- Show a summary of services and their status:
`rc-status`
- Include services in all runlevels in the summary:
`rc-status --all`
- List services that have crashed:
`rc-status --crashed`
- List manually started services:
`rc-status --manual`
- List supervised services:
`rc-status --supervised`
- Get the current runlevel:
`rc-status --runlevel`
- List all runlevels:
`rc-status --list`

20
pages/linux/rc-update.md Normal file
View file

@ -0,0 +1,20 @@
# rc-update
> Add and remove OpenRC services to and from runlevels.
> See also `openrc`.
- List all services and the runlevels they are added to:
`rc-update show`
- Add a service to a runlevel:
`sudo rc-update add {{service_name}} {{runlevel}}`
- Delete a service from a runlevel:
`sudo rc-update delete {{service_name}} {{runlevel}}`
- Delete a service from all runlevels:
`sudo rc-update --all delete {{service_name}}`