View previous topic :: View next topic |
Author |
Message |
chrisk2305 Tux's lil' helper
Joined: 05 Sep 2007 Posts: 110
|
Posted: Sun Apr 05, 2020 3:44 pm Post subject: System stuck during boot for ~5 minutes hanging at random |
|
|
Hi,
My system is stuck during boot for quite some time due to random fast init and random crng init hanging:
Code: | 3.104177] clocksource: Switched to clocksource tsc
[ 54.950502] random: fast init done
[ 149.704022] random: crng init done
[ 423.106828] smartpqi 0000:0c:00.0: |
I searched the forums and already emerged:
Code: |
USE=+jitterentropy emerge sys-apps/rng-tools
emerge haveged
|
And enabled both services but that did not do the trick (I guess because they are userspace tools and my issues happens at the very beginning of booting).
Kernel version I am using is 5.4.3
Any help is much appreciated!
Chris |
|
Back to top |
|
|
fedeliallalinea Administrator
Joined: 08 Mar 2003 Posts: 31455 Location: here
|
Posted: Sun Apr 05, 2020 4:06 pm Post subject: |
|
|
You tried also some of others proposed by toralf (I use haveged)? _________________ Questions are guaranteed in life; Answers aren't. |
|
Back to top |
|
|
mike155 Advocate
Joined: 17 Sep 2010 Posts: 4438 Location: Frankfurt, Germany
|
Posted: Sun Apr 05, 2020 4:37 pm Post subject: |
|
|
Please install haveged AND enable it. |
|
Back to top |
|
|
chrisk2305 Tux's lil' helper
Joined: 05 Sep 2007 Posts: 110
|
Posted: Mon Apr 06, 2020 5:06 am Post subject: |
|
|
Hi,
please see my inital post. I installed and enabled haveged. Did not do the trick. |
|
Back to top |
|
|
mike155 Advocate
Joined: 17 Sep 2010 Posts: 4438 Location: Frankfurt, Germany
|
Posted: Mon Apr 06, 2020 12:36 pm Post subject: |
|
|
Quote: | I installed and enabled haveged. Did not do the trick. |
Sorry! I have overlooked that.
- Please upgrade to the latest kernel of the 5.4. series (5.4.30) and retry.
- Please post the output of
Please post the output of 'dmesg' directly after booting
Please post your kernel config using wgetpaste. |
|
Back to top |
|
|
chrisk2305 Tux's lil' helper
Joined: 05 Sep 2007 Posts: 110
|
|
Back to top |
|
|
mike155 Advocate
Joined: 17 Sep 2010 Posts: 4438 Location: Frankfurt, Germany
|
Posted: Mon Apr 06, 2020 3:54 pm Post subject: |
|
|
dmesg shows 2 issues, which are most probably independent of one another:
- it takes 150 seconds to initialize the random number generator:
Code: | [ 149.762497] random: crng init done |
it takes 430 seconds to initialize the Adaptec SmartRAID driver:
Code: | [ 434.259870] smartpqi 0000:0c:00.0: Online Firmware Activation enabled |
The second issue is the one that hurts you. Let's try to solve that first. |
|
Back to top |
|
|
chrisk2305 Tux's lil' helper
Joined: 05 Sep 2007 Posts: 110
|
Posted: Mon Apr 06, 2020 4:24 pm Post subject: |
|
|
hmm....you are probably right. At first I thought that the Adaptec HBA is the issue but concentrated on random (which also takes far too long )
In the meanwhile I updated the HBA's firmware to the latest one but that did not change anything in boot behaviour. Not sure what else I can try. |
|
Back to top |
|
|
mike155 Advocate
Joined: 17 Sep 2010 Posts: 4438 Location: Frankfurt, Germany
|
Posted: Mon Apr 06, 2020 4:29 pm Post subject: |
|
|
Some of your kernel option look suspicious. AMD ACPI2Platform is disabled, NUMA is disabled, IOMMU is disabled, etc.
Please read https://wiki.gentoo.org/wiki/Ryzen and adjust your kernel settings. It might also be necessary to increase CONFIG_NR_CPUS to 32.
EDIT (not related to your boot issues): don't use -O3 in your CFLAGS! -O3 is known to break several packages and it's not recommended.
Last edited by mike155 on Mon Apr 06, 2020 4:36 pm; edited 1 time in total |
|
Back to top |
|
|
chrisk2305 Tux's lil' helper
Joined: 05 Sep 2007 Posts: 110
|
Posted: Mon Apr 06, 2020 4:34 pm Post subject: |
|
|
are these options also necessary as this is a virtual machine? The Adaptec HBA is passed through to the VM as additional info. |
|
Back to top |
|
|
mike155 Advocate
Joined: 17 Sep 2010 Posts: 4438 Location: Frankfurt, Germany
|
Posted: Mon Apr 06, 2020 4:52 pm Post subject: |
|
|
You're talking about a virtual machine? Really?
Your output of dmesg doesn't look like a virtual machine! 16 CPUs, multiple ethernet adapters, many scsi devices, ... What are you doing?
I'm afraid I can't help you. |
|
Back to top |
|
|
chrisk2305 Tux's lil' helper
Joined: 05 Sep 2007 Posts: 110
|
Posted: Mon Apr 06, 2020 5:23 pm Post subject: |
|
|
Yes I am.
This is quite a special setup. I have multiple VMs runnig on that host ( 16C/32T Epyc2 CPU, 128GB RAM). I am passing through 2 NVMe disks and the Adaptec HBA - no more specialties than that.
Neither of that can explain my issues. |
|
Back to top |
|
|
toralf Developer
Joined: 01 Feb 2004 Posts: 3942 Location: Hamburg
|
Posted: Mon Apr 06, 2020 7:06 pm Post subject: |
|
|
chrisk2305 wrote: | are these options also necessary as this is a virtual machine? | Gha,
and didn't you set CONFIG_HW_RANDOM_VIRTIO to be passed to the virtual machine to avoid hangs of virtual machines during boot ??? |
|
Back to top |
|
|
chrisk2305 Tux's lil' helper
Joined: 05 Sep 2007 Posts: 110
|
Posted: Tue Apr 07, 2020 5:55 am Post subject: |
|
|
@toralf: The Hypervisor used here is esxi 6.7. As far as I know VMWare does not pass through a hardware number generator. |
|
Back to top |
|
|
toralf Developer
Joined: 01 Feb 2004 Posts: 3942 Location: Hamburg
|
Posted: Tue Apr 07, 2020 7:17 am Post subject: |
|
|
chrisk2305 wrote: | @toralf: The Hypervisor used here is esxi 6.7. As far as I know VMWare does not pass through a hardware number generator. | Understood - you should take a look at the LKML archive. The problem with hanging virtual machines due to the rng not being initialized was a hot topic a time ago - I'm pretty sure you'll find the answer there. |
|
Back to top |
|
|
chrisk2305 Tux's lil' helper
Joined: 05 Sep 2007 Posts: 110
|
Posted: Wed Apr 08, 2020 7:31 am Post subject: |
|
|
All the threads I find on the internet suggest to install haveged and/ or rng-tools. I also tried "Trust CPU for rng" Kernel option but the issue persists. I am stuck here. |
|
Back to top |
|
|
|