Created
September 15, 2014 14:43
-
-
Save truetone/14aed57c869d83df5037 to your computer and use it in GitHub Desktop.
Handy Linux (Ubuntu) Commands
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Show security updates only: | |
apt-get -s dist-upgrade |grep "^Inst" |grep -i securi | |
# Show all upgradeable packages | |
apt-get -s dist-upgrade | grep "^Inst" | |
# Install security updates only | |
apt-get -s dist-upgrade | grep "^Inst" | grep -i securi | awk -F " " {'print $2'} | xargs apt-get install | |
# Check what services need to be restarted after package upgrades. | |
# Figure out what packages you are going to upgrade beforehand and schedule your restarts/reboots. | |
# The problem here is that unless you restart a service it still may be using an older version of | |
# a library (most common reason) that's been loaded into memory before you installed new package | |
# which fixes a security vulnerability or whatever. | |
checkrestart -v |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment