Bug 1973646 - what is replacement for virtio_rng in rhel8
Summary: what is replacement for virtio_rng in rhel8
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: rng-tools
Version: 8.3
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: beta
: ---
Assignee: Vladis Dronov
QA Contact: Vilém Maršík
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-06-18 11:47 UTC by Marian Jankular
Modified: 2023-08-08 02:59 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-06-28 17:07:05 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Comment 1 Vladis Dronov 2021-06-22 09:43:04 UTC
hello, Marian,

apologies, i'm not sure why do you suggest that virtio_rng should be replaced in the rhel8.
it works on my rhel8 kvm vm quite well:

# uname -r
4.18.0-305.el8.x86_64

# ls -la /dev/hwrng
crw------- 1 root root 10, 183 Jun 22 11:30 /dev/hwrng

# cat /sys/devices/virtual/misc/hw_random/dev 
10:183

# cat /sys/devices/virtual/misc/hw_random/rng_available
virtio_rng.0 

probably this device has to be added to the vm itself in its config. i'm using standard
qemu + libvirtd + virt-manager on my laptop and it is done in vm details -> Add Hardware.
i'm not sure about other platforms.

as for rng-tools - yes, with the introduction of jitter-rng in the kernel as of v5.4-rc1
by 50ee7529ec45 ("random: try to actively add entropy rather than passively wait for it")
we generally have enough entropy in all cases (except when some application requires massive
amounts of entropy) and do not need rngd to run in userspace anymore. thus Fedora and RHEL
have removed rng-tools from the installed-by-default standard and minimal package sets (but
rng-tools surely can be installed if necessary).

Comment 2 Vladis Dronov 2021-06-22 10:08:04 UTC
> where does the rrand cpu feature come into play? Noticed the following in dmesg;

as for this, this was added in the RHEL8.3 (since kernel-4.18.0-201.el8) and RHEL8.2.z
per bz1830280 and bz1928027.

please, note, CONFIG_RANDOM_TRUST_CPU enabled by the patch in these bzs just enables
trusting CPU (namely, its RDRAND command on x86_64) as a source of randomness by default.
the setting random.trust_cpu={on,off} itself was available since the upstream v4.19-rc3.

Comment 3 Vladis Dronov 2021-06-28 17:07:05 UTC
no update for a week, closing.


Note You need to log in before you can comment on or make changes to this bug.