Centos proxy Internet access settings
1. Set proxy on the built-in centos Interface1. interface settings
The default proxy port of squid is 3128.
2. firefox settingsSettings> LAN Settings> ip: port/username: passwd
Ii. Set proxies for terminal1. Temporary proxyIf you only use a proxy temporarilyRun the following command on the command line:
export http_proxy="http://210.45.72.XX:808"
In addition:/root/.bashrc
Add:export http_proxy="http://username:password@210.45.72.XX:808"
If you are using an ip address or the computer's NIC address authentication, you can ignore all usernames and passwords. Note: When you stop using the proxy, you must change the changed file to the original one. Especially if you use export
Note: When you stop using the proxy, you must change the modified file to the original one.export http_proxy="http://210.45.72.XX:808"
Command, enter:unset http_proxy ,
Remove environment variables. Because the export http_proxy = "http://210.45.72.XX: 808" command is essentially to write the settings after the export into the environment settings file.
Enter env to view all environment variable settings. env> env.txt to output the environment variable to env.txt, and then open the variable. unset to cancel the environment variable.
2. Global proxy
vim /etc/profile
http_proxy = http://username:password@yourproxy:8080/ftp_proxy = http://username:password@yourproxy:8080/export http_proxyexport ftp_proxy
source /etc/profile
3. yum proxy
vim /etc/yum.conf
proxy = http://username:password@yourproxy:8080/
source /etc/profile
4. wget proxy
vim /etc/wgetrc
- The last line is added as follows:
http_proxy = http://username:password@yourproxy:8080/ftp_proxy = http://username:password@yourproxy:8080/
source /etc/profile
If you use yum to install software in CentOS6.5 installed by yourself, the Error 404 is always prompted. Baidu then finds that you have to set the yum source. After CentOS is installed, you generally need to modify the yum source to achieve an ideal speed when installing and updating the rpm package. There are 163 sources and sohu sources that are relatively fast in China. Here we use the 163 source as an example. 1. cd/etc/yum. repos. d2. mv CentOS-Base.repo CentOS-Base.repo.backup3. wget http://mirrors.163.com/.help/CentOS6-Base-163.repo4. mv CentOS6-Base-163.repo CentOS-Base.repo5. yum clean all