Score:0

How to downgrade package to the version form previous release of Ubuntu?

ng flag

I've stuck with a specific issue in Mozc package on the latest Ubuntu 21.04, that is of 2.26.4220.100 version. So I figured out I can solve it by downgrading Mozc package to the 2.23.2815.102 version that was working great on 20.04LTS Ubuntu. Still, when I try to get list of available versions enter image description here

it shows the only 2.26.4220.100 version available.

But if we look at the complete list, we can see there are lots of older versions available from previous versions of Ubuntu: enter image description here

So for some reason my apt just doesn't see repositories for other Ubuntu releases. And my question is how to make it do so, so I could just sudo apt install «pkg»=«version»?

David avatar
cn flag
for some reason my apt just doesn't see repositories for other Ubuntu releases That is correct it shows the version that is for the version of Ubuntu you are using. Nothing wrong with apt.
username avatar
ng flag
@David thank you for your answer! So, how to make it do so if I need it?
pLumo avatar
in flag
If you check the list of dependencies, you will see that issues following a downgrade are likely.
username avatar
ng flag
@pLumo thank you for your advice! Still, I'd like to give it a try, with upgrade it back being always an option. So, how to downgrade it to the version from 20.04 repository?
raj avatar
cn flag
raj
I would download manually the old version of the package, install it using `dpkg`, and then pin the version in Synaptic to prevent upgrades.
username avatar
ng flag
@raj thank you for your advice! Yes, I was considering this way as well. Still, at the 'Download' section of https://packages.ubuntu.com/en/source/focal/mozc I can see only .tag.xz archives and not proper .deb packages. Is it possible to install them some way, or am I just looking in the wrong place?
raj avatar
cn flag
raj
You are looking in **source** repository - you won't find installable binary packages there. Try here: https://packages.ubuntu.com/en/focal/allpackages - search (Ctrl+F) for "mozc". It is possible that you will have to downgrade more than one package.
username avatar
ng flag
@raj ouch, you're right. I'm still new to the packages site. Thank you for advising! Yup, that did the trick, I very properly managed to downgrade target packages and everything works great now. Thank you! Regarding prevention from automatic upgrade, I'm using apt instead of Synaptic, so I guess I should just `sudo apt-mark hold` all the packages that I downgraded, right?
raj avatar
cn flag
raj
From the description it looks that it should do the same, however I never used this, I always did it via Synaptic. When I run `sudo apt-mark showhold` it doesn't show me the package that I have pinned in Synaptic, so probably the mechanism is different, but the result may be the same :)
Score:1
cn flag
raj

The easiest method would be probably to manually download the .deb file using the "focal" link shown on your screenshot, then install it using sudo dpkg -i ibus-mozc_2.23.2815.102+dfsg-8ubuntu1_amd64.deb (because of dependencies, you will probably also need to downgrade mozc-server and mozc-utils-gui - if installed), and then prevent the packages from further upgrades using either sudo apt-mark hold ibus-mozc (and the same for other downgraded packages), or "Lock version" option in Synaptic Package Manager.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.