r/Ubuntu • • 7d ago

How to stop phasing updates?

A month ago, I made a post about having trouble upgrading some kernels on my laptop. Someone gave me the code to bypass phasing and get every upgrade as soon as it came out

Well, I don't mind having to upgrade my laptop as often as I do but I don't think it should give me a new notification about it every nth day of the week.

So how do I stop it? In specific, this was the command I used:

$ sudo apt upgrade -o apt::get::always-include-phased-updates=true

I tried putting false and 0 at the end instead of true but that didn't work.

8 Upvotes

10 comments sorted by

1

u/AdventurousItem4635 7d ago

That -o option only counts for the one command you ran it with, it doesn't get saved anywhere. So there's nothing to switch back, phasing was back to normal as soon as that upgrade finished. If you want to be sure nobody had you put it in a config file too, grep -ri phased /etc/apt/ will show it.

The notifications are a separate setting. Open Software & Updates, go to the Updates tab and change "When there are other updates" to weekly or every two weeks. Security updates have their own dropdown above it so you can leave those alone.

0

u/Simple_Enjoyer1 7d ago

Oh okay, good to know.

The grep line resulted in an "Access Denied" tho

2

u/alec_me 7d ago

I'm not sure how bypassing phasing helps with problems with updating kernels since kernel package updates aren't phased.

But anyway,

$ sudo apt upgrade -o apt::get::always-include-phased-updates=true

This command bypasses phasing by installing updates no matter what phase percentage they're at including halted phasing at 0%. Setting to false is the default which is to allow phasing.

You probably want

$ sudo apt upgrade -o apt::get::never-include-phased-updates=true

This tells apt to not upgrade a package until it's 100% phased, i.e. no longer phasing. An upgrade will still show packages as being deferred due to phasing, but only when they reach 100% phase completion will apt upgrade them. Halted phased packages at 0% will never be upgraded unless done manually.

1

u/dthrdr 7d ago

You can disable it but phasing is done for a reason. What package do you need updated that is withheld due to phasing? I mean really need not just want.

0

u/yxhuvud 7d ago edited 7d ago

Phasing is done for a reason, but I've had more failures due to interconnected libraries being phased differently than I've had just updating. I wish they were better at handling that particular issue.

0

u/Un_Ballerina_1952 7d ago

Have you tried false instead of true? 

1

u/Simple_Enjoyer1 7d ago

Yes and I wrote that in the body of the post.

1

u/Un_Ballerina_1952 7d ago

Sorry; I saw the '0' and not the "false" (Too early?  Not enough caffeine? Who knows.)

1

u/Simple_Enjoyer1 7d ago

Ah it's fine. I'll try those two again just to check

Edit: Didn't work. Terminal thinks I'm trying to upgrade like I always do.

1

u/Evening-Landscape763 7d ago

https://ubuntu.com/server/docs/explanation/software/about-apt-upgrade-and-phased-updates/#how-do-i-turn-off-phased-updates

See if /etc/apt/apt.conf.d/99-Phased-Updates exists and have contents of

Update-Manager::Always-Include-Phased-Updates true;
APT::Get::Always-Include-Phased-Updates true;

Change true to false to go to original settings