Networking Forums

Networking Forums > Computer Networking > Linux Networking > Squid blocking server hostname?

Reply
Thread Tools Display Modes

Squid blocking server hostname?

 
 
Mark Adams
Guest
Posts: n/a

 
      01-02-2006, 06:07 PM
I've been working on an issue I have here on my home network and I can't
seem to find an answer in TFM or online.

My server (Mdk 10.1) is running Squid 2.5 Stable9 and squidGuard 1.2.0.
Everything works pretty well, but whenever I attempt to access a service
on the server through a browser via the server's hostname (e.g.
https://shuttle:10000), I get a dns error: "Unable to determine IP
address from host name for shuttle". Using the FQDN for shuttle makes
no difference.

If I avoid the proxy and connect directly to the network, or if I use
the ip address (e.g. https://192.168.1.105:10000), I can connect to the
service just fine. All this is true for every machine on my LAN.

This seems like a simple thing, but it's driving me nuts. Here is my
/etc/host file for all machine including the server (shuttle):
192.168.0.1 modem
192.168.1.1 gateway
127.0.0.1 localhost
192.168.1.100 adamsmdk
192.168.1.101 chrisq
192.168.1.103 alexa
192.168.1.104 games
192.168.1.105 shuttle
192.168.1.106 media
205.171.3.65 DNS1
205.171.2.65 DNS2

Here is the /etc/resolv.conf from the server:
search adams-lan.local
nameserver 127.0.0.1
nameserver 192.168.1.1
nameserver 192.168.1.105

Anybody have any ideas?

Thanks.
--
Mark E. Adams, 2004 -- drop the "dot" to email me.
http://adamslan.shyper.com -*- Mandriva User# 263042

CONSIDER: ===========---------,,,,,,,,,............. . . . . .
How can you do 'New Math' problems with an 'Old Math' mind?
-- Charles Schulz
 
Reply With Quote
 
 
 
 
Dave Pickles
Guest
Posts: n/a

 
      01-02-2006, 07:50 PM
Mark Adams wrote:

> I've been working on an issue I have here on my home network and I can't
> seem to find an answer in TFM or online.
>
> My server (Mdk 10.1) is running Squid 2.5 Stable9 and squidGuard 1.2.0.
> Everything works pretty well, but whenever I attempt to access a service
> on the server through a browser via the server's hostname (e.g.
> https://shuttle:10000), I get a dns error: "Unable to determine IP
> address from host name for shuttle". Using the FQDN for shuttle makes
> no difference.
>
> If I avoid the proxy and connect directly to the network, or if I use
> the ip address (e.g. https://192.168.1.105:10000), I can connect to the
> service just fine. All this is true for every machine on my LAN.
>
> This seems like a simple thing, but it's driving me nuts. Here is my
> /etc/host file for all machine including the server (shuttle):
> 192.168.0.1 modem
> 192.168.1.1 gateway
> 127.0.0.1 localhost
> 192.168.1.100 adamsmdk
> 192.168.1.101 chrisq
> 192.168.1.103 alexa
> 192.168.1.104 games
> 192.168.1.105 shuttle
> 192.168.1.106 media
> 205.171.3.65 DNS1
> 205.171.2.65 DNS2
>
> Here is the /etc/resolv.conf from the server:
> search adams-lan.local
> nameserver 127.0.0.1
> nameserver 192.168.1.1
> nameserver 192.168.1.105
>
> Anybody have any ideas?


I'm not sure that Squid uses the hosts file - it has its own name server
cache to improve performance.

Since you are running your own DNS servers on your local network you could
create forward and reverse zone files for your local domain, so even if
Squid does only use DNS it should still work.
--
Dave
 
Reply With Quote
 
none@of.your.biz.nes
Guest
Posts: n/a

 
      01-03-2006, 12:32 PM

Monday January 02 2006 12:07, Mark Adams wrote to All:


MA> This seems like a simple thing, but it's driving me nuts. Here is
MA> my
MA> /etc/host file for all machine including the server (shuttle):
MA> 192.168.0.1 modem
MA> 192.168.1.1 gateway
MA> 127.0.0.1 localhost
MA> 192.168.1.100 adamsmdk
MA> 192.168.1.101 chrisq
MA> 192.168.1.103 alexa
MA> 192.168.1.104 games
MA> 192.168.1.105 shuttle
MA> 192.168.1.106 media
MA> 205.171.3.65 DNS1
MA> 205.171.2.65 DNS2

MA> Here is the /etc/resolv.conf from the server:
MA> search adams-lan.local
MA> nameserver 127.0.0.1
MA> nameserver 192.168.1.1
MA> nameserver 192.168.1.105

Do you actually have a correctly configured name server on all these
addresses? Localhost exists on every machine, so it should not be
included. "Gateway" probably tries to resolve outside addresses, not
local ones. Your "modem" is on a different network, so it should be
omitted.


Kari Suomela

KARICO Business Services
Toronto, ON Canada
http://www.karico.ca

.... My hard disk is full! Maybe I'll try this message section thing.

 
Reply With Quote
 
Mark Adams
Guest
Posts: n/a

 
      01-03-2006, 08:46 PM
(E-Mail Removed) wrote:
> Monday January 02 2006 12:07, Mark Adams wrote to All:
>
>
> MA> This seems like a simple thing, but it's driving me nuts. Here is
> MA> my
> MA> /etc/host file for all machine including the server (shuttle):
> MA> 192.168.0.1 modem
> MA> 192.168.1.1 gateway
> MA> 127.0.0.1 localhost
> MA> 192.168.1.100 adamsmdk
> MA> 192.168.1.101 chrisq
> MA> 192.168.1.103 alexa
> MA> 192.168.1.104 games
> MA> 192.168.1.105 shuttle
> MA> 192.168.1.106 media
> MA> 205.171.3.65 DNS1
> MA> 205.171.2.65 DNS2
>
> MA> Here is the /etc/resolv.conf from the server:
> MA> search adams-lan.local
> MA> nameserver 127.0.0.1
> MA> nameserver 192.168.1.1
> MA> nameserver 192.168.1.105
>
> Do you actually have a correctly configured name server on all these
> addresses? Localhost exists on every machine, so it should not be
> included. "Gateway" probably tries to resolve outside addresses, not
> local ones. Your "modem" is on a different network, so it should be
> omitted.
>

Hey Kari,

The host file (which appears on all machines) has every network address
on the LAN in it a)to simplify connectivity within the LAN (I have a
server and a media center to keep track of and Samba really likes static
IP's) and b) I've got wacky stuff going on where hostnames are not being
properly resolved.

One reason I set up a DNS is to (maybe) take a step toward getting some
of this stuff to work properly. What I'm talking about here is little
stuff like -- when I click a shortcut for "/usr/bin/www-browser
https://localhost:10000/" I get the error:

While trying to retrieve the URL: localhost:10000

The following error was encountered:

Unable to determine IP address from host name for localhost

The dnsserver returned:

Name Error: The domain name does not exist.
==============

How can localhost not resolve?! The advice I've always gotten is, "make
sure 127.0.0.1 localhost is in the host file."

Do you have any ideas why localhost won't resolve?

BTW, to keep it on topic, it turns out I can access the serve via domain
rather than host -- "adams-lan.local" works whereas "shuttle" does not.
The FQDN of the box in question is "shuttle.adams-lan.local".

Just wanted to mention it.
--
Mark E. Adams, 2004 -- drop the "dot" to email me.
http://adamslan.shyper.com -*- Mandriva User# 263042

CONSIDER: ===========---------,,,,,,,,,............. . . . . .
Expert, n.:
Someone who comes from out of town and shows slides.
 
Reply With Quote
 
ynotssor
Guest
Posts: n/a

 
      01-03-2006, 08:57 PM
"Mark Adams" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...

> Here is my /etc/host file for all machine including the server (shuttle):

....
> Anybody have any ideas?


It may just be a simple typo, but since you've made the same mistake in a
couple of posts in this thread, you should be aware that the filename is
/etc/hosts, not /etc/host. Also check /etc/nsswitch.conf for

hosts: files dns

 
Reply With Quote
 
Walter Mautner
Guest
Posts: n/a

 
      01-03-2006, 10:09 PM
Mark Adams wrote:

> I've been working on an issue I have here on my home network and I can't
> seem to find an answer in TFM or online.
>
> My server (Mdk 10.1) is running Squid 2.5 Stable9 and squidGuard 1.2.0.
> Everything works pretty well, but whenever I attempt to access a service
> on the server through a browser via the server's hostname (e.g.
> https://shuttle:10000), I get a dns error: "Unable to determine IP
> address from host name for shuttle". Using the FQDN for shuttle makes
> no difference.
>
> If I avoid the proxy and connect directly to the network, or if I use
> the ip address (e.g. https://192.168.1.105:10000), I can connect to the
> service just fine. All this is true for every machine on my LAN.
>
> This seems like a simple thing, but it's driving me nuts. Here is my
> /etc/host file for all machine including the server (shuttle):


As already mentioned, hopefully it's /etc/hosts.

> 192.168.0.1 modem
> 192.168.1.1 gateway
> 127.0.0.1 localhost
> 192.168.1.100 adamsmdk
> 192.168.1.101 chrisq
> 192.168.1.103 alexa
> 192.168.1.104 games
> 192.168.1.105 shuttle
> 192.168.1.106 media
> 205.171.3.65 DNS1
> 205.171.2.65 DNS2
>
> Here is the /etc/resolv.conf from the server:
> search adams-lan.local
> nameserver 127.0.0.1


Have you running a named on your server? How is it configured?

> nameserver 192.168.1.1
> nameserver 192.168.1.105
>

But then, the "gateway" as well as "shuttle" do run bind?
I rather suppose you want your ISPs nameservers here, probably
> 205.171.3.65 DNS1
> 205.171.2.65 DNS2


Either (look at the examples in /usr/share/doc/bind*) setup your zones -
consider you also have a (.local or whatever) domainname and use the
"search" stanza in (man /etc/)resolv.conf.

--
vista policy violation: Microsoft optical mouse detected penguin patterns
on mousepad. Partition scan in progress to remove offending
incompatible products. Reactivate MS software.
Linux 2.6.12-mm2 [LinuxCounter#295241,ICQ#4918962]
 
Reply With Quote
 
Mark Adams
Guest
Posts: n/a

 
      01-04-2006, 12:13 AM
ynotssor wrote:
> "Mark Adams" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>
>
>>Here is my /etc/host file for all machine including the server (shuttle):

>
> ...
>
>>Anybody have any ideas?

>
>
> It may just be a simple typo, but since you've made the same mistake in a
> couple of posts in this thread, you should be aware that the filename is
> /etc/hosts, not /etc/host. Also check /etc/nsswitch.conf for
>
> hosts: files dns
>

Roger that ynotssor, it is a type and the file is correctly named. I
have already checked /etc/nsswitch.conf and it appears to be okay
(hosts: files nisplus nis dns).

Thanks for your attention to this. I really do appreciate it. See my
message to Walter below for more on this situation.

--
Mark E. Adams, 2004 -- drop the "dot" to email me.
http://adamslan.shyper.com -*- Mandriva User# 263042

CONSIDER: ===========---------,,,,,,,,,............. . . . . .
Slurm, n.:
The slime that accumulates on the underside of a soap bar when
it sits in the dish too long.
-- Rich Hall, "Sniglets"
 
Reply With Quote
 
ynotssor
Guest
Posts: n/a

 
      01-04-2006, 03:47 AM
"Mark Adams" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...

> I have already checked /etc/nsswitch.conf and it appears to be okay
> (hosts: files nisplus nis dns).


Are you actually running NIS+ and NIS? If not, remove those entries from all
uncommented lines in /etc/nsswitch.conf.

 
Reply With Quote
 
Mark Adams
Guest
Posts: n/a

 
      01-04-2006, 04:04 AM
ynotssor wrote:
> "Mark Adams" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>
>
>>I have already checked /etc/nsswitch.conf and it appears to be okay
>>(hosts: files nisplus nis dns).

>
>
> Are you actually running NIS+ and NIS? If not, remove those entries from all
> uncommented lines in /etc/nsswitch.conf.
>

No, those entries showed up by default. Have rem'd references to nis,
etc. in nsswitch.conf.

--
Mark E. Adams, 2004 -- drop the "dot" to email me.
http://adamslan.shyper.com -*- Mandriva User# 263042

CONSIDER: ===========---------,,,,,,,,,............. . . . . .
Never put off till tomorrow what you can avoid all together.
 
Reply With Quote
 
ynotssor
Guest
Posts: n/a

 
      01-04-2006, 04:15 AM
"Mark Adams" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)

>> Are you actually running NIS+ and NIS? If not, remove those entries
>> from all uncommented lines in /etc/nsswitch.conf.

>
> No, those entries showed up by default. Have rem'd references to nis,
> etc. in nsswitch.conf.


:> 192.168.1.105 shuttle

nslookup -sil 192.168.1.105
nslookup -sil shuttle

What are the complete results from the above 2 commands?
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Blocking only one site of a Domain with SQUID marcel.amaral@gmail.com Linux Networking 0 05-12-2006 08:16 PM
squid server problem Pavee Linux Networking 5 04-19-2006 04:07 AM
Squid Antivirus and javascript active-x blocking hakim Linux Networking 0 06-13-2005 08:02 PM
hostname of server with multiple interfaces Eggert Ehmke Linux Networking 0 04-01-2005 05:06 PM
How to change hostname on a Server 2003? Per Windows Networking 1 05-05-2004 03:42 PM



1 2 3 4 5 6 7 8 9 10 11