How to get a list of all pending security updates?
up vote
6
down vote
favorite
I need to list (not count or install) all pending security updates on an Ubuntu 14.04 system. I've read the post How to create a list of of only security updates with apt-get? and its accepted answer (apt-show-versions | grep upgradeable | grep security) does indeed give me a list.
However, that command lists 62 pending security updates. /usr/lib/update-notifier/apt-check tells me that I have 75 pending security updates, but doesn't seem to have a way to list them. How can I reconcile these two numbers? Is one of the two commands doing something other than what I want?
apt updates
add a comment |
up vote
6
down vote
favorite
I need to list (not count or install) all pending security updates on an Ubuntu 14.04 system. I've read the post How to create a list of of only security updates with apt-get? and its accepted answer (apt-show-versions | grep upgradeable | grep security) does indeed give me a list.
However, that command lists 62 pending security updates. /usr/lib/update-notifier/apt-check tells me that I have 75 pending security updates, but doesn't seem to have a way to list them. How can I reconcile these two numbers? Is one of the two commands doing something other than what I want?
apt updates
add a comment |
up vote
6
down vote
favorite
up vote
6
down vote
favorite
I need to list (not count or install) all pending security updates on an Ubuntu 14.04 system. I've read the post How to create a list of of only security updates with apt-get? and its accepted answer (apt-show-versions | grep upgradeable | grep security) does indeed give me a list.
However, that command lists 62 pending security updates. /usr/lib/update-notifier/apt-check tells me that I have 75 pending security updates, but doesn't seem to have a way to list them. How can I reconcile these two numbers? Is one of the two commands doing something other than what I want?
apt updates
I need to list (not count or install) all pending security updates on an Ubuntu 14.04 system. I've read the post How to create a list of of only security updates with apt-get? and its accepted answer (apt-show-versions | grep upgradeable | grep security) does indeed give me a list.
However, that command lists 62 pending security updates. /usr/lib/update-notifier/apt-check tells me that I have 75 pending security updates, but doesn't seem to have a way to list them. How can I reconcile these two numbers? Is one of the two commands doing something other than what I want?
apt updates
apt updates
asked May 19 '16 at 17:45
user3553031
14116
14116
add a comment |
add a comment |
3 Answers
3
active
oldest
votes
up vote
6
down vote
If you are just looking to do this quickly once, instead of creating a separate repository and scripting up some automation and all that. Great if you aren't supposed to be making changes while auditing a system or whatever.
These two commands will spit out the list. Pipe to wc -l to see how many are behind. ;-)
grep security /etc/apt/sources.list > /tmp/security.list
sudo apt-get upgrade -oDir::Etc::Sourcelist=/tmp/security.list -oDir::Etc::SourceParts=/some/valid/dir/false -s
Still valid for older distros or if you have update repos off, but security on:
sudo apt-get upgrade -s| grep ^Inst |grep Security
add a comment |
up vote
2
down vote
This worked for me:
sudo unattended-upgrade --dry-run -d 2> /dev/null | awk '/Checking/ { print $2 }'
Shows all available updates, but doesnt limit to security-updates if i'm not mistaken. Still helpful.
– delf
Aug 27 at 14:04
add a comment |
up vote
0
down vote
sudo apt list --upgradable |grep "/$(lsb_release -cs)-security"
This lists all available updates which come via the security repository.
add a comment |
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
6
down vote
If you are just looking to do this quickly once, instead of creating a separate repository and scripting up some automation and all that. Great if you aren't supposed to be making changes while auditing a system or whatever.
These two commands will spit out the list. Pipe to wc -l to see how many are behind. ;-)
grep security /etc/apt/sources.list > /tmp/security.list
sudo apt-get upgrade -oDir::Etc::Sourcelist=/tmp/security.list -oDir::Etc::SourceParts=/some/valid/dir/false -s
Still valid for older distros or if you have update repos off, but security on:
sudo apt-get upgrade -s| grep ^Inst |grep Security
add a comment |
up vote
6
down vote
If you are just looking to do this quickly once, instead of creating a separate repository and scripting up some automation and all that. Great if you aren't supposed to be making changes while auditing a system or whatever.
These two commands will spit out the list. Pipe to wc -l to see how many are behind. ;-)
grep security /etc/apt/sources.list > /tmp/security.list
sudo apt-get upgrade -oDir::Etc::Sourcelist=/tmp/security.list -oDir::Etc::SourceParts=/some/valid/dir/false -s
Still valid for older distros or if you have update repos off, but security on:
sudo apt-get upgrade -s| grep ^Inst |grep Security
add a comment |
up vote
6
down vote
up vote
6
down vote
If you are just looking to do this quickly once, instead of creating a separate repository and scripting up some automation and all that. Great if you aren't supposed to be making changes while auditing a system or whatever.
These two commands will spit out the list. Pipe to wc -l to see how many are behind. ;-)
grep security /etc/apt/sources.list > /tmp/security.list
sudo apt-get upgrade -oDir::Etc::Sourcelist=/tmp/security.list -oDir::Etc::SourceParts=/some/valid/dir/false -s
Still valid for older distros or if you have update repos off, but security on:
sudo apt-get upgrade -s| grep ^Inst |grep Security
If you are just looking to do this quickly once, instead of creating a separate repository and scripting up some automation and all that. Great if you aren't supposed to be making changes while auditing a system or whatever.
These two commands will spit out the list. Pipe to wc -l to see how many are behind. ;-)
grep security /etc/apt/sources.list > /tmp/security.list
sudo apt-get upgrade -oDir::Etc::Sourcelist=/tmp/security.list -oDir::Etc::SourceParts=/some/valid/dir/false -s
Still valid for older distros or if you have update repos off, but security on:
sudo apt-get upgrade -s| grep ^Inst |grep Security
edited Nov 20 at 9:37
Piloos
32
32
answered Nov 4 '16 at 21:10
flickerfly
4,62752043
4,62752043
add a comment |
add a comment |
up vote
2
down vote
This worked for me:
sudo unattended-upgrade --dry-run -d 2> /dev/null | awk '/Checking/ { print $2 }'
Shows all available updates, but doesnt limit to security-updates if i'm not mistaken. Still helpful.
– delf
Aug 27 at 14:04
add a comment |
up vote
2
down vote
This worked for me:
sudo unattended-upgrade --dry-run -d 2> /dev/null | awk '/Checking/ { print $2 }'
Shows all available updates, but doesnt limit to security-updates if i'm not mistaken. Still helpful.
– delf
Aug 27 at 14:04
add a comment |
up vote
2
down vote
up vote
2
down vote
This worked for me:
sudo unattended-upgrade --dry-run -d 2> /dev/null | awk '/Checking/ { print $2 }'
This worked for me:
sudo unattended-upgrade --dry-run -d 2> /dev/null | awk '/Checking/ { print $2 }'
edited Nov 3 '17 at 12:44
David Foerster
27.4k1363108
27.4k1363108
answered Nov 3 '17 at 12:23
Samuel James
1212
1212
Shows all available updates, but doesnt limit to security-updates if i'm not mistaken. Still helpful.
– delf
Aug 27 at 14:04
add a comment |
Shows all available updates, but doesnt limit to security-updates if i'm not mistaken. Still helpful.
– delf
Aug 27 at 14:04
Shows all available updates, but doesnt limit to security-updates if i'm not mistaken. Still helpful.
– delf
Aug 27 at 14:04
Shows all available updates, but doesnt limit to security-updates if i'm not mistaken. Still helpful.
– delf
Aug 27 at 14:04
add a comment |
up vote
0
down vote
sudo apt list --upgradable |grep "/$(lsb_release -cs)-security"
This lists all available updates which come via the security repository.
add a comment |
up vote
0
down vote
sudo apt list --upgradable |grep "/$(lsb_release -cs)-security"
This lists all available updates which come via the security repository.
add a comment |
up vote
0
down vote
up vote
0
down vote
sudo apt list --upgradable |grep "/$(lsb_release -cs)-security"
This lists all available updates which come via the security repository.
sudo apt list --upgradable |grep "/$(lsb_release -cs)-security"
This lists all available updates which come via the security repository.
answered Oct 30 at 12:02
zerwas
3,30311618
3,30311618
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f774805%2fhow-to-get-a-list-of-all-pending-security-updates%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown