相信不少朋友都遇到过在使用OVZ的VPS的时候安装Debian 7, 在更新完系统后就出现如下, 并导致重启后连不上SSH
.init: timeout opening/writing control channel /run/initctl
的问题. 其实这个问题已经不是第一次被人反应了.
https://bugzilla.openvz.org/show_bug.cgi?id=2657
当安装debian 6的时候, 发现一切都正常不会有什么问题. 那么我们就从6升级到7吧.
全新安装系统后
更改时区
dpkg-reconfigure tzdata
卸载Apache(为了纯净安装)
apt-get -y --purge autoremove apache2 apache2.2-common apache2-doc apache2-utils
如果你在读取源的时候会强行用ipv6解析, 那么可以输入
sed -i '1i\precedence ::ffff:0:0/96 100' /etc/gai.conf
更新当前debian 6
apt-get -y update;apt-get -y upgrade
安装nano, 当然你也可以使用vi
apt-get -y install nano
编辑更新源列表文件
nano /etc/apt/sources.list
删除其中内容并添加:
deb http://ftp.us.debian.org/debian/ wheezy main deb-src http://ftp.us.debian.org/debian/ wheezy main deb http://security.debian.org/ wheezy/updates main deb-src http://security.debian.org/ wheezy/updates main # wheezy-updates, previously known as 'volatile' deb http://ftp.us.debian.org/debian/ wheezy-updates main deb-src http://ftp.us.debian.org/debian/ wheezy-updates main
如果害怕SSH断掉可安装screen
apt-get -y install screen;screen
如果SSH断开可输入如下来恢复
screen -Dr
升级Debian 6到Debian 7
apt-get -y update;apt-get -y install apt dpkg aptitude;apt-get -y dist-upgrade; reboot
清理垃圾
apt-get autoclean apt-get autoremove
文章评论