首页 > 代码库 > Linux 代理设置

Linux 代理设置

apt proxy

vim /etc/apt/apt.confAcquire::http::proxy "http://10.48.127.169:8080/";  Acquire::ftp::proxy "ftp://10.48.127.169:8080/";  Acquire::https::proxy "https://10.48.127.169:8080/"; 

当前用户生效

vim  ~/.bashrcexport http_proxy=http://10.48.127.169:8080/export https_proxy=http://10.48.127.169:8080/

全局配置

vim /etc/profileexport http_proxy=http://10.48.127.169:8080export https_proxy=http://10.48.127.169:8080

 配置DNS

search chotim.comnameserver 192.168.2.2

 安装SSH

apt-get install openssh-serverps -e |grep ssh/etc/init.d/ssh start#或service ssh startservice ssh stop

添加用户

useradd username

修改密码

passwd root

 

Linux 代理设置