Problem Description: After installing the system, just want to start to write the program, found that Vim has not been installed, with Su-switch to root after
Run Apt-get install vim directly, prompt to insert disc source, then enter, into an unresolved state.
Search the Internet and find out how to do it:
The following is done in Root's home directory,
CD ~
To update the system's software source first:
sudo cp/etc/apt/sources.list/etc/apt/sources.list_bak #备份一下软件源sudo vi/etc/apt/sources.list Add the following: NetEase 163 update server: Deb Http://mirrors.163.com/debian/squeeze main Non-free contribdeb http://mirrors.163.com/debian/ Squeeze-proposed-updates main Non-free contribdeb-src Http://mirrors.163.com/debian/squeeze main Non-free CONTRIBDEB-SRC http://mirrors.163.com/debian/squeeze-proposed-updates main non-free contrib# Sohu Update server: Deb/http Mirrors.sohu.com/debian/lenny main Non-free contribdeb http://mirrors.sohu.com/debian/lenny-proposed-updates main Non-free contribdeb-src http://mirrors.sohu.com/debian/lenny main Non-free contribdeb-src http://mirrors.sohu.com/ Debian/lenny-proposed-updates main Non-free contrib
then update the source under System
Apt-get update
Apt-get upgrade
Then start installing VIM
Apt-get install vim
found, still need to insert disk
again to search the web, found that the original CD-ROM source must be commented out
and re-execute the above
Vi/etc/apt/sources.list
Add a # number to the beginning of the line with CDROM
And then execute it again.
Apt-get Install Vim
Tip Older version of Vim-common is installed, but new version of Vim-commonn cannot be installed
Continue to search the Internet, eventually through, manually delete the original old library, you can
Apt-get Remove Vim-common
Finally execute Apt-get install vim
Done.
Reference Links:
Http://www.cnblogs.com/xshwy/archive/2012/07/15/2592381.html
http://m.wenda.so.com/q/1378290958068376
http://blog.csdn.net/daofengdeba/article/details/7597619
Install vim under Debian