Man page - apt-get-noninteractive(8)
Packages contains this manual
- unicode-show(1)
- str_replace(1)
- apparmor-info(8)
- stdisplay(1)
- limit-medium(1)
- upgrade-nonroot(8)
- limit-low(1)
- ld-system-preload-disable(8)
- apparmor-watch(8)
- leaktest(8)
- dpkg-noninteractive(8)
- anon-consensus-del(8)
- pwchange(8)
- chmod-calc(1)
- lsmod-deterministic(8)
- dummy-dependency(8)
- apt-get-noninteractive(8)
apt-get install helper-scripts
Manual
APT-GET-NONINTERACTIVE
NAMESYNOPSIS
Description
Examples
Why is âapt-get-noninteractiveâ not using the âapt-getâ option â--yesâ?
Why does âapt-get-noninteractiveâ prevent daemon restarts during upgrade?
WWW
AUTHOR
NAME
apt-get-noninteractive - wrapper to run apt-get non-interactively
SYNOPSIS
apt-get-noninteractive [option]s
Description
Simple wrapper that
|
⢠|
sets environment variables for non-interactive use, |
||
|
⢠|
prevents daemons from restarting during upgrades, |
||
|
⢠|
forces new package configuration files installation without user prompts. (Through option -o Dpkg::Options::=--force-confask,confnew,confnew ) |
then forwards all arguments to apt-get .
Does not pass by default:
|
⢠|
--allow-downgrades |
|||
|
⢠|
--allow-remove-essential |
|||
|
⢠|
--allow-change-held-packages |
If you like to keep old configuration files, add the following parameter.
-o Dpkg::Options::=--force-confold
Examples
sudo apt-get-noninteractive dist-upgrade
sudo apt-get-noninteractive -o Dpkg::Options::=--force-confold install dist-upgrade
sudo apt-get-noninteractive install lxqt
sudo apt-get-noninteractive install package-name
sudo apt-get-noninteractive --allow-downgrades --allow-change-held-packages install package-name
Why is âapt-get-noninteractiveâ not using the âapt-getâ option â--yesâ?
Using APT (the package manager) in automatic, non-interactive mode is tricky. Itâs not as simple as just adding --yes to make everything work smoothly.
Some people might think that apt-get-noninteractive should automatically include --yes because of the name, but it doesnât, and for good reason.
The proper way to use apt-get-noninteractive is to:
|
1. |
Run it without --yes . |
||
|
2. |
Check the output to see if something dangerous might happen (like removing a critical package). |
||
|
3. |
If everything looks fine, press Enter to continue. |
If you are already confident about the outcome, you can run it again with --yes to skip confirmation.
If --yes were included by default, users would have to:
|
1. |
Run plain apt-get to preview what would happen. |
|||
|
2. |
Cancel it with Ctrl+C. |
|||
|
3. |
Then run apt-get-noninteractive to actually apply the changes. |
Advanced notes:
|
⢠|
APT non-interactive mode requires setting many options and environment variables; no one wants to do that manually. |
||
|
⢠|
Itâs unclear if apt-get-noninteractive behaves differently from apt-get because of the extra options it passes. |
||
|
⢠|
This design is intentional and opinionated, aiming for both safety and usability. |
Why does âapt-get-noninteractiveâ prevent daemon restarts during upgrade?
Because daemon restarts can cause APT upgrade failures and apt-get-noninteractive is designed as a tool to easily fix broken APT.
WWW
https://www.kicksecure.com/wiki/Operating_System_Software_and_Updates#Broken_APT
AUTHOR
This man page has been written by Patrick Schleizer (adrelanos@whonix.org).