Open eduherminio opened 8 months ago
I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label.
I have the same error, 4 VMs stoped working all at the same time
Anyone looking for fix:
sudo apt-get install --allow-downgrades dotnet-sdk-8.0=8.0.100-1
sudo apt-get update && \
sudo apt-get install -y dotnet-sdk-8.0
sudo apt-get install -y dotnet-runtime-8.0
many thanks to @appiclogics !!
similar thing happen to me today in vultr vm, site was running fine, after a commit been pushed to the server, which then publish & restart server, it ends with error. when type dotnet --version
it only say this:
You must install or update .NET to run this application.
App: /usr/share/dotnet/sdk/8.0.200/dotnet.dll
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '8.0.2' (x64)
.NET location: /usr/share/dotnet/
No frameworks were found.
Learn more:
https://aka.ms/dotnet/app-launch-failed
To install missing framework, download:
https://aka.ms/dotnet-core-applaunch?framework=Microsoft.NETCore.App&framework_version=8.0.2&arch=x64&rid=linux-x64&os=ubuntu.22.04
Same error happened, is anyone have fixed it?
So for every one having this issue, the problem is that our VM/Machines have aspnetcore-runtime-8.0
package installed but what is needed is this dotnet-runtime-8.0
package
all you have to do is update apt and install the missing package
no need to down grade
the problem is that our VM/Machines have aspnetcore-runtime-8.0 package installed but what is needed is this dotnet-runtime-8.0 package
When the aspnetcore-runtime-8.0
package is installed, that should mean the dotnet-runtime-8.0
package gets installed as well (as a dependency), see https://learn.microsoft.com/en-us/dotnet/core/distribution-packaging.
cc @MichaelSimons
It all depends on how you installed your runtime in the first place.
in my case, after some investigation, I found out that the dotnet-runtime-8.0
package is not installed in all VMs only the aspnetcore-runtime-8.0
package is.
How it happened, I do not know and I simply do not care, I just added another line in my Python setup script and was done with it.
anyway that is much better than downgrading to 8.0.1
It all depends on how you installed your runtime in the first place.
Unless you're doing something unusual, dotnet-runtime-8.0
should auto install as a dependency of aspnetcore-runtime-8.0
.
If it doesn't, then the aspnetcore-runtime-8.0
package is not expressing this dependency.
cc @NikolaMilosavljevic - Can you take a look?
aspnetcore-runtime-8.0
package has a dependency on dotnet-runtime-8.0
package - here's the output of rpm -qpR
command:
warning: aspnetcore-runtime-8.0-8.0.2-1.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 3135ce90: NOKEY
dotnet-runtime-8.0 >= 8.0.2
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
@eduherminio @GaNacereddine can you add more specifics about VMs you're using, i.e. how do you create and set them up, etc? It would help reproduce this locally and fix the issue.
DEB packages are the same - there is a runtime dependency:
Depends: dotnet-runtime-8.0 (>= 8.0.2)
Are these VMs runing the same distro? I see that first issue was reported on Ubuntu, presumably 22.04.
@eduherminio @GaNacereddine can you add more specifics about VMs you're using, i.e. how do you create and set them up, etc? It would help reproduce this locally and fix the issue.
$ uname -srm
Linux 6.2.0-1019-azure x86_64
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 22.04.3 LTS
Release: 22.04
Codename: jammy
Created manually from Azure Portal. Setup done by running:
wget https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
sudo apt-get update && sudo apt-get install -y dotnet-sdk-8.0
Let me know if any other information could be helpful
I can repro this on WSL Jammy. Code that runs from VSCode debugger fails at the command line.
Architecture: x64
App host version: 8.0.2
.NET location: Not found
Learn more:
https://aka.ms/dotnet/app-launch-failed
Download the .NET runtime:
https://aka.ms/dotnet-core-applaunch?missing_runtime=true&arch=x64&rid=linux-x64&os=ubuntu.22.04&apphost_version=8.0.2
dotnet --list-runtimes
Microsoft.AspNetCore.App 8.0.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 8.0.2 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
dotnet --list-sdks
8.0.200 [/usr/share/dotnet/sdk]
Yesterday I turned on another machine where builds used to be working. It still worked after turning it on, but they also stopped working this morning. IMHO this behavior and issue is very concerning because it happens out of the blue, without updating neither the code or the machine.
Yesterday I turned on another machine where builds used to be working. It still worked after turning it on, but they also stopped working this morning. IMHO this behavior and issue is very concerning because it happens out of the blue, without updating neither the code or the machine.
That is very surprising. The experience suggests that something is removing dotnet-runtime
package. Is there anything related to dotnet-runtime
package in apt
and dpkg
logs?
/var/log/apt/history.log
/var/log/dpkg.log
Would it be possible to share these logs?
That is very surprising. The experience suggests that something is removing
dotnet-runtime
package. Is there anything related todotnet-runtime
package inapt
anddpkg
logs?/var/log/apt/history.log /var/log/dpkg.log
Would it be possible to share these logs?
Sure, here you are.
/usr/bin/unattended-upgrade
seems to have messed with the installation.
You can see that on 2024-02-25 00:30:48
I applied the workaround mentioned above.
I've confirmed that the packages.microsoft.com endpoint for 20.04 and 22.04 appear to be stable since the 2/13 releases.
It seems that unattended-upgrade
process is upgrading Microsoft packages with native Ubuntu packages. This won't work well, as Ubuntu packages install content to a different location. You would end-up with mismatched packages and broken .NET installation.
This issue tracks the scenarios and offers workarounds and fixes: https://github.com/dotnet/core/issues/7699
One solution is to prioritize PMC repository using APT preferences file.
For some one still facing the issue:
sudo apt remove dotnet*
sudo apt remove aspnetcore*
sudo apt remove netstandard*
sudo rm /etc/apt/sources.list.d/microsoft-prod.list
sudo apt update
sudo apt install dotnet-sdk-8.0
FYI on our plan for Ubuntu 24.04 packages
Thanks @richlander. This is for sure not an optimal solution (I'm the first one that had to jump into Microsoft feed packages because latest ones weren't available in Ubuntu archive), but it's better than the duality of packages coexisting that we have now, and that cause issues like this one.
Understood. Please file issues when you see them @eduherminio. Feel free to at-mention me. I'm not always perfect, but I do try and stay on top of my notifications and help where I can.
I had the same issue and removed every dotnet package and removed microsoft-prod.list. Now I am having package deps issue: 'dotnet-runtime-deps-8.0 : Depends: libicu but it is not installable.' Any help would be appreciated. I can't run my core API...
Distributor ID: Ubuntu
Description: Ubuntu Noble Numbat (development branch)
Release: 24.04
Codename: noble
sudo apt install dotnet-sdk-8.0
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
dotnet-runtime-deps-8.0 : Depends: libicu but it is not installable or
libicu72 but it is not installable or
libicu71 but it is not installable or
libicu70 but it is not installable or
libicu69 but it is not installable or
libicu68 but it is not installable or
libicu67 but it is not installable or
libicu66 but it is not installable or
libicu65 but it is not installable or
libicu63 but it is not installable or
libicu60 but it is not installable or
libicu57 but it is not installable or
libicu55 but it is not installable or
libicu52 but it is not installable
E: Unable to correct problems, you have held broken packages.
I just tried it on raw metal and in Docker w/o this issue.
What I see: https://gist.github.com/richlander/c35678fc5b82c194bdf29ea633b6073b
On a Jammy system, I have this. It would be good to double check that you do not (on Noble).
root@c3a484fb55e2:~# cat /etc/os-release | head -n 1
PRETTY_NAME="Ubuntu 22.04.4 LTS"
root@c3a484fb55e2:~# cat /etc/apt/sources.list.d/microsoft-prod.list
deb [arch=amd64,arm64,armhf] https://packages.microsoft.com/ubuntu/22.04/prod jammy main
Did you upgrade?
I just tried it on raw metal and in Docker w/o this issue.
What I see: https://gist.github.com/richlander/c35678fc5b82c194bdf29ea633b6073b
On a Jammy system, I have this. It would be good to double check that you do not (on Noble).
root@c3a484fb55e2:~# cat /etc/os-release | head -n 1 PRETTY_NAME="Ubuntu 22.04.4 LTS" root@c3a484fb55e2:~# cat /etc/apt/sources.list.d/microsoft-prod.list deb [arch=amd64,arm64,armhf] https://packages.microsoft.com/ubuntu/22.04/prod jammy main
Did you upgrade?
Thanks for responding. yes I did upgrade to 24.04. Do I still need the "microsoft-prod.list"?
cat /etc/os-release | head -n 1
PRETTY_NAME="Ubuntu 24.04 LTS"
cat /etc/apt/sources.list.d/microsoft-prod.list
cat: /etc/apt/sources.list.d/microsoft-prod.list: No such file or directory
I had the same issue and removed every dotnet package and removed microsoft-prod.list. Now I am having package deps issue: 'dotnet-runtime-deps-8.0 : Depends: libicu but it is not installable.' Any help would be appreciated. I can't run my core API...
Distributor ID: Ubuntu Description: Ubuntu Noble Numbat (development branch) Release: 24.04 Codename: noble
sudo apt install dotnet-sdk-8.0 Reading package lists... Done Building dependency tree... Done Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation: The following packages have unmet dependencies: dotnet-runtime-deps-8.0 : Depends: libicu but it is not installable or libicu72 but it is not installable or libicu71 but it is not installable or libicu70 but it is not installable or libicu69 but it is not installable or libicu68 but it is not installable or libicu67 but it is not installable or libicu66 but it is not installable or libicu65 but it is not installable or libicu63 but it is not installable or libicu60 but it is not installable or libicu57 but it is not installable or libicu55 but it is not installable or libicu52 but it is not installable E: Unable to correct problems, you have held broken packages.
When will the native feed for dotnet-sdk-8 support libicu74?
apt search libicu
Sorting... Done
Full Text Search... Done
icu-devtools/noble 74.2-1ubuntu3 amd64
Development utilities for International Components for Unicode
libicu-dev/noble 74.2-1ubuntu3 amd64
Development files for International Components for Unicode
libicu4j-4.4-java/noble 4.4.2.2-4 all
Library for Unicode support and internationalization
libicu4j-java/noble 73.2-1 all
Library for Unicode support and internationalization
libicu74/noble,now 74.2-1ubuntu3 amd64 [installed]
International Components for Unicode
many thanks to @appiclogics !! similar thing happen to me today in vultr vm, site was running fine, after a commit been pushed to the server, which then publish & restart server, it ends with error. when type
dotnet --version
it only say this:You must install or update .NET to run this application. App: /usr/share/dotnet/sdk/8.0.200/dotnet.dll Architecture: x64 Framework: 'Microsoft.NETCore.App', version '8.0.2' (x64) .NET location: /usr/share/dotnet/ No frameworks were found. Learn more: https://aka.ms/dotnet/app-launch-failed To install missing framework, download: https://aka.ms/dotnet-core-applaunch?framework=Microsoft.NETCore.App&framework_version=8.0.2&arch=x64&rid=linux-x64&os=ubuntu.22.04
It works, thanks :-)
For those who found the same issue, clean remove and reinstall as @appiclogics suggestion can fix the problem. Thanks @appiclogics .
BTW, this problem has just happened to me after I have Windows updated.
I use Ubuntu 22.04.3 LTS
WSL2.
I had the same issue. I use Kubuntu 24.04
I guess it's happening because of unattended upgrades.
This may help those using Ubuntu:
1) Run sudo nano /etc/apt/apt.conf.d/50unattended-upgrades
.
2) Find Unattended-Upgrade::Package-Blacklist
.
3) Insert the following after it:
"dotnet.*";
"aspnetcore.*";
This way, APT will not update dotnet without your command. However, be aware that now security patches released by the dotnet team will not be automatically installed.
This is my interpretation of this answer on this issue.
Corrected it on my servers. We'll see if it helps when 8.0.6 is released.
I ended up installing via snap. I'm on a Digital Ocean server BTW.
Facing the same issue on Fedora 39
Just had this start happening to me on Fedora 40.
Describe the bug
I had .NET SDK 8 installed in an Ubuntu Azure VM and it was building my project just fine every hour/few hours or so until earlier today,
Suddenly stopped being able to do so, stating
You must install or update .NET to run this application.
andNo frameworks were found.
No reboots or known changes happened in the VM (the builds are part of an automated process that doesn't restart automatically after VM restart) and no changes happened in the code either.Is this somehow expected?
To Reproduce
Exceptions (if any)
I don't think it matters, but the repo being built was lynx-chess/Lynx.
Further technical details
System:
Linux 6.2.0-1018-azure