Re: Linux messages full of `random: get_random_u32 called from`

From: Christian Brauner
Date: Thu Apr 26 2018 - 16:47:57 EST


On Thu, Apr 26, 2018 at 01:22:02PM -0700, Sultan Alsawaf wrote:
> > Hmm, it looks like the multiuser startup is getting blocked on snapd:
> >
> > 29.060s snapd.service
> >
> > graphical.target @1min 32.145s
> > ââmulti-user.target @1min 32.145s
> > ââhddtemp.service @6.512s +28ms
> > âânetwork-online.target @6.508s
> > ââNetworkManager-wait-online.service @2.428s +4.079s
> > ââNetworkManager.service @2.016s +404ms
> > ââdbus.service @1.869s
> > ââbasic.target @1.824s
> > ââsockets.target @1.824s
> > ââsnapd.socket @1.821s +1ms
> > ââsysinit.target @1.812s
> > ââapparmor.service @587ms +1.224s
> > ââlocal-fs.target @585ms
> > ââlocal-fs-pre.target @585ms
> > ââkeyboard-setup.service @235ms +346ms
> > ââsystemd-journald.socket @226ms
> > ââsystem.slice @225ms
> > ââ-.slice @220ms
> >
> > This appears to be some kind of new package management system for
> > Ubuntu:
> >
> > Description-en: Tool to interact with Ubuntu Core Snappy.
> > Install, configure, refresh and remove snap packages. Snaps are
> > 'universal' packages that work across many different Linux systems,
> > enabling secure distribution of the latest apps and utilities for
> > cloud, servers, desktops and the internet of things.
> >
> > Why it the Ubuntu package believes it needs to be fully started before
> > the login screen can display is unclear to me. It might be worth
> > using systemctl to disable snapd.serivce and see if that makes things
> > work better for you.
> >
> > - Ted
>
> I removed snapd completely which did nothing.
>
> Here are new logs:
> systemd-analyze blame: https://hastebin.com/edehikuyeb.css
> systemd-analyze critical-chain: https://hastebin.com/vedufafema.pl
> dmesg: https://hastebin.com/zuwuwoxadu.vbs
>
> I should also note that leaving the system untouched does not result in it booting: I must
> provide a source of entropy, otherwise it just stays stuck. In both of the dmesgs I've given, I

We have observed a similiar problem with libvirt. As soon as entropy is
provided the boot finishes otherwise it hangs for a long time.
This is not happening with v4.17-rc1 afaict.

Christian

> manually provided entropy to the system after about 5 minutes of waiting.
>
> Also, regardless of what's hanging on CRNG init, CRNG should be able to init on its own in a timely
> manner without the need for user-provided entropy. Userspace was working fine before the recent CRNG
> kernel changes, so I don't think this is a userspace bug.
>
> -Sultan
>