快速业务通道

Debian/Ubuntu命令方式快速安装squid

作者 佚名技术 来源 Linux系统 浏览 发布时间 2012-03-31

之前,我们介绍过如何通过源码方式在Debian下安装squid当然,那是个比较详细略微麻烦的过程.今天我们试试用较简单的apt命令方法安装squid服务.看看有与源码安装有何配置上的差异:

一、运行squid安装命令

root@netren:~# apt-get install squid
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
squid-common squid-langpack
Suggested packages:
squidclient squid-cgi logcheck-database resolvconf smbclient winbind
The following NEW packages will be installed:
squid squid-common squid-langpack (这几个软件包将被安装)
0 upgraded, 3 newly installed, 0 to remove and 4 not upgraded.
Need to get 1,347kB of archives.
After this operation, 8,503kB of additional disk space will be used.
Do you want to continue [Y/n]?y
Get:1 http://hk.archive.ubuntu.com/ubuntu/ lucid/main squid-langpack 20100111-1 [228kB]
Get:2 http://hk.archive.ubuntu.com/ubuntu/ lucid/main squid-common 2.7.STABLE7-1ubuntu12 [353kB] (版本是2.7.STABLE7)
Get:3 http://hk.archive.ubuntu.com/ubuntu/ lucid/main squid 2.7.STABLE7-1ubuntu12 [766kB]
Fetched 1,347kB in 7s (180kB/s)
Preconfiguring packages ...
Selecting previously deselected package squid-langpack.
(Reading database ... 43247 files and directories currently installed.)
Unpacking squid-langpack (from .../squid-langpack_20100111-1_all.deb) ...
Selecting previously jeffrey guo deselected package squid-common.
Unpacking squid-common (from .../squid-common_2.7.STABLE7-1ubuntu12_all.deb) ...
Selecting previously deselected package squid.
Unpacking squid (from .../squid_2.7.STABLE7-1ubuntu12_i386.deb) ...
Processing triggers for ureadahead ...
Processing triggers for man-db ...
Setting up squid-langpack (20100111-1) ...
Setting up squid-common (2.7.STABLE7-1ubuntu12) ...

Setting up squid (2.7.STABLE7-1ubuntu12) ...
Creating squid spool directory structure
2011/01/05 18:05:08| Creating Swap Directories (安装时自动创建了cache缓存目录)

二、完成安装,进行查看:

root@netren:~# netstat -tunlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 1661/mysqld
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 2433/apache2
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 597/sshd
tcp 0 0 0.0.0.0:3128 0.0.0.0:* LISTEN 2601/(squid) (squid端口正在监听运行)

三、squid在系统内的安装信息:

那么,它到底将安装目录及配置文件放在哪里了呢?
/etc/default/squid
/etc/init/squid.conf
/etc/init.d/squid (服务管理中添加了squid)
/etc/logrotate.d/squid (日志管理中添加了squid)
/etc/resolvconf/update-libc.d/squid
/etc/squid/squid.conf (主要配置文件)
/usr/lib/squid/squid_session
/usr/lib/squid/squid_unix_group
/usr/lib/squid/unlinkd
/usr/lib/squid/wbinfo_group.pl

>>>阅读全文

本文出自 “网人linux社区” 博客,请务必保留此出处http://netren.blog.51cto.com/3240427/592132

凌众科技专业提供服务器租用、服务器托管、企业邮局、虚拟主机等服务,公司网站:http://www.lingzhong.cn 为了给广大客户了解更多的技术信息,本技术文章收集来源于网络,凌众科技尊重文章作者的版权,如果有涉及你的版权有必要删除你的文章,请和我们联系。以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢!

分享到: 更多

Copyright ©1999-2011 厦门凌众科技有限公司 厦门优通互联科技开发有限公司 All rights reserved

地址(ADD):厦门软件园二期望海路63号701E(东南融通旁) 邮编(ZIP):361008

电话:0592-5908028 传真:0592-5908039 咨询信箱:web@lingzhong.cn 咨询OICQ:173723134

《中华人民共和国增值电信业务经营许可证》闽B2-20100024  ICP备案:闽ICP备05037997号