URL: https://www.opennet.ru/cgi-bin/openforum/vsluhboard.cgi
Форум: vsluhforumID12
Нить номер: 4449
[ Назад ]

Исходное сообщение
"Как прикрутить squidguard к Squid 2.6 ????"

Отправлено Orc , 25-Окт-06 17:51 
# squid -v
Squid Cache: Version 2.6.STABLE4
configure options:  '--prefix=/usr' '--exec_prefix=/usr' '--bindir=/usr/sbin' '--sbindir=/usr/sbin' '--libexecdir=/usr/lib/squid' '--sysconfdir=/etc/squid' '--localstatedir=/var/spool/squid' '--datadir=/usr/share/squid' '--enable-async-io' '--with-pthreads' '--enable-storeio=ufs,aufs,coss,diskd,null' '--enable-linux-netfilter' '--enable-linux-proxy' '--enable-arp-acl' '--enable-epoll' '--enable-removal-policies=lru,heap' '--enable-snmp' '--enable-delay-pools' '--enable-htcp' '--enable-cache-digests' '--enable-icap-support' '--enable-underscores' '--enable-referer-log' '--enable-useragent-log' '--enable-auth=basic,digest,ntlm' '--enable-carp' '--with-large-files' 'i386-debian-linux' 'build_alias=i386-debian-linux' 'host_alias=i386-debian-linux' 'target_alias=i386-debian-linux'

установил squidguard

прописал в squid.conf:

url_rewrite_program /usr/bin/squidGuard
url_rewrite_children 30

перезапускаю сквид и получаю в cache.log:

2006/10/25 17:41:37| Starting Squid Cache version 2.6.STABLE4 for i386-debian-linux-gnu...
2006/10/25 17:41:37| Process ID 22925
2006/10/25 17:41:37| With 1024 file descriptors available
2006/10/25 17:41:37| Using epoll for the IO loop
2006/10/25 17:41:37| DNS Socket created at 0.0.0.0, port 32787, FD 6
2006/10/25 17:41:37| Adding domain domen.local from /etc/resolv.conf
2006/10/25 17:41:37| Adding nameserver 10.1.1.21 from /etc/resolv.conf
2006/10/25 17:41:37| helperOpenServers: Starting 30 'squidGuard' processes
2006/10/25 17:41:38| helperStatefulOpenServers: Starting 30 'ntlm_auth' processes
2006/10/25 17:41:40| helperOpenServers: Starting 10 'ntlm_auth' processes
2006/10/25 17:41:41| User-Agent logging is disabled.
2006/10/25 17:41:41| Referer logging is disabled.
2006/10/25 17:41:41| Unlinkd pipe opened on FD 81
2006/10/25 17:41:41| Swap maxSize 5242880 KB, estimated 403298 objects
2006/10/25 17:41:41| Target number of buckets: 20164
2006/10/25 17:41:41| Using 32768 Store buckets
2006/10/25 17:41:41| Max Mem  size: 122880 KB
2006/10/25 17:41:41| Max Swap size: 5242880 KB
2006/10/25 17:41:41| Local cache digest enabled; rebuild/rewrite every 3600/3600 sec
2006/10/25 17:41:41| Store logging disabled
2006/10/25 17:41:41| Rebuilding storage in /var/spool/squid (DIRTY)
2006/10/25 17:41:41| Using Least Load store dir selection
2006/10/25 17:41:41| Set Current Directory to /var/spool/squid
2006/10/25 17:41:41| Loaded Icons.
2006/10/25 17:41:41| Accepting proxy HTTP connections at 0.0.0.0, port 8888, FD 82.
2006/10/25 17:41:41| HTCP Disabled.
2006/10/25 17:41:41| Accepting SNMP messages on port 3401, FD 83.
2006/10/25 17:41:41| WCCP Disabled.
2006/10/25 17:41:41| Ready to serve requests.
2006/10/25 17:41:41| WARNING: url_rewriter #30 (FD 36) exited
2006/10/25 17:41:41| WARNING: url_rewriter #20 (FD 26) exited
2006/10/25 17:41:41| WARNING: url_rewriter #26 (FD 32) exited
2006/10/25 17:41:41| WARNING: url_rewriter #25 (FD 31) exited
2006/10/25 17:41:41| WARNING: url_rewriter #28 (FD 34) exited
2006/10/25 17:41:41| WARNING: url_rewriter #5 (FD 11) exited
2006/10/25 17:41:41| WARNING: url_rewriter #15 (FD 21) exited
2006/10/25 17:41:41| WARNING: url_rewriter #8 (FD 14) exited
2006/10/25 17:41:41| WARNING: url_rewriter #29 (FD 35) exited
2006/10/25 17:41:41| WARNING: url_rewriter #16 (FD 22) exited
2006/10/25 17:41:41| WARNING: url_rewriter #27 (FD 33) exited
2006/10/25 17:41:41| WARNING: url_rewriter #6 (FD 12) exited
2006/10/25 17:41:41| WARNING: url_rewriter #18 (FD 24) exited
2006/10/25 17:41:41| WARNING: url_rewriter #14 (FD 20) exited
2006/10/25 17:41:41| WARNING: url_rewriter #11 (FD 17) exited
2006/10/25 17:41:41| Too few url_rewriter processes are running
FATAL: The url_rewriter helpers are crashing too rapidly, need help!

