Changeset View
Standalone View
rcorder.8
Show All 35 Lines | |||||
.Os | .Os | ||||
.Sh NAME | .Sh NAME | ||||
.Nm rcorder | .Nm rcorder | ||||
.Nd print a dependency ordering of interdependent files | .Nd print a dependency ordering of interdependent files | ||||
.Sh SYNOPSIS | .Sh SYNOPSIS | ||||
.Nm | .Nm | ||||
.Op Fl k Ar keep | .Op Fl k Ar keep | ||||
.Op Fl s Ar skip | .Op Fl s Ar skip | ||||
.Op Fl g | |||||
0mp: Usually, flags without arguments are listed using one Fl macro before any other flags and… | |||||
.Op Fl p | |||||
.Ar | .Ar | ||||
.Sh DESCRIPTION | .Sh DESCRIPTION | ||||
The | The | ||||
.Nm | .Nm | ||||
utility is designed to print out a dependency ordering of a set of | utility is designed to print out a dependency ordering of a set of | ||||
interdependent files. | interdependent files. | ||||
Typically it is used to find an execution | Typically it is used to find an execution | ||||
sequence for a set of shell scripts in which certain files must be | sequence for a set of shell scripts in which certain files must be | ||||
▲ Show 20 Lines • Show All 45 Lines • ▼ Show 20 Lines | |||||
.Bl -tag -width indent | .Bl -tag -width indent | ||||
.It Fl k | .It Fl k | ||||
Add the specified keyword to the | Add the specified keyword to the | ||||
.Dq "keep list" . | .Dq "keep list" . | ||||
If any | If any | ||||
.Fl k | .Fl k | ||||
option is given, only those files containing the matching keyword are listed. | option is given, only those files containing the matching keyword are listed. | ||||
.It Fl s | .It Fl s | ||||
Add the specified keyword to the | Add the specified keyword to the | ||||
Done Inline ActionsI think this reads slightly better with a comma: Generate ordering suitable for parallel startup, placing files that can be rpokala: I think this reads slightly better with a comma:
```
Generate ordering suitable for parallel… | |||||
.Dq "skip list" . | .Dq "skip list" . | ||||
Done Inline ActionsThis comment is not about the man page change, but about the actual option. This way the rc infrastructure would be able to start new script(s) as soon as a requirement is satisfied. Of course, this can be done as a future improvement. If needed. avg: This comment is not about the man page change, but about the actual option.
It's better than… | |||||
Done Inline ActionsThis interactive mode can be easily added as generate_ordering() now emits scripts exactly in the way you want them to to appear. lytboris_gmail.com: This interactive mode can be easily added as generate_ordering() now emits scripts exactly in… | |||||
If any | If any | ||||
.Fl s | .Fl s | ||||
option is given, files containing the matching keyword are not listed. | option is given, files containing the matching keyword are not listed. | ||||
.It Fl g | |||||
Done Inline ActionsIt would be great if we could keep the list sorted .It Fl g ... .It Fl k ... .It Fl p ... .It Fl s 0mp: It would be great if we could keep the list sorted
```
.It Fl g
...
.It Fl k
...
.It Fl p
...
. | |||||
Produce a GraphViz (.dot) of the complete dependency graph instead of | |||||
plaintext calling order list. | |||||
.It Fl p | |||||
Generate ordering suitable for parallel startup placing files that can be | |||||
executed in simultaneously on the same line. | |||||
bcrUnsubmitted Done Inline ActionsI think the "in" here is superfluous. bcr: I think the "in" here is superfluous. | |||||
.El | .El | ||||
.Pp | .Pp | ||||
An example block follows: | An example block follows: | ||||
.Bd -literal -offset indent | .Bd -literal -offset indent | ||||
# REQUIRE: networking syslog | # REQUIRE: networking syslog | ||||
# REQUIRE: usr | # REQUIRE: usr | ||||
# PROVIDE: dns nscd | # PROVIDE: dns nscd | ||||
.Ed | .Ed | ||||
Show All 36 Lines | |||||
.Xr rc.shutdown 8 . | .Xr rc.shutdown 8 . | ||||
.El | .El | ||||
.Sh DIAGNOSTICS | .Sh DIAGNOSTICS | ||||
The | The | ||||
.Nm | .Nm | ||||
utility may print one of the following error messages and exit with a non-zero | utility may print one of the following error messages and exit with a non-zero | ||||
status if it encounters an error while processing the file list. | status if it encounters an error while processing the file list. | ||||
.Bl -diag | .Bl -diag | ||||
.It "Requirement %s has no providers, aborting." | .It "Requirement %s in file %s has no providers." | ||||
No file has a | No file has a | ||||
.Dq Li PROVIDE | .Dq Li PROVIDE | ||||
line corresponding to a condition present in a | line corresponding to a condition present in a | ||||
.Dq Li REQUIRE | .Dq Li REQUIRE | ||||
line in another file. | line in another file. | ||||
.It "Circular dependency on provision %s, aborting." | .It "Circular dependency on provision %s in file %s." | ||||
A set of files has a circular dependency which was detected while | A set of files has a circular dependency which was detected while | ||||
processing the stated condition. | processing the stated condition. Loop visualization follows this message. | ||||
bcrUnsubmitted Done Inline ActionsA line break is needed after a sentence stop. bcr: A line break is needed after a sentence stop. | |||||
.It "Circular dependency on file %s, aborting." | .It "Circular dependency on file %s." | ||||
A set of files has a circular dependency which was detected while | A set of files has a circular dependency which was detected while | ||||
processing the stated file. | processing the stated file. | ||||
.It "%s was seen in circular dependencies for %d times." | |||||
Each node that was a part of circular dependency loops reports total number of | |||||
such encounters. Start with files having biggest counter when fighting with | |||||
bcrUnsubmitted Done Inline ActionsAnother line break is needed here. bcr: Another line break is needed here. | |||||
broken dependencies. | |||||
.Sh DIAGNOSTICS WITH GRAPHVIZ | |||||
Direct dependency is drawn with solid line, | |||||
.Dq Li BEFORE | |||||
dependency is drawn as a dashed line. | |||||
Each node of a graph represents an item from | |||||
.Dq Li PROVIDE | |||||
lines. In case there | |||||
bcrUnsubmitted Done Inline ActionsSentence stop = line break. bcr: Sentence stop = line break. | |||||
are more than one file providing an item, a list of filenames shortened with | |||||
.Xr basename 3 | |||||
is shown. Shortened filenames are also shown in case | |||||
bcrUnsubmitted Done Inline Actions... and another one here. bcr: ... and another one here. | |||||
.Dq Li PROVIDE | |||||
item does not match file name. | |||||
.Pp | |||||
Edges and nodes where circular dependencies were detected are drawn bold red. | |||||
If a file has an item in | |||||
.Dq Li REQUIRE | |||||
or in | |||||
.Dq Li BEFORE | |||||
that could not be provided, | |||||
this missing provirer and the requirement will be drawn bold red as well. | |||||
bcrUnsubmitted Done Inline Actionss/provirer/provider/ bcr: s/provirer/provider/ | |||||
.El | .El | ||||
.Sh SEE ALSO | .Sh SEE ALSO | ||||
.Xr acpiconf 8 , | .Xr acpiconf 8 , | ||||
.Xr rc 8 , | .Xr rc 8 , | ||||
Done Inline Actionss/Dq Li/Ql/ 0mp: s/Dq Li/Ql/ | |||||
.Xr rc.shutdown 8 | .Xr rc.shutdown 8 | ||||
.Sh HISTORY | .Sh HISTORY | ||||
The | The | ||||
Done Inline Actionss/Dq Li/Ql/ 0mp: s/Dq Li/Ql/ | |||||
.Nm | .Nm | ||||
utility appeared in | utility appeared in | ||||
.Nx 1.5 . | .Nx 1.5 . | ||||
.Nm | .Nm | ||||
utility first appeared in | utility first appeared in | ||||
.Fx 5.0 . | .Fx 5.0 . | ||||
.Sh AUTHORS | .Sh AUTHORS | ||||
Done Inline Actionss/Dq Li/Ql/ 0mp: s/Dq Li/Ql/ | |||||
.An -nosplit | .An -nosplit | ||||
Written by | Written by | ||||
.An Perry E. Metzger Aq Mt perry@piermont.com | .An Perry E. Metzger Aq Mt perry@piermont.com | ||||
and | and | ||||
.An Matthew R. Green Aq Mt mrg@eterna.com.au . | .An Matthew R. Green Aq Mt mrg@eterna.com.au . | ||||
Done Inline Actionss/Dq Li/Ql/ 0mp: s/Dq Li/Ql/ | |||||
.Sh BUGS | .Sh BUGS | ||||
The | The | ||||
Done Inline Actionss/Dq Li/Ql/ 0mp: s/Dq Li/Ql/ | |||||
.Dq Li REQUIRE | .Dq Li REQUIRE | ||||
keyword is misleading: | keyword is misleading: | ||||
It does not describe which daemons have to be running before a script | It does not describe which daemons have to be running before a script | ||||
will be started. | will be started. | ||||
It describes which scripts must be placed before it in | It describes which scripts must be placed before it in | ||||
the dependency ordering. | the dependency ordering. | ||||
For example, | For example, | ||||
if your script has a | if your script has a | ||||
Show All 9 Lines |
Usually, flags without arguments are listed using one Fl macro before any other flags and arguments: