Dotnet SDK provided by fedora does not have same workloads as official one?

So i want to install android workload on dotnet 10 but it says it cannot be found?

dotnet workload search android

Workload ID      Description
sudo dotnet workload install android

Welcome to .NET 10.0!

SDK Version: 10.0.101

Installed an ASP.NET Core HTTPS development certificate.
To trust the certificate, run ‘dotnet dev-certs https --trust’
Learn about HTTPS: https://aka.ms/dotnet-https

Write your first app: https://aka.ms/dotnet-hello-world
Find out what’s new: https://aka.ms/dotnet-whats-new
Explore documentation: https://aka.ms/dotnet-docs
Report issues and find source on GitHub: https://github.com/dotnet/core
Use ‘dotnet --help’ to see available commands or visit: https://aka.ms/dotnet-cli

Workload installation failed: Workload ID android is not recognized.

However it seems like it work when you use the official installation scripts provided by Microsoft. I dont like it being outside of package management since i need to update manually and is there a reason why the workload dont exist in fedora official package?

Run as a normal user:

dotnet workload update
dotnet workload search
dotnet workload install android
1 Like

I have permission denied for this

dotnet workload update

Skipping NuGet package signature verification.
Updated advertising manifest microsoft.net.workloads.
Installing workload version 10.0.101.1.
Workload installation failed. Rolling back installed packs…
Workload update failed: Access to the path ‘/home/lagita/.dotnet/metadata/workloads/X64/10.0.100’ is denied.

Fix ownership/permissions and switch SELinux to permissive mode:

sudo chown -R $(id -u):$(id -g) ~/.dotnet
sudo setenforce 0

it kinda works the installation proceeds but now it output some errors that is not very descriptive

Workload installation failed: One or more errors occurred. (Downloading microsoft.netcore.app.runtime.aot.linux-x64.cross.android-arm version 9.0.11 failed) (Downloading microsoft.android.sdk.linux version 36.1.2 failed) (Downloading microsoft.netcore.app.runtime.aot.linux-x64.cross.android-x86 version 9.0.11 failed) (Downloading microsoft.netcore.app.runtime.aot.linux-x64.cross.android-x86 version 10.0.1 failed)

Apparently it stores downloads in /tmp until there’s no free space left.
Reboot or manually clear /tmp and then try this:

dotnet workload install android --temp-dir ~/.cache

ok i just specify the temp dir like this in dotnet since there is an option for it and it works thanks
dotnet workload install android --temp-dir ${HOME}/.temp

1 Like