Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

haveged fails to start (systemd)

Featured Replies

root@odroidn2:~# journalctl -x | grep haveged
Mar 12 19:43:51 odroidn2 kernel: audit: type=1400 audit(1615574627.248:2): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/usr/sbin/haveged" pid=1635 comm="apparmor_parser"
Mar 12 19:43:47 odroidn2 audit[1635]: AVC apparmor="STATUS" operation="profile_load" profile="unconfined" name="/usr/sbin/haveged" pid=1635 comm="apparmor_parser"
-- Subject: A start job for unit haveged.service has finished successfully
-- A start job for unit haveged.service has finished successfully.
Mar 12 19:43:52 odroidn2 haveged[1836]: haveged: Couldn't initialize HAVEGE rng 9
Mar 12 19:43:52 odroidn2 haveged[1836]: haveged starting up
Mar 12 19:43:52 odroidn2 systemd[1]: haveged.service: Main process exited, code=exited, status=1/FAILURE
-- An ExecStart= process belonging to unit haveged.service has exited.
Mar 12 19:43:52 odroidn2 systemd[1]: haveged.service: Failed with result 'exit-code'.
-- The unit haveged.service has entered the 'failed' state with result 'exit-code'.
 

I don't have a N2 or an HC4 handy, but these two links appear interesting ...

 

https://isolated.site/2019/07/08/debian-10-hangs-during-booting-on-phicomm-n1/

https://lists.opensuse.org/opensuse-bugs/2019-03/msg00250.html

 

Both have the same error code, and apparently the same solution. Notably, the phicomm N1 is also an Amlogic S905 ...

 

Any chance setting this in your /etc/default/haveged fixes it?

 

DAEMON_ARGS="-w 1024 -d16"

 

Apparently haveged is supposed to auto-detect CPU settings, but apparently doesn't always work, and the fallback doesn't either.

I try that on my Helios4 with Armbian 21.08.0-trunk Hirsute.

Service can't start

Jun 15 20:58:54 helios4 kernel: audit: type=1326 audit(1623790734.437:21): auid=4294967295 uid=0 gid=0 ses=4294967295 subj==unconfined pid=2134 comm="haveged" exe="/usr/sbin/haveged" sig=31 arch=40000028 syscall=122 compat=0 ip=0xb6f9cb68 code=0x80000000

but I can be started from command line, with default options:

# haveged --Foreground --verbose=1
haveged: command socket is listening at fd 3
haveged starting up
haveged: ver: 1.9.8; arch: generic; vend: ; build: (gcc 10.2.1 CTV); collect: 128K
haveged: cpu: (VC); data: 16K (D); inst: 16K (D); idx: 12/40; sz: 15006/57790
haveged: tot tests(BA8): A:1/1 B:1/1 continuous tests(B):  last entropy estimate 7.99541
haveged: fills: 0, generated: 0

 

Edited by iav
fix board name

On 3/17/2021 at 12:46 PM, tparys said:
DAEMON_ARGS="-w 1024 -d16"

 

Works for me (Odroid N2+). Thanks!

This is actually is/was a bug in haveged, or the Debian build itself: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=985196

Strangely we only observed this on armv7l/armhf systems, not aarch64/arm64. However a cleaner solution is to apply the following to the systemd unit:

mkdir -p /etc/systemd/system/haveged.service.d
echo -e '[Service]\nSystemCallFilter=uname' > /etc/systemd/system/haveged.service.d/syscall.conf


But actually, the hardware random generator should work well, making haveged obsolete?
 

apt install rng-tools5 # modern
apt purge rng-tools # legacy
apt purge rng-tools-debian # legacy Debian port
apt purge haveged

 

Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.