導航:首頁 > 配伺服器 > linux如何實現全局代理伺服器

linux如何實現全局代理伺服器

發布時間:2022-06-02 16:10:33

㈠ 如何在linux上設置全局代理

設置全局代理,方法如下:

修改 /etc/profile 文件,添加下面內容:
http_proxy=http://username:password@yourproxy:8080/
ftp_proxy=http://username:password@yourproxy:8080/
export http_proxy
export ftp_proxy

如果沒有密碼限制,則以上內容可以修改為以下內容:
http_proxy=http://yourproxy:8080/
ftp_proxy=http://yourproxy:8080/
export http_proxy
export ftp_proxy

㈡ 如何設置LINUX系統通過代理伺服器上網

linux自帶firefox
打開FireFox,編輯->首選項->常規->連接
設置FF訪問網際網路的方式
連接設置
手動配置代理
然後輸入代理伺服器IP和埠號即可。

㈢ 在Linux中可以實現代理伺服器功能的軟體是什麼

Linux中實現代理伺服器功能最常用的軟體為squid,下面是源代碼包安裝步驟:

1.從http://www.squid-cache.org下載squid-2.2.STABLE4-src.tar.gz

2.將該文件拷貝到/usr/local目錄

cpsquid-2.2.STABLE4-src.tar.gz/usr/local

3.解開該文件

tarxvzf
squid-2.2.STABLE4-src.tar.gz
#為了方便使用將目錄更名為squid
mvsquid-2.2.STABLE4squid

4.進入squid目錄

cdsquid

5.執行編譯

./configure
#系統默認安裝目錄為/usr/local/squid
/configure-prefix=/directory/you/want
#指定安裝目錄

6.執行

makeall

7.執行安裝

makeinstall

8.安裝結束後,Squid的可執行文件在安裝目錄的bin子目錄下,配置文件在etc子目錄下。

㈣ linux伺服器如何使用代理

不同的代理伺服器設置略有 不同,具體分類操作如下:
設置HTTP及HTTPS代理
對於http及https類型的請求,可以通過設置http_proxy或。方法是export http_proxy=http://proxyaddress:port。
可以寫在$HOME/.bash_profile或/etc/profile中。

設置tsocks代理
見:http://renyongjie668.blog.163.com/blog/static/16005312011824112410588/
有了tsocks代理,其實後面其他設置方式都不是很重要了,幾乎都可以用tsocks來做。

設置SSH代理
同樣用tsocks來實現代理。

Ubuntu中apt-get代理設置
新版的Ubuntu已經不支持export http_proxy就能給apt-get設置代理的方式了。這種方法要用到/etc/apt/文件夾下的apt.conf文件。注意: 某些情況下,系統安裝過程中沒有建立apt配置文件。下面的操作將視情況修改現有的配置文件或者新建配置文件。

sudo vi /etc/apt/apt.conf

在您的apt.conf文件中加入下面這行(根據你的實際情況替換yourproxyaddress和proxyport)。

Acquire::http::Proxy "http://proxyaddress:port";

如果需要用戶名密碼登陸:

Acquire::http::Proxy "http://username:password@proxyaddress:port";

保存apt.conf文件。(其他的協議自己可以適當修改)

㈤ linux 如何設置代理

linux設置代理linux系統設置yum,wget,rpm命令使用代理:1.Using
yum
with
a
proxyserver---------------------------------------To
enable
yum
operations
to
use
aproxy
server
you
should
first
add
the
following
parameter
to
/etc/yum.conf
proxy=http://yourproxy:8080/
where
yourproxy
is
the
name
of
the
proxy
server
you
want
to
access
and
8080
isthe
proxy
port.
If
the
server
requires
authentication
you
can
specify
the
logincredentials
like:proxy=http://username:password@yourproxy:8080/---------------------------------------2.
The
rpm
package
manager
makesuse
of
the
proxy
environment
variable.
This
can
be
set
system
wide
in
/etc/profile
or
user
specific
in
~/.bash_profile:export
http_proxy=http://yourproxy:8080/export
ftp_proxy=http://yourproxy:8080/---------------------------------------3.
To
use
wget
throug
a
proxy
serveradd
the
following
lines
to
/etc/wgetrc
http_proxy
=
http://yourproxy:8080/
ftp_proxy
=
http://yourproxy:8080/

㈥ 如何在Linux上,設置全局代理

編輯 profile
vi /etc/profile

最後加入:

http_proxy=http://ip:port

export http_proxy

保存、退出

應用設置如下:

source /etc/profile

閱讀全文

與linux如何實現全局代理伺服器相關的資料

熱點內容
三軌直銷系統源碼 瀏覽:321
手機銀行app怎麼更新呢 瀏覽:247
單片機匯編學習 瀏覽:531
配1u伺服器主機需要注意什麼 瀏覽:38
演算法工程師小李 瀏覽:633
程序員搬到哪裡買房好 瀏覽:627
steam測試亞洲伺服器怎麼切換 瀏覽:513
vc命令行編譯工程 瀏覽:331
當貝市場解壓步驟 瀏覽:458
哪裡有賣安卓系統的app 瀏覽:472
河南省雲伺服器租賃雲主機 瀏覽:755
基金app哪個好2021年 瀏覽:41
迷你電梯單片機 瀏覽:38
編譯電腦 瀏覽:502
程序員進入網吧 瀏覽:247
cad圖轉換pdf 瀏覽:809
魔域單機版命令 瀏覽:488
ftp伺服器需要開放什麼埠 瀏覽:327
ros編譯單個進程 瀏覽:731
如何查別人伺服器的地址 瀏覽:453