Squid Cache (Version 2.6.STABLE4): Terminated abnormally.
CPU Usage: 0.024 seconds = 0.012 user + 0.012 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 0
Memory usage for squid via mallinfo():
        total space in arena:    2644 KB
        Ordinary blocks:         2581 KB     18 blks
        Small blocks:               0 KB      0 blks
        Holding blocks:           624 KB      3 blks
        Free Small blocks:          0 KB
        Free Ordinary blocks:      62 KB
        Total in use:            3205 KB 98%
        Total free:                62 KB 2%


я пробовал играться с числом url_rewrite_children ставил и 5 и меньше и 40 и больше - результат один...

как прикрутить всё-таки squidguard к squid 2.6?


Содержание

Сообщения в этом обсуждении
"Как прикрутить squidguard к Squid 2.6 ????"
Отправлено pisez , 25-Окт-06 18:18 
А чем c-icap не устраивает ?

"Как прикрутить squidguard к Squid 2.6 ????"
Отправлено Orc , 25-Окт-06 18:42 
>А чем c-icap не устраивает ?


хм. я просто хотел отрезать баннеры и порнуху. на версии squid 2.5 стоял squidguard и прекрасно с этим справлялся.

в squid 2.6 убрали в конфиге опцию redirector и как я понял, путь к программе обработчику запросов нужно теперь прописывать в url_rewriter.

а как c-icap может мне в этом помочь?


"Как прикрутить squidguard к Squid 2.6 ????"
Отправлено Orc , 26-Окт-06 11:46 
>>А чем c-icap не устраивает ?
>
>
>хм. я просто хотел отрезать баннеры и порнуху. на версии squid 2.5
>стоял squidguard и прекрасно с этим справлялся.
>
>в squid 2.6 убрали в конфиге опцию redirector и как я понял,
>путь к программе обработчику запросов нужно теперь прописывать в url_rewriter.
>
>а как c-icap может мне в этом помочь?


никто не отвечает, поэтому напишу сам

Если добавить в squid.conf

redirect_program /usr/bin/squidGuard
redirect_children 20

при этом все опции url_rewriter закоментированы

