View Single Post
Posts: 1,808 | Thanked: 4,272 times | Joined on Feb 2011 @ Germany
#98
@Mentalist Traceur and @Pali and @others,

Perhaps a simple solution would be to store a config file in / or /etc (/preinit.cfg or so) where one could set the option of FBCON (FBCON=early, FBCON=normal, FBCON=no) plus another option for EARLY_CONSOLE=(yes,no,ask) [ "ask" would enable @Mentalist Traceur's timed selection).

Another option would be "BOOTMENU", either empty or pointing to a file (/bootmenu.sh), so that preinit would only check that option and if non-empty and file exists and file is executable (so that it's easily disabled) then it would run it.

This way preinit (stock or Pali's) would only need a few extra lines but the added functionallity would be implemented elsewhere (and easily enabled/disabled).

As long as the new preinit throughly checks things one could almost guarantee that there would be no reboot loops (at least caused by preinit).

For the long term I would go for a full runlevel implementation, so that you can have your single-user, multi-user-no-X, multi-user-networking, etc.

BTW /sbin/init is an ELF binary. Is the source code available?
 

The Following User Says Thank You to reinob For This Useful Post: