debian转kali
历史文章,保留原始发布日期与正文。文中软件、链接及操作方法可能已变化,实践前请核对当前环境。
debian升级到kali2
#!/bin/bash
### Replace the Debian repos with Kali repos ###
mv /etc/apt/sources.list /etc/apt/sources.list.debian
cat <<EOF > /etc/apt/sources.list
#
# deb cdrom:[Debian GNU/Linux 2016.1 _Kali-rolling_ - Official Snapshot amd64 LIVE/INSTALL Binary 20160120-18:40]/ kali-rolling contrib main non-free
#deb cdrom:[Debian GNU/Linux 2016.1 _Kali-rolling_ - Official Snapshot amd64 LIVE/INSTALL Binary 20160120-18:40]/ kali-rolling contrib main non-free
deb http://http.kali.org/kali kali-rolling main non-free contrib
# deb-src http://http.kali.org/kali kali-rolling main non-free contrib
EOF
### Add the Kali Linux GPG keys to aptitude ###
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys ED444FF07D8D0BF6
(如果不行用 apt-key adv --keyserver hkp://keys.gnupg.net --recv-keys 7D8D0BF6)
### ubuntu
### wget -q -O - https://www.kali.org/archive-key.asc | gpg --import
### Update and install base packages ###
apt-get update
apt-get -y upgrade
apt-get -y dist-upgrade
apt-get -y autoremove --purge
apt-get -y install kali-linux-all
### Downgrade specific packages to their Kali Linux versions ###
apt-get -y --force-yes install tzdata=2016e-1
apt-get -y --force-yes install libc6=2.22-11
apt-get -y --force-yes install systemd=230-2 libsystemd0=230-2
### Double-check that nothing else needs to be updated ###
apt-get update
apt-get -y upgrade
apt-get -y dist-upgrade
### Clean up ###
apt-get -y autoremove --purge
apt-get clean
echo Done.