Like as dotnet/dotnet-docker#1537
but I have same error on CenOS 8 (not Docker) on standalone machine.
Clean new CentOS 8 with latest updates on 23 dec 2020.
in console:
sudo dnf install aspnetcore-runtime-3.1
– OK
dotnet
– OK (shows using manual)
dotnet --info
– error:
A fatal error occurred, the folder [/usr/share/dotnet/host/fxr] does not contain any version-numbered child folders
dotnet --list-runtimes
– error:
A fatal error occurred, the folder [/usr/share/dotnet/host/fxr] does not contain any version-numbered child folders
dotnet *.dll
– error:
A fatal error occurred, the folder [/usr/share/dotnet/host/fxr] does not contain any version-numbered child folders
the folder /usr/share/dotnet/host/fxr
is really empty. Trying to install SDK – no effect
2
Answers
I had the same problem after updating my system to Fedora 32. The problem was, that I had installed dotnet-runtime-2.1 before, but Fedora 32 comes with 3.1 included.
If your dotnet application is compatible with 3.1, you can simply uninstall the old runtime. That’s how I did it:
In my case, version 2.1 was installed by myself. 3.1 was installed by the system (tagged with fc32)
dotnet --info
should work again.For more information or if your application requires dotnet 2.1:
https://github.com/dotnet/core/issues/4655
If the dotnet sdk is version 5.0
step 1.- Remove sdk
step 2.- remove folders
step 4.- Clean and upgrade.
step 5.- Reboot system
step 6.- Finally