2006/10/26 11:43:48| Starting Squid Cache version 2.6.STABLE4 for i386-debian-linux-gnu...
2006/10/26 11:43:48| Process ID 5379
2006/10/26 11:43:48| With 1024 file descriptors available
2006/10/26 11:43:48| Using epoll for the IO loop
2006/10/26 11:43:48| DNS Socket created at 0.0.0.0, port 32770, FD 6
2006/10/26 11:43:48| Adding domain domen.local from /etc/resolv.conf
2006/10/26 11:43:48| Adding nameserver 10.1.1.201 from /etc/resolv.conf
2006/10/26 11:43:48| helperOpenServers: Starting 20 'squidGuard' processes
2006/10/26 11:43:48| helperStatefulOpenServers: Starting 30 'ntlm_auth' processes
2006/10/26 11:43:50| helperOpenServers: Starting 10 'ntlm_auth' processes
2006/10/26 11:43:50| User-Agent logging is disabled.
2006/10/26 11:43:50| Referer logging is disabled.
2006/10/26 11:43:50| Unlinkd pipe opened on FD 71
2006/10/26 11:43:50| Swap maxSize 5242880 KB, estimated 403298 objects
2006/10/26 11:43:50| Target number of buckets: 20164
2006/10/26 11:43:50| Using 32768 Store buckets
2006/10/26 11:43:50| Max Mem  size: 122880 KB
2006/10/26 11:43:50| Max Swap size: 5242880 KB
2006/10/26 11:43:50| Local cache digest enabled; rebuild/rewrite every 3600/3600 sec
2006/10/26 11:43:50| Store logging disabled
2006/10/26 11:43:50| Rebuilding storage in /var/spool/squid (DIRTY)
2006/10/26 11:43:50| Using Least Load store dir selection
2006/10/26 11:43:50| Set Current Directory to /var/spool/squid
2006/10/26 11:43:50| Loaded Icons.
2006/10/26 11:43:51| Accepting proxy HTTP connections at 0.0.0.0, port 8888, FD 72.
2006/10/26 11:43:51| HTCP Disabled.
2006/10/26 11:43:51| Accepting SNMP messages on port 3401, FD 73.
2006/10/26 11:43:51| WCCP Disabled.
2006/10/26 11:43:51| Ready to serve requests.
2006/10/26 11:43:51| WARNING: url_rewriter #14 (FD 20) exited
2006/10/26 11:43:51| WARNING: url_rewriter #13 (FD 19) exited
2006/10/26 11:43:51| WARNING: url_rewriter #18 (FD 24) exited
2006/10/26 11:43:51| WARNING: url_rewriter #19 (FD 25) exited
2006/10/26 11:43:51| WARNING: url_rewriter #16 (FD 22) exited
2006/10/26 11:43:51| WARNING: url_rewriter #15 (FD 21) exited
2006/10/26 11:43:51| WARNING: url_rewriter #17 (FD 23) exited
2006/10/26 11:43:51| WARNING: url_rewriter #12 (FD 18) exited
2006/10/26 11:43:51| WARNING: url_rewriter #9 (FD 15) exited
2006/10/26 11:43:51| WARNING: url_rewriter #3 (FD 9) exited
2006/10/26 11:43:51| Too few url_rewriter processes are running
FATAL: The url_rewriter helpers are crashing too rapidly, need help!

Squid Cache (Version 2.6.STABLE4): Terminated abnormally.
CPU Usage: 0.024 seconds = 0.016 user + 0.008 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 0
Memory usage for squid via mallinfo():
        total space in arena:    2516 KB
        Ordinary blocks:         2500 KB     13 blks
        Small blocks:               0 KB      0 blks
        Holding blocks:           624 KB      3 blks
        Free Small blocks:          0 KB
        Free Ordinary blocks:      15 KB
        Total in use:            3124 KB 99%
        Total free:                15 KB 0

и всё равно он валится на url_rewriter - что за фигня?


"Как прикрутить squidguard к Squid 2.6 ????"
Отправлено SP , 14-Мрт-08 17:52 
>>
>>хм. я просто хотел отрезать баннеры и порнуху. на версии squid 2.5
>>стоял squidguard и прекрасно с этим справлялся.
>>
>>в squid 2.6 убрали в конфиге опцию redirector и как я понял,
>>путь к программе обработчику запросов нужно теперь прописывать в url_rewriter.

В 2.6-STABLE18

url_rewrite_program /usr/bin/squidGuard -c /etc/squid/squidGuard.conf

работает так как и должно работать.

А использовать для этого icap -- на мой взгляд избыточно, к тому же это фича новая и ещё недостаточно хорошо отлаженная.


"Как прикрутить squidguard к Squid 2.6 ????"
Отправлено pisez , 28-Окт-06 13:29 
http://c-icap.sourceforge.net/
http://www.chtsanti.net/c-icap/why-icap.html
http://www.chtsanti.net/c-icap/squid.html

Коротко :
ICAP can be used for ANY content-filtering and content-modification application. For instance, it can be used for language translation or Web-page personalization. It can be used for real-time streaming processing, for example, for adding subtitles in video-streams or translating speech streams (e.g., from English to Greek) in real time. It also supports various forms of adaptation of the format of a media type such as converting a MS-Word document into an HTML document or converting a Web page into a speech version of the page to assist users with vision problems. Finally, it could support the integration of intelligent mechanisms (e.g., classification techniques and collaboration filtering) to provide personalization with respect to the information needs or preferences of an individual user. The protocol allows for the identification of both the user and the client (e.g., Web or email client) used by the user.


