-
Notifications
You must be signed in to change notification settings - Fork 4.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.NET runtime not found on Ubuntu #79237
Comments
Tagging subscribers to this area: @vitek-karas, @agocke, @VSadov Issue DetailsDescriptionMy weekly GitHub actions build started failing. Docker:
Actions error:
Full error: https://github.com/ptr727/PlexCleaner/actions/runs/3622494725/jobs/6107272543 Reproduction StepsInstall .NET 6 on ubuntu:latest. Expected behaviorWork as before. Actual behavior
Regression?Yes, this worked in previous ubuntu:latest release, no code changes, github actions build just started failing. Known WorkaroundsNo response Configurationhttps://github.com/ptr727/PlexCleaner/actions/runs/3616398576 Other informationNo response
|
Side note: Is there some reason you're doing this yourself, instead of using one of the pre-built .net images? |
Pre-built images did not exist when I started my project circa .NET Core 3 (at least I don't think they existed?). As for this issue, I found several other reports of the .11 .NET build that is included in Ubuntu being broken, and to switch to installing hardcoded .8 builds. As for me, I just reverted to installing using PMC and not relying on Ubuntu native support.
|
This combo looks suspicious:
The default dotnet install location on Linux is You can change this by putting a different path in |
As far as I can tell this is likely due to wrong installation. The fact that
If the installation of the runtime is supposed to be global, then it needs to be registered in If the installation is supposed to be only for running the app and not global to the machine, then it needs to set If you want to be 100% about this, you can set The key question is - how did you install the SDK/runtime? |
Using |
3.1 images exist, although I'm not sure when they were first created. |
|
@markhiveit thanks - |
The odd thing was that it was working up until very recently with Anyway, sounds like my config was wrong in the first place and needed correcting. |
Confirmed: the default dotnet install location is Not sure who owns creating deb packages. @jkoritzinsky would you happen to know? |
I experienced the same issue on ubuntu 22.04 going from 6.0.9 to 6.0.11. Resolved it by doing |
@MichaelSimons do you know who the contact would be for the Ubuntu packages? |
@mirespace, is the primary dev of the source-built .NET packages in the Ubuntu feed. @mirespace, can you help out with this issue? TIA |
Hi all, Thanks a lot Michael for the mention! We detected that DOTNET_ROOT was not properly updated when upgrading from previous versions to latest 6.0.111 (we did a change in the install layout as some of you could notice), affecting only to amd64 architectures: https://bugs.launchpad.net/ubuntu/+source/dotnet6/+bug/1997746 We were monitoring any possible issues related to this, but we didn't get any on Launchpad so we couldn't estimate if this was causing a real impact or not. @ptr727 or anyone else affected, whenever you face an issue with the package, feel free to file a issue about dotnet package in ubuntu at https://bugs.launchpad.net/ubuntu/+source/dotnet6/+filebug ... thankyou!. I'll track this to the above bug already opened. Anyway, happy to help here, of course! The fix is prepared for next version .112 next week, sorry for the inconvenience. The issue arises in the file
There are a couple of workarounds in the meantime (I already saw some of you applying it, thanks!):
We didn't notice the missing location files! Thanks @agocke for the reporting here and @Daan4 for the workaround. I already filed a bug for that: https://bugs.launchpad.net/ubuntu/+source/dotnet6/+bug/1999266 I'll update this issue when the fix would be released. Thanks in advance for your patience. |
@mirespace Just to give a little more context where this matters: If you use The scenario that's broken is what we call the "apphost" scenario, where a native exe is bundled with the user application. In that case the apphost needs to launch the runtime, but doesn't necessarily know where to look. The behavior is defined as either
The fixes for this would generally be to either use the default install location, or place the install_location file in the expected /etc/dotnet location. No real preference on either choice. |
.NET 6.0.11 calls from built sites is not working without this dotnet/runtime#79237 (comment)
I would say we prefer to always write the The design docs for this area are here: Ideally the installer would also write the |
Hi! To clarify, both fixes will be introduced in the next version:
|
FWIW, was having this issue on a freshly spun up arm64 (NOT amd64) VPS instance, and before I found this issue, I tried rebooting the VPS, after which it worked fine. Investigating further, I found /etc/dotnet to be empty but DOTNET_ROOT set to the correct value of /usr/lib/dotnet, no idea if it was set before the reboot as this is my first time using .NET and didn't know about it before hand. No idea what happened after the reboot. |
Environment variables usually require session refresh (the common case being |
FYI: I'm using zsh instead of bash, and as a result I don't know what that answer is. TBH I only learned today that zsh doesn't read Realizing now how much hander the generic problem of "we need to modify your shell environment on installation" is than I knew, I won't feel bad if the decision here is "you're on your own if you don't use the default shell". That said, I think zsh and fish are pretty popular these days. I think zsh is even the default on macOS so lots more people are aware of it. |
The proper way is for the package installer to update Setting |
Hi all! Happy New year btw. (OFYI) Sorry for the delay in commenting here: the fixes were released this week with version 6.0.113 (maybe some of you noticed them also in the 112 version that was in proposed pocket in December). I hope this help, and please, let me know if something else needs to be changed for you. @masto Thanks for bringing up the zsh user experience.... would you mind submitting a bug at https://bugs.launchpad.net/ubuntu/+source/dotnet6/+filebug ? I will mark it as Wishlist at first, but it will help us to be aware of it. We will work on it as soon as possible when time and resources allow. |
Thanks for the update, @mirespace! I'm going to close this issue since the fix has been released. |
Description
My weekly GitHub actions build started failing.
I suspect some change in Ubuntu .NET 6 results in the apps no longer running, and complaining no runtime found.
Docker:
Actions error:
Full error: https://github.com/ptr727/PlexCleaner/actions/runs/3622494725/jobs/6107272543
Reproduction Steps
Install .NET 6 on ubuntu:latest.
Compile .NET core app in github actions step, copy .NET app to docker
ditnet --info
works.Run .NET app, complains no .NET found?
Expected behavior
Work as before.
Actual behavior
.NET location: Not found
Regression?
Yes, this worked in previous ubuntu:latest release, no code changes, github actions build just started failing.
Known Workarounds
No response
Configuration
https://github.com/ptr727/PlexCleaner/actions/runs/3616398576
Other information
No response
The text was updated successfully, but these errors were encountered: