Guest User

Untitled

a guest
Jul 19th, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.40 KB | None | 0 0
  1. less /var/log/apt/history.log
  2.  
  3. zless /var/log/apt/history.log.1.gz
  4.  
  5. ls -la /var/log/apt/
  6.  
  7. kreso@h17:~$ apt-history install
  8. 2013-08-06 14:42:36 install gir1.2-nautilus-3.0:amd64 <none> 1:3.8.2-0ubuntu1~ubuntu13.04.1
  9. 2013-08-06 14:42:36 install python-nautilus:amd64 <none> 1.1-3ubuntu1
  10. 2013-08-06 14:42:37 install insync-nautilus:all <none> 1.0.20
  11. 2013-08-07 14:41:37 install powertop:amd64 <none> 2.1-0ubuntu1
  12. 2013-08-07 18:44:10 install libdiscid0:amd64 <none> 0.2.2-3build1
  13. 2013-08-07 18:44:11 install sound-juicer:amd64 <none> 3.5.0-0ubuntu1
  14.  
  15. grep " install " /var/log/dpkg.log
  16.  
  17. comm -23 <(grep "apt-get install" /var/log/apt/history.log | sed 's/.* //' | sort)
  18. <(grep "apt-get remove" /var/log/apt/history.log | sed 's/.* //' | sort)
  19.  
  20. _P=mutter &&
  21. (cat /var/log/dpkg.log{,.1};zcat /var/log/dpkg.log.*.gz) |
  22. egrep --text "^[^ ]* [^ ]* (configure|install|remove|status [^ ]*|trigproc|upgrade) $_P[: ]" |
  23. sort --reverse | less
  24.  
  25. 2016-12-20 09:47:35 status unpacked mutter:amd64 3.22.2-2ubuntu1~ubuntu16.10.1
  26. 2016-12-20 09:47:35 status installed mutter:amd64 3.22.2-2ubuntu1~ubuntu16.10.1
  27.  
  28. package='skypeforlinux'; pregex="(${package}[^)]+))"; while read -r line; do [[ "$line" =~ ^Start-Date:[[:space:]]([[:digit:]].+) ]] && curdate="${BASH_REMATCH[1]} "; [[ "$line" =~ $pregex ]] && echo "$curdate ${BASH_REMATCH[1]}"; done < <(for i in `ls -tr /var/log/apt/history*`; do zgrep -B3 "$package" $i; done)
Add Comment
Please, Sign In to add comment