Microsoft Repository throwing error when updating and upgrading

Questions about applications and software
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
swagatopablo
Level 1
Level 1
Posts: 40
Joined: Thu Sep 20, 2012 1:19 pm

Microsoft Repository throwing error when updating and upgrading

Post by swagatopablo »

I just installed azure cli 2.0.81 to provision virtual machines and manage them via the bash. These are the instructions I used.
https://docs.microsoft.com/en-us/cli/az ... pivots=apt

But since then, my attempt to upgrade is hitting this error.

Code: Select all

The repository 'https://packages.microsoft.com/repos/azure-cli ulyana Release' does not have a Release file
How to solve this?
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
sleeper12
Level 21
Level 21
Posts: 14559
Joined: Thu May 25, 2017 3:22 pm

Re: Microsoft Repository throwing error when updating and upgrading

Post by sleeper12 »

Looks like you missed the warning on the install page:

"Warning

Ubuntu 20.04 (Focal Fossa) and 20.10 (Groovy Gorilla) include an azure-cli package with version 2.0.81 provided by the universe repository. This package is outdated and not recommended. If this package is installed, remove the package before continuing by running the command sudo apt remove azure-cli -y && sudo apt autoremove -y.

The azure-cli deb package does not support ARM64 architecture."
swagatopablo
Level 1
Level 1
Posts: 40
Joined: Thu Sep 20, 2012 1:19 pm

Re: Microsoft Repository throwing error when updating and upgrading

Post by swagatopablo »

Thanks a lot for getting back. I did install with the Option 2, not from universe, but even after purging azure-cli now, it seems my whole Mint installation is broken and cannot even update. Any clue how to salvage the situation and get a functioning mint/ubuntu installation back (without the nuclear option of total reformatting) even if I do without azure-cli for now? This is my error upon update attempt

Code: Select all

E: The repository 'https://packages.microsoft.com/repos/azure-cli ulyana Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://repo.skype.com/deb stable InRelease: The following signatures were invalid: EXPKEYSIG 1F3045A5DF7587C3 Skype Linux Client Repository <se-um@microsoft.com>
Last edited by swagatopablo on Mon Sep 20, 2021 10:54 pm, edited 1 time in total.
sleeper12
Level 21
Level 21
Posts: 14559
Joined: Thu May 25, 2017 3:22 pm

Re: Microsoft Repository throwing error when updating and upgrading

Post by sleeper12 »

Try this for the Skype error:

Code: Select all

 curl https://repo.skype.com/data/SKYPE-GPG-KEY | sudo apt-key add - 
Did you remove azure-cli per the instructions in the Warning message? Maybe then you can install it with Option 1.
swagatopablo
Level 1
Level 1
Posts: 40
Joined: Thu Sep 20, 2012 1:19 pm

Re: Microsoft Repository throwing error when updating and upgrading

Post by swagatopablo »

Thanks for helping me fix the skype error, and yes, I removed azure-cli using the exact command mentioned there. The current problem is not with azure-cli but the microsoft repository. Here is the console output.

Code: Select all

root@clevo-workstation:~# apt-get update
Hit:1 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/amd64  InRelease
Get:2 https://nvidia.github.io/nvidia-container-runtime/stable/ubuntu18.04/amd64  InRelease [1,481 B]      
Hit:3 https://nvidia.github.io/nvidia-docker/ubuntu18.04/amd64  InRelease                                                     
Hit:4 http://dl.google.com/linux/chrome/deb stable InRelease                                                                  
Hit:5 https://repo.skype.com/deb stable InRelease                                                                             
Ign:6 https://packages.microsoft.com/repos/azure-cli ulyana InRelease                                                         
Hit:7 http://archive.ubuntu.com/ubuntu focal InRelease                                                                        
Hit:8 https://packages.microsoft.com/ubuntu/20.04/prod focal InRelease                                                        
Hit:9 https://packages.microsoft.com/repos/ms-teams stable InRelease                                                          
Get:10 https://desktop-download.mendeley.com/download/apt stable InRelease [2,456 B]                                          
Err:11 https://packages.microsoft.com/repos/azure-cli ulyana Release                                                          
  404  Not Found [IP: 40.65.182.21 443]
Hit:12 https://download.docker.com/linux/ubuntu bionic InRelease                                                              
Ign:13 http://packages.linuxmint.com ulyana InRelease                                                                         
Get:14 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]                                                      
Ign:15 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64  InRelease                                  
Hit:16 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64  Release                                    
Hit:17 http://ppa.launchpad.net/remmina-ppa-team/remmina-next/ubuntu focal InRelease                                          
Hit:18 http://archive.canonical.com/ubuntu focal InRelease                                                                    
Get:19 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]                                                    
Hit:20 http://packages.linuxmint.com ulyana Release                                                                           
Get:23 http://archive.ubuntu.com/ubuntu focal-backports InRelease [101 kB]                                                    
Hit:22 https://packagecloud.io/AtomEditor/atom/any any InRelease      
Reading package lists... Done
E: The repository 'https://packages.microsoft.com/repos/azure-cli ulyana Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
sleeper12
Level 21
Level 21
Posts: 14559
Joined: Thu May 25, 2017 3:22 pm

Re: Microsoft Repository throwing error when updating and upgrading

Post by sleeper12 »

See if you can disable/remove that microsoft repo in Software Sources, PPA's or Additional Repositories.
User avatar
karlchen
Level 23
Level 23
Posts: 18211
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Microsoft Repository throwing error when updating and upgrading

Post by karlchen »

Hi, folks.

The repository 'https://packages.microsoft.com/repos/azure-cli ulyana Release' does not have a Release file
Has it occurred to anybody that the Mint nickname 'ulyana' may be meaningless to Microsoft repos? If anything then they will know 'focal'.
https://packages.microsoft.com/repos/azure-cli focal
Fix the file content of /etc/apt/sources.list.d/azure-cli.list accordingly.

Regards,
Karl
Image
The people of Alderaan have been bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine for 771 days now.
Lifeline
swagatopablo
Level 1
Level 1
Posts: 40
Joined: Thu Sep 20, 2012 1:19 pm

Re: Microsoft Repository throwing error when updating and upgrading

Post by swagatopablo »

karlchen wrote: Tue Sep 21, 2021 11:41 am
Thanks for the simple solution. Somehow I used to think Mint and Ubuntu are same under the Cinnamon GUI layer. But clearly I was wrong.
So does it mean when I add any repository or install an application, the Ubuntu specific instructions will not apply for my Mint box? But most applications cover only Ubuntu, Debian, Fedora and Arch users among the major distributions. Almost nobody gives explicit instructions for Mint. Is this an issue?

Also, out of curiosity, I use Elementary OS in another box I have. Is that (or other distros) likely to hit the same wall when updating some packages?
User avatar
karlchen
Level 23
Level 23
Posts: 18211
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Microsoft Repository throwing error when updating and upgrading

Post by karlchen »

Hello, swagotopablo.

Basically, the Ubuntu instructions will apply for Mint, too.
In the given instruction, which you followed, https://docs.microsoft.com/en-us/cli/az ... pivots=apt, the problemtic command is this one:
Add the Azure CLI software repository:

Code: Select all

AZ_REPO=$(lsb_release -cs)
echo "deb [arch=amd64] https://packages.microsoft.com/repos/azure-cli/ $AZ_REPO main" |  sudo tee /etc/apt/sources.list.d/azure-cli.list
To be precise, it is the first command: AZ_REPO=$(lsb_release -cs), because lsb_release -cs returns your Mint nickname ulyana, though actually you need the Ubuntu nickname focal.

This incorrect nickname ulyana is then put into the sources list file /etc/apt/sources.list.d/azure-cli.list. And there we have our problem.

The solution is simple:
Either change AZ_REPO=$(lsb_release -cs) to be AZ_REPO=focal and carry on with the next command.
Or execute both commands as given in the instruction. But then manually correct the file /etc/apt/sources.list.d/azure-cli.list and replace ulyana by focal, before proceeding with the linked instruction.

Note:
Almost nobody gives explicit instructions for Mint. Is this an issue?
Yes, indeed it is. The same issue will be found in many third party instructions on how to add their repo to your sources list files. The commands are tested against Ubuntu, where they work without issues. But no-one takes into consideration that there are distros like Mint, which are based on Ubuntu, where the lsb_release command may return the wrong nickname.

Regards,
Karl
Image
The people of Alderaan have been bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine for 771 days now.
Lifeline
Locked

Return to “Software & Applications”