Boot screen with DietPi and Odroid C4

Hello,

I have managed to get my Odroid running with DietPi to get into chromium kiosk mode and works very well so far.

My question is how to suppress the entire boot and console messages until chrome is up and maybe show a splash or boot screen. All the hints I found so far may fit for Raspberry Pi but Odroid seems to be special?

Maybe someone here can point me into the right direction.

Cheers,

Sven

Have got some progress.

  1. Add quiet splash plymouth.ignore-serial-consoles to the extraargs entry in /boot/dietpiEnv.txt
  2. Install plymouth and plymouth-themes: G_AGI plymouth plymouth-themes
  3. Active new theme: plymouth-set-default-theme -R spinner

Show up a spinner on start and shutdown - nice.

But I still see some console output.
Where the whole bunch of text is output I see after log in (i.e. Version, Device model, etc.) ?

Regards, Sven

You mean dietpi-banner?

Sounds like dietpi-banner, yes.

See also the docs: Miscellaneous Tools - DietPi.com Docs

you can try to deselect all options to reduce the output

Ok, now I have a very cool state. But it was a lot of work todo to get there. Maybe some of you can give hints to do it better in some ways.

Here is what I got so far (mostly done as root):

  1. Add quiet splash plymouth.ignore-serial-consoles loglevel=3 vt.global_cursor_default=0 to the extraargs entry in /boot/dietpiEnv.txt. Effect: No blinking cursor, no kernel messages on boot screen
  2. Install chromium and set it to auto boot via dietpi-config
  3. Enable ssh, you will need it for later login
  4. Disable getty service: systemctl mask getty@tty1.service
  5. Disable console output in /etc/systemd/system/dietpi-postboot.service: Comment out following line: StandardOutput=tty
  6. Put dietpi user into tty and video group: usermod -aG video tty dietpi
  7. Add a new udev rule for having relaxed permissions on /dev/tty devices:
echo -e "KERNEL==\"tty[0-9]*\", MODE=\"0660\"\n" > /etc/udev/rules.d/99-my-tty.rules
udevadm control --reload-rules
udevadm trigger
  1. Added a service for starting X and chromium
nano /etc/systemd/system/chromium-kiosk.service

And enter following text:

[Unit]
Description=Chromium Kiosk Mode
After=network.target

[Service]
ExecStart=/var/lib/dietpi/dietpi-software/installed/chromium-autostart.sh
TTYPath=/dev/tty1
Restart=always
User=dietpi

[Install]
WantedBy=graphical.target

and than enable service

systemctl enable chromium-kiosk.service
  1. Finally reboot

Effect: Clean boot with spinner animation without any console output and direct start into chromium.

2 Likes

The DietPi login banner can be btw also muted like this:

touch ~/.hushlogin

The dietpi-postboot.service should not show any output if an autostart option with autologin (like Chromium kiosk mode) is selected. Also the user selected with dietpi-aurostart should get the needed permissions, like video group.

Hi,

thanks, that helped to remove the banner, ok. But still shows “Debian GNU/Linux 12 DietPi tty1” and login stuff on autologin.

Not true, at least on my side. Just tested it again - fresh install, installed chromium and selected autostart (option 11). Get a whole bunch of output before seeing X.

There is two native Debian messages, which can be removed as well:

  • rm /etc/issue for the message shown before/with login prompt
  • rm /etc/motd for the message shown after login

Which output do you see exactly from dietpi-postboot?

Helped further reducing it. Now I only see DietPi login: dietpi (automatic login)

And than I see the output from X Server startup:

Ah right, with your service you see the X startup logs in journalctl instead.

Actually not a bad idea to start Chromium directly without any login session. But I am no fans of masking the login prompt entirely, as this makes fixing things more complicated if anything happens.

For hiding even the last bit login messages (the prompt entirely), the service could switch to e.g. tty3 via chvt 3 and back again on stop or failure. We do it like this for the Amiberry fastboot option. Also I am no fans of Restart=always without stricter limits. There is always a reason for a failure, which usually requires some adjustment, otherwise you just run into a restart loop.

I remember such was asked for before, hence thinking about a way to implement this without the risk of locking users out and keeping a sane way for debugging, if needed.

No, there is some misunderstanding, cross posting, sorry. I want to clarify:

  • my approach with a dedicated service works as intended with plymouth animation, than a black screen without messages, login prompt or cursor and direct starting into X - sure the plymouth screen could be shown until X but that is another story. Downside is the effort to get there and issues you mentioned
  • second approach - and this is the screenshot from my last post - is to stay with automatic login and automatic starting x and to limit the console outputs but I do not get it as quiet as with my first approach.

If there were a solution with dietpi out of the box any updates may be easier to install. Thats the advantage of second approach.

I have got it working without service and active getty as well. Found some hints here: https://wiki.archlinux.org/title/Silent_boot

  1. Silence getty: nano /etc/systemd/system/getty@tty1.service.d/dietpi-autologin.conf and add the command line parameter –skip-login
  2. Redirect startx output to /dev/null: nano /var/lib/dietpi/dietpi-software/installed/chromium-autostart.sh and add >/dev/null 2>&1 to the last line (exec “$STARTX” …)

Cheers, Sven

1 Like