I'm not sure I understand.
You want to run the rc scripts (the ones stored in /etc/rc.d) in parallel? That's certainly possible. The best-known and most widely deployed implementation (note: I said best-known and widely used, not most popular, not best liked!) is systemd, which is available in many Linux distributions. There is OpenRC, which I think is used by default on GhostBSD. For a while, a user here on the forum was making a big drama about wanting to use "nosh", and I've completely forgotten what the final outcome of that was.
Anyway, if you want to run the rc scripts in parallel, you have to solve the problem of how to preserve their ordering. Most rc scripts have very strict ordering requirements: They
require certain other scripts to run before them, and they
provide services to scripts that come after them. This is documented in the comments at the top of each rc script, but I'm not 100% sure that the documentation is complete and sufficient. Whatever you implement has to preserve that ordering, so if a script requires X, you need to wait with starting that script until whatever script provides X has actually finished. Total ordering of a graph is a well-known problem in computer science (I think students do it as homework in their first year), and implementing it using "wait" statements is not all that difficult.
I think your problem you mention above is that the output of the scripts is intermingled. Welcome to running parallel programs! Ultimately, the mixing of output depends on what device is used for the output (/var/log/messages via syslog, or the console, or the kernel-internal dmesg mechanism). Typically, if output is printed line-by-line, lines will be intermingled, but not broken apart. So if three services are running, all saying "hallo", "progress" and "goodbye", you might get this output:
Code:
A: Hallo
B: Hallo
B: Progress at 01:12 doing X
C: Hallo
A: Progress at 01:23 doing Y
A: Goodbye
C: Progress at 01:45 doing Z
B: Goodbye
C: Goodbye
To accomplish this, you need to audit every single rc script and every program used within the rc scripts, and make sure they always print a while line at a time, in this style: "echo A: Progress at `date` doing X", or the equivalent with a printf statement in C or the equivalent in other languages. If scripts/programs break this apart in this way:
Code:
echo -n A: Progress at ""
echo -n `date` ""
echo Doing X
Then it is possible that things get mixed up:
Code:
B: Progress at C: Progress at A: Goodbye 01:12 doing Y 01:23 doing Z
The underlying problem is the line buffering of devices and open files. If you want to do this right, you re-implement syslog to allow logging multi-line packets. For people who implement parallel systems, this is a standard problem, and typically one has a young software engineer spend a few weeks writing a logging package that does the right thing.