svc.8 (2181B)
1 .Dd April 17, 2023 2 .Dt SVC 8 SMM 3 .Os Galeb 2.2 4 .Sh NAME 5 .Nm svc 6 .Nd manage services 7 .Sh SYNOPSIS 8 .Nm 9 .Op Fl acdeklrs | ad 10 .Op Ar service 11 .Sh DESCRIPTION 12 Most of the options accept either the service name or, if omitted, apply the 13 operation to all the related services. 14 . 15 .Bl -tag -width ".Nm Fl a" -offset indent 16 . 17 .It Nm Fl a 18 lists all activated services in 19 .Pa /bin/svc.d/run . 20 . 21 .It Nm Fl a Op Ar service 22 activates the service 23 .Dq Ar service . 24 . 25 .It Nm Fl ad Op Ar service 26 checks if the service 27 .Dq Ar service 28 is activated in the directory 29 .Pa /bin/svc.d/run . 30 . 31 .It Nm Fl c 32 configures 33 .Nm 34 by creating the necessary subdirectories of 35 .Pa /bin/svc.d . 36 . 37 .It Nm Fl d Op Ar service 38 deactivates the service 39 .Dq Ar service . 40 . 41 .It Nm Fl e Op Ar service 42 checks if the service 43 .Dq Ar service 44 is running 45 .Pq Dq exists . 46 . 47 .It Nm Fl k 48 stops 49 .Pq Dq kills 50 all active services. 51 . 52 .It Nm Fl k Op Ar service 53 stops the service 54 .Dq Ar service . 55 . 56 .It Nm Fl l 57 lists all available (not necessarily activated) services in the directory 58 .Pa /bin/svc.d/avail . 59 . 60 .It Nm Fl r 61 restarts all active services. 62 . 63 .It Nm Fl r Op Ar service 64 restarts the service 65 .Dq Ar service . 66 . 67 .It Nm Fl s 68 starts all active services. 69 . 70 .It Nm Fl s Op Ar service 71 starts the service 72 .Dq Ar service . 73 .El 74 .Sh FILES 75 .Bl -tag -width ".Pa /bin/svc.d/avail" 76 .It Pa /bin/svc.d/avail 77 service scripts which are available for activation. 78 .It Pa /bin/svc.d/default 79 service configuration files. 80 .It Pa /bin/svc.d/run 81 symlinks to activated service scripts. 82 .El 83 .Sh EXIT STATUS 84 .Nm , 85 .Xr service 8 86 and service scripts themselves should set the exit status to one of the 87 following: 88 .Bl -tag -offset indent -width 6n 89 .It 0 90 success. 91 . 92 .It 1 93 redundancy; for example, if starting the service was attempted when the service 94 is already running. 95 . 96 .It 2 97 general error. 98 .El 99 .Sh SEE ALSO 100 .Xr service 8 101 .Sh HISTORY 102 .Nm 103 and related commands were made by Cristoph Lohmann in 2012. 104 The version used in Galeb is heavily modified and documented by Strahinya Radich 105 in 2022. 106 .Sh AUTHORS 107 .An "Cristoph Lohmann" Aq 20h@r-36.net , 108 2012-2014, original author 109 .An "Strahinya Radich" Aq contact@strahinja.org , 110 2022, reorganized 111 .Nm 112 and created the manpage.