I have a script that I symlink in as /etc/rc.d/rc3.d/S30initialize which basically makes it get called when entering runlevel 3. I want for the output of this script to appear on the virtual terminal. For example on the default display of the screen. So what I do inside this script is wrap everything inside (  set -e  set -x  .... install some stuff, etc) 2>&1 | tee -a /etc/init.log > /dev/tty1So this works fine but what happens is that the stream of output makes it to the screen just fine (at the end of the bootup kernel messages) but then the tty login prompt comes up and covers it up about a second later.At the end of the script execution I can often spot logged into /etc/init.log this:tee: write errorSooooo my question is, is there some way that I can temporarily or permanently disable the tty login prompt on tty1? I'm quite happy to use Ctrl+Alt+F2 to log in to the machine if I need to.I have also tried changing it to not use a pipe, like this: ) 2>&1 | tee -a /etc/init.log /dev/tty1 but this suffers from the same problem (it just no longer seems to produce a tee: write error error).I'm mostly interested in tweaking this behavior on Centos 7. Incidentally when i try to do similar things on my Raspberry Pi I did use a slightly different method of running things at startup: there I added commands to rc.local, and everything makes its way to the main terminal screen without a problem. So maybe I can try that, or there is maybe another way -- maybe I can put in a long pause to wait for the login prompt to show up before I run the subshell which is being directed to /dev/tty1. This way instead of the login prompt stomping on the output stream it will be my script stomping on the output stream.
send bootup script output to virtual terminal
linux;terminal;login