The Cookie Machine - Click here to drag window

DUMMY TEXT - Real text set in assets/js/theCookieMachine.js

Views: 101     Votes:  1     ✅ Solution
Tags: command-line   apt   scripts  
Link: 🔍 See Original Answer on Ask Ubuntu 🔗

Title: Suspend temporarily linux update apt for the session until reboot
ID: /2019/10/02/Suspend-temporarily-linux-update-apt-for-the-session-until-reboot
Created: October 2, 2019
Upload: November 24, 2022    Layout:  post
TOC: false    Navigation:  false    Copy to clipboard:  false

You can run a command based on this answer:

Create a script:


systemctl stop apt-daily.service
systemctl kill --kill-who=all apt-daily.service

# wait until `apt-get updated` has been killed
while ! (systemctl list-units --all apt-daily.service | egrep -q '(dead|failed)')
  sleep 1;

# now proceed
echo Apt Daily Service has been killed

Mark the script as executable in order to call the command:

sudo chmod /path/to/

You need sudo powers to call the command:

sudo /path/to/

When you are away from the hotspot and back to your regular network reboot to reinstate apt services or type:

sudo systemctl start apt-daily.service

Of course you can forgo the fancy script altogether and stop services with:

sudo systemctl stop apt-daily.service
⇧ Disabling external monitor with xrandr also disables laptop screen How to set intel_idle.max_cstate=1  ⇩