LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-18-2009, 03:34 AM   #1
your_shadow03
Senior Member
 
Registered: Jun 2008
Location: Germany
Distribution: Slackware
Posts: 1,466
Blog Entries: 6

Rep: Reputation: 51
SQUID Issue?


I followed the link: http://www.cyberciti.biz/tips/linux-...uid-howto.html till the end and followed it line by line.
But I am stuck when I restart the squid:
Code:
[root@pe ~]# service squid restart
Stopping squid:                                            [FAILED]
Starting squid:                                            [FAILED]
[root@pe ~]#
My logs are :
File: access.log
Code:
[root@pe ~]# tail -f /var/log/squid/access.log
1228475770.977     30 10.14.2.254 TCP_DENIED/403 1352 GET http://google.com/ - NONE/- text/html
1228475771.110      2 10.14.2.254 TCP_DENIED/403 1374 GET http://google.com/favicon.ico - NONE/- text/html
1228475774.095      1 10.14.2.254 TCP_DENIED/403 1374 GET http://google.com/favicon.ico - NONE/- text/html
1228475781.008      0 10.14.2.254 TCP_DENIED/403 1358 GET http://10.14.236.169/ - NONE/- text/html
1228475781.159      0 10.14.2.254 TCP_DENIED/403 1380 GET http://10.14.236.169/favicon.ico - NONE/- text/html
1228475784.065      1 10.14.2.254 TCP_DENIED/403 1380 GET http://10.14.236.169/favicon.ico - NONE/- text/html
1228475789.493      6 10.14.2.254 TCP_DENIED/403 1370 GET http://10.14.236.169:10000/ - NONE/- text/html
1228475789.564      2 10.14.2.254 TCP_DENIED/403 1392 GET http://10.14.236.169:10000/favicon.ico - NONE/- text/html
1228475792.584      0 10.14.2.254 TCP_DENIED/403 1392 GET http://10.14.236.169:10000/favicon.ico - NONE/- text/html
File : squid.log
Code:
[root@pe ~]# tail -f /var/log/squid/
access.log  cache.log   squid.out   store.log
[root@pe ~]# tail -f /var/log/squid/squid.out
Squid Cache (Version 2.5.STABLE14): Terminated abnormally.
2009/02/18 15:03:45| ACL name 'localhost' not defined!
FATAL: Bungled squid.conf line 59: http_access allow localhost
Squid Cache (Version 2.5.STABLE14): Terminated abnormally.
2009/02/18 15:03:52| ACL name 'localhost' not defined!
FATAL: Bungled squid.conf line 59: http_access allow localhost
Squid Cache (Version 2.5.STABLE14): Terminated abnormally.
2009/02/18 15:03:52| ACL name 'localhost' not defined!
FATAL: Bungled squid.conf line 59: http_access allow localhost
Squid Cache (Version 2.5.STABLE14): Terminated abnormally.

Last edited by your_shadow03; 02-18-2009 at 03:36 AM.
 
Old 02-18-2009, 03:59 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
2009/02/18 15:03:45| ACL name 'localhost' not defined!
FATAL: Bungled squid.conf line 59: http_access allow localhost
In a default squid installation there are the following ACLs:
Code:
acl manager proto cache_object
acl localhost src 127.0.0.1/32
I guess you miss the 2nd ACL, that's why squid complains.
 
Old 02-18-2009, 04:32 AM   #3
your_shadow03
Senior Member
 
Registered: Jun 2008
Location: Germany
Distribution: Slackware
Posts: 1,466

Original Poster
Blog Entries: 6

Rep: Reputation: 51
Thanks BATHORY:~~~
Hey Its Worked !!!
 
Old 02-18-2009, 04:42 AM   #4
your_shadow03
Senior Member
 
Registered: Jun 2008
Location: Germany
Distribution: Slackware
Posts: 1,466

Original Poster
Blog Entries: 6

Rep: Reputation: 51
One more query - Now That Squid is successfully installed and running.I need to check if it really is working.
My Squid.conf is :
Code:
[root@pe ~]#  grep -v "^#" /etc/squid/squid.conf | sed -e '/^$/d'               httpd_accel_host virtual
httpd_accel_port 80
httpd_accel_with_proxy on
httpd_accel_uses_host_header on
acl localhost src 10.14.236.0/24
acl lan src localhost 10.14.236.92 10.14.236.94
http_access allow localhost
http_access allow lan
hosts_file /etc/hosts
 http_port 10.14.236.169:3128
hierarchy_stoplist cgi-bin ?
acl QUERY urlpath_regex cgi-bin \?
no_cache deny QUERY
auth_param basic children 5
auth_param basic realm Squid proxy-caching web server
auth_param basic credentialsttl 2 hours
auth_param basic casesensitive off
refresh_pattern ^ftp:           1440    20%     10080
refresh_pattern ^gopher:        1440    0%      1440
refresh_pattern .               0       20%     4320
acl all src 0.0.0.0/0.0.0.0
acl manager proto cache_object
acl localhost src 127.0.0.1/255.255.255.255
acl to_localhost dst 127.0.0.0/8
acl SSL_ports port 443 563
acl Safe_ports port 80          # http
acl Safe_ports port 21          # ftp
acl Safe_ports port 443 563     # https, snews
acl Safe_ports port 70          # gopher
acl Safe_ports port 210         # wais
acl Safe_ports port 1025-65535  # unregistered ports
acl Safe_ports port 280         # http-mgmt
acl Safe_ports port 488         # gss-http
acl Safe_ports port 591         # filemaker
acl Safe_ports port 777         # multiling http
acl CONNECT method CONNECT
http_access allow localhost
http_access deny all
http_reply_access allow all
icp_access allow all
coredump_dir /var/spool/squid
[root@pe ~]#

Now How can i check if the squid server is working or not.Do I need to do settings at the client Machine.
 
Old 02-18-2009, 04:57 AM   #5
your_shadow03
Senior Member
 
Registered: Jun 2008
Location: Germany
Distribution: Slackware
Posts: 1,466

Original Poster
Blog Entries: 6

Rep: Reputation: 51
I tried Going to Internet Options > Connection > Pointing the Default Proxy Server to the SQUID Server ort 80.
But it dint open google.com.
No Update in squid.log or access.log under /var/log/squid directory.
 
Old 02-18-2009, 05:52 AM   #6
chitambira
Member
 
Registered: Oct 2008
Location: Online
Distribution: RHEL, Centos
Posts: 373
Blog Entries: 1

Rep: Reputation: 51
you gotta have to define your client network(computers that will use the proxy server) lets sat if their network is 10.1.1.0/24
then you need to add this to your squid.conf

acl mynetwork src 10.1.1.0/24


then first line of the http_access allow lines should be like

http_access allow mynetwork


the you restart your squid or issue /usr/local/sbin/squid -k reconfigure
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Squid Logging Issue cmfarley19 Linux - Server 1 07-16-2008 01:07 PM
Squid issue - again jonette20 Linux - Server 16 08-19-2007 01:35 PM
squid cache issue !! hitesh_linux Linux - Enterprise 16 04-23-2007 03:01 AM
Squid issue MensaWater *BSD 2 05-18-2006 08:47 AM
squid issue ahmad82pkn Linux - Networking 4 02-06-2006 08:33 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 02:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration