blog.erben.sk Just another sysadmin blog

12Apr/100

Remove todays debian installed packages

When you change your mind or you have installed packages on wrong server this magic command can help:


grep -e `date +%Y-%m-%d` /var/log/dpkg.log | awk '/install / {print $4}' | uniq | xargs apt-get --purge -y remove

Purge config files of removed packages:


aptitude purge `dpkg --get-selections | grep deinstall | awk '{print $1}'`

Comments (0) Trackbacks (0)

No comments yet.


Leave a comment

(required)

No trackbacks yet.