"Как прикрутить squidguard к Squid 2.6 ????"
Отправлено Lexei , 15-Ноя-06 22:58 
>http://c-icap.sourceforge.net/
>http://www.chtsanti.net/c-icap/why-icap.html
>http://www.chtsanti.net/c-icap/squid.html
>
>Коротко :
>ICAP can be used for ANY content-filtering and content-modification application. For instance,
>it can be used for language translation or Web-page personalization. It
>can be used for real-time streaming processing, for example, for adding
>subtitles in video-streams or translating speech streams (e.g., from English to
>Greek) in real time. It also supports various forms of adaptation
>of the format of a media type such as converting a
>MS-Word document into an HTML document or converting a Web page
>into a speech version of the page to assist users with
>vision problems. Finally, it could support the integration of intelligent mechanisms
>(e.g., classification techniques and collaboration filtering) to provide personalization with respect
>to the information needs or preferences of an individual user. The
>protocol allows for the identification of both the user and the
>client (e.g., Web or email client) used by the user.

а вы сами пробовали пркрутить с-icap для целей, которые здесь описаны?



"Как прикрутить squidguard к Squid 2.6 ????"
Отправлено megaalc , 20-Мрт-07 17:26 
TO Lexei
Разобрался , почему падает?
У меня тоже самое (только редиректор samsredir):

2007/03/20 16:56:17| Starting Squid Cache version 2.6.STABLE11 for i386-portbld-freebsd6.0...
2007/03/20 16:56:17| Process ID 2351
2007/03/20 16:56:17| With 11072 file descriptors available
2007/03/20 16:56:17| Using kqueue for the IO loop
2007/03/20 16:56:17| DNS Socket created at 0.0.0.0, port 53058, FD 5
2007/03/20 16:56:17| Adding nameserver 10.0.2.2 from /etc/resolv.conf
2007/03/20 16:56:17| helperOpenServers: Starting 5 'samsredir' processes
2007/03/20 16:56:17| helperOpenServers: Starting 5 'ncsa_auth' processes
2007/03/20 16:56:17| Unlinkd pipe opened on FD 20
2007/03/20 16:56:17| Swap maxSize 102400 KB, estimated 7876 objects
2007/03/20 16:56:17| Target number of buckets: 393
2007/03/20 16:56:17| Using 8192 Store buckets
2007/03/20 16:56:17| Max Mem  size: 8192 KB
2007/03/20 16:56:17| Max Swap size: 102400 KB
2007/03/20 16:56:17| Rebuilding storage in /usr/local/squid/cache (DIRTY)
2007/03/20 16:56:17| Using Least Load store dir selection
2007/03/20 16:56:17| Set Current Directory to /usr/local/squid/cache
2007/03/20 16:56:17| Loaded Icons.
2007/03/20 16:56:18| Accepting proxy HTTP connections at 0.0.0.0, port 3128, FD 22.
2007/03/20 16:56:18| Accepting ICP messages at 0.0.0.0, port 3130, FD 23.
2007/03/20 16:56:18| Accepting SNMP messages on port 3401, FD 24.
2007/03/20 16:56:18| WCCP Disabled.
2007/03/20 16:56:18| Ready to serve requests.
2007/03/20 16:56:18| WARNING: url_rewriter #1 (FD 6) exited
2007/03/20 16:56:18| WARNING: url_rewriter #2 (FD 7) exited
2007/03/20 16:56:18| WARNING: url_rewriter #3 (FD 8) exited
2007/03/20 16:56:18| Too few url_rewriter processes are running
FATAL: The url_rewriter helpers are crashing too rapidly, need help!

Squid Cache (Version 2.6.STABLE11): Terminated abnormally.
CPU Usage: 0.050 seconds = 0.014 user + 0.035 sys
Maximum Resident Size: 8440 KB
Page faults with physical i/o: 0


"Как прикрутить squidguard к Squid 2.6 ????"
Отправлено sdm , 25-Мрт-07 14:17 
http://www.rejik.ru/forum/viewtopic.php?t=370