I'm currently using the net core 3.1 and want to upgrade it to 5.0. I tried following this guide from Install the .NET SDK or the .NET Runtime on Ubuntu
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 apt-transport-https &&
sudo apt-get update &&
sudo apt-get install -y dotnet-sdk-5.0
but looks like the dotnet-sdk-5.0
is not found
E: Unable to locate package dotnet-sdk-5.0
E: Couldn't find any package by glob 'dotnet-sdk-5.0'
E: Couldn't find any package by regex 'dotnet-sdk-5.0'
A quick cache dump only returns old versions:
➜ ~ sudo apt-cache dump | grep dotnet-sdk
Package: dotnet-sdk-2.2
Package: dotnet-sdk-3.1
It works just fine for my laptop also running 20.04, but not on this desktop. Weird. Did I miss anything?
uname -m; cat /etc/apt/sources.list.d/microsoft-prod.list
return? Did you encounter any error while runningsudo apt-get update
? – Kulfy Mar 27 '21 at 15:42deb [arch=amd64] https://packages.microsoft.com/ubuntu/19.04/prod disco main # disabled on upgrade to focal`
From this I could guess that my problem was probably due to the fact that I upgraded to 20.04 from 19.04. So I manually add one for 20.04 by
– tab87vn Mar 27 '21 at 21:53sudo apt-add-repository https://packages.microsoft.com/ubuntu/20.04/prod