FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Ubuntu > Ubuntu User

 
 
LinkBack Thread Tools
 
Old 02-11-2008, 12:35 AM
Bart Silverstrim
 
Default How to load squid was localhost

NoOp wrote:
> On 02/10/2008 04:42 PM, Bart Silverstrim wrote:
>> NoOp wrote:
>
>>> Don't know how you can pre-edit /etc/squid.conf if squid doesn't install...
>>>
>>> Can anyone else replicate? If so, perhaps we need to revisit/refile
>>> 12709 or add on to 97505.
>> I'm sorry if I'm missing it, but what did you set the visible_hostname
>> directive to in squid.conf?
>
> Haven't got that far.
>
>> That is one thing that you can't pre-edit, so it does have to be set first.
>>
>
> I guess that's the point for the 2 bug reports that I pointed to...
> there is *no* /etc/squid.conf available to edit prior to 'sudo apt-get
> install squid'.

I don't think it would be there, the file is put in by the package as
it's installed; perhaps a direction should come up and tell you that you
must edit the file for your needs before launching it (there are other
applications that must have config files altered too), but Squid is also
extremely flexible. There's no way to get a perfect install offhand
(i.e., transparent proxy? Localhost proxy only? Where, on what
partition, do you want the cache? Do you want SquidGuard configured to
be launched from Squid?)

> I might be wrong (usually am) but it would appear to me that doing a
> standard apt-get install shouldn't cause a core dump:
>
>> FATAL: Could not determine fully qualified hostname. Please set
>> 'visible_hostname'

The standard install of Squid does that. I think that would be an issue
to take up with the maintainers of Squid, not the Ubuntu maintainers of
the package.

The fortunate part is that the errors you got, if googled, should come
up with quick fixes for configuring it.

--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 03:08 AM
Charlie Kravetz
 
Default How to load squid was localhost

On Sun, 2008-02-10 at 16:36 -0800, NoOp wrote:
> On 02/10/2008 02:41 PM, Bart Silverstrim wrote:
>
> >
> > Yes, I've run into cases where screwing up hostnames can cause fun
> > problems. In the times I've set up Squid, though, it usually was more
> > tolerant of that error or at least have errors logged to the logs Squid
> > keeps that would point out DNS/hostname-related errors, or at least
> > setting it to your own host IP seemed to work.
> >
>
> Looks to be a larger problem. Just for grins I decided to install squid
> on my test laptop - the one where hostname -f works & the one that is a
> pretty much stock Ubuntu Gnome 7.10 w/2.6.22.14-generic. Got the following:
>
> $ sudo apt-get install squid
> [sudo] password for <user>:
> Reading package lists... Done
> Building dependency tree
> Reading state information... Done
> The following extra packages will be installed:
> squid-common
> Suggested packages:
> squidclient squid-cgi logcheck-database resolvconf winbind
> The following NEW packages will be installed:
> squid squid-common
> 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
> Need to get 1116kB of archives.
> After unpacking 6156kB of additional disk space will be used.
> Do you want to continue [Y/n]? y
> Get:1 http://us.archive.ubuntu.com gutsy-updates/main squid-common
> 2.6.14-1ubuntu2.1 [474kB]
> Get:2 http://us.archive.ubuntu.com gutsy-updates/main squid
> 2.6.14-1ubuntu2.1 [642kB]
> Fetched 1116kB in 7s (141kB/s)
>
> Preconfiguring packages ...
> Selecting previously deselected package squid-common.
> (Reading database ... 129738 files and directories currently installed.)
> Unpacking squid-common (from .../squid-common_2.6.14-1ubuntu2.1_all.deb) ...
> Selecting previously deselected package squid.
> Unpacking squid (from .../squid_2.6.14-1ubuntu2.1_i386.deb) ...
> Setting up squid-common (2.6.14-1ubuntu2.1) ...
> Setting up squid (2.6.14-1ubuntu2.1) ...
> Creating squid spool directory structure
> FATAL: Could not determine fully qualified hostname. Please set
> 'visible_hostname'
>
> Squid Cache (Version 2.6.STABLE14): Terminated abnormally.
> CPU Usage: 0.016 seconds = 0.012 user + 0.004 sys
> Maximum Resident Size: 0 KB
> Page faults with physical i/o: 0
> Aborted (core dumped)
> * Restarting Squid HTTP proxy squid
> * Creating squid spool directory structure
> FATAL: Could not determine fully qualified hostname. Please set
> 'visible_hostname'
>
> Squid Cache (Version 2.6.STABLE14): Terminated abnormally.
> CPU Usage: 0.016 seconds = 0.016 user + 0.000 sys
> Maximum Resident Size: 0 KB
> Page faults with physical i/o: 0
> Aborted (core dumped)
> FATAL: Could not determine fully qualified hostname. Please set
> 'visible_hostname'
>
> Squid Cache (Version 2.6.STABLE14): Terminated abnormally.
> CPU Usage: 0.020 seconds = 0.012 user + 0.008 sys
> Maximum Resident Size: 0 KB
> Page faults with physical i/o: 0
> Aborted (core dumped)
>
> Nothing in logs other than sys.log with the "Could not determine fully
> qualified hostname. Please set 'visible_hostname'"
>
> The laptop has a fixed IP (192.168 range), so it wouldn't be anything
> related to dhcp etc.
>
> Re-loop to https://bugs.launchpad.net/ubuntu/+source/squid/+bug/12709
> that the author of
> https://bugs.launchpad.net/ubuntu/+source/squid/+bug/97505
> referred to.
>
> Don't know how you can pre-edit /etc/squid.conf if squid doesn't install...
>
> Can anyone else replicate? If so, perhaps we need to revisit/refile
> 12709 or add on to 97505.
>
I will set up a test system and try this also. It might take a day or
so. Anything I need to install besides Squid?


--
Charlie Kravetz
Linux Registered User Number 425914 [http://counter.li.org/]
Never let anyone steal your DREAM. [http://keepingdreams.com]


--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 04:03 PM
Derek Broughton
 
Default How to load squid was localhost

Karl Larsen wrote:

> Padraig wrote:

>> Just out of curiosity...for what purpose are you using squid? Squid is
>> used mainly as a proxy server for companies to restrict access to
>> non-productive and inappropriate websites.
>>
>>
> It is a very good filter of popup and other CRAP people send with
> their web pages.
>
> I never see them if I can get squid and proxi loaded and working.

I agree squid is good for that, but you'll have trouble getting squid
working without a working understanding of IP address and local networks.
I can't imagine Squid really want to know your "localhost" address -
everything knows that's 127.0.0.1.
--
derek


--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 04:09 PM
Derek Broughton
 
Default How to load squid was localhost

Bart Silverstrim wrote:

> NoOp wrote:
>> On 02/10/2008 02:41 PM, Bart Silverstrim wrote:
>>
>>> Yes, I've run into cases where screwing up hostnames can cause fun
>>> problems. In the times I've set up Squid, though, it usually was more
>>> tolerant of that error or at least have errors logged to the logs Squid
>>> keeps that would point out DNS/hostname-related errors, or at least
>>> setting it to your own host IP seemed to work.
>>
>> Looks to be a larger problem. Just for grins I decided to install squid
>> on my test laptop - the one where hostname -f works & the one that is a
>> pretty much stock Ubuntu Gnome 7.10 w/2.6.22.14-generic. Got the
>> following:
...>
>> Setting up squid (2.6.14-1ubuntu2.1) ...
>> Creating squid spool directory structure
>> FATAL: Could not determine fully qualified hostname. Please set
>> 'visible_hostname'
..
>> Nothing in logs other than sys.log with the "Could not determine fully
>> qualified hostname. Please set 'visible_hostname'"
>>
>> The laptop has a fixed IP (192.168 range), so it wouldn't be anything
>> related to dhcp etc.
>>
>> Re-loop to https://bugs.launchpad.net/ubuntu/+source/squid/+bug/12709
>> that the author of
>> https://bugs.launchpad.net/ubuntu/+source/squid/+bug/97505
>> referred to.
>>
>> Don't know how you can pre-edit /etc/squid.conf if squid doesn't
>> install...
>>
>> Can anyone else replicate? If so, perhaps we need to revisit/refile
>> 12709 or add on to 97505.
>
> I'm sorry if I'm missing it, but what did you set the visible_hostname
> directive to in squid.conf?
>
> That is one thing that you can't pre-edit, so it does have to be set
> first.

Well, I agree this seems like a bug. We _do_ have debconf, so surely it
should be used to _get_ your visible hostname so that the install doesn't
b0rk. But do you really need to set visible_hostname? The implication of
the messages, to me, seems to be that if it can find a proper FQDN
from "hostname -f" (or equivalent) you should be able to get by without
pre-configuring visible_hostname.
--
derek


--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 04:10 PM
Derek Broughton
 
Default How to load squid was localhost

Bart Silverstrim wrote:

>
>
> NoOp wrote:

>>> FATAL: Could not determine fully qualified hostname. Please set
>>> 'visible_hostname'
>
> The standard install of Squid does that. I think that would be an issue
> to take up with the maintainers of Squid, not the Ubuntu maintainers of
> the package.

No, missing debconf prompts are part of packaging.
--
derek


--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 05:40 PM
Bart Silverstrim
 
Default How to load squid was localhost

Derek Broughton wrote:

> Well, I agree this seems like a bug. We _do_ have debconf, so surely it
> should be used to _get_ your visible hostname so that the install doesn't
> b0rk. But do you really need to set visible_hostname? The implication of
> the messages, to me, seems to be that if it can find a proper FQDN
> from "hostname -f" (or equivalent) you should be able to get by without
> pre-configuring visible_hostname.

Sorry, I don't mean to make it sound like an argument. I was just
telling you what I've run into while configuring it on Linux and FreeBSD
in the past.

Personally I'm not sure hostname -f would always work on every platform
(or guarantee it would always work), so maybe that's why it's avoided.
Also the proxy could be set up to work as a virtual host or a forwarder
chained to other systems, so it may not be good to "autoconfigure" it
out of fear that it'll bork up what you're trying to do. Squid is
really really flexible in deployment, so the maintainer may have opted
to support the lowest common denominator.

I honestly don't know...*shrug*

--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 06:34 PM
NoOp
 
Default How to load squid was localhost

On 02/10/2008 08:08 PM, Charlie Kravetz wrote:

>>
> I will set up a test system and try this also. It might take a day or
> so. Anything I need to install besides Squid?
>
>

Nope, just sudo apt-get install squid



--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 06:39 PM
NoOp
 
Default How to load squid was localhost

On 02/11/2008 09:09 AM, Derek Broughton wrote:

>
> Well, I agree this seems like a bug. We _do_ have debconf, so surely it
> should be used to _get_ your visible hostname so that the install doesn't
> b0rk. But do you really need to set visible_hostname? The implication of
> the messages, to me, seems to be that if it can find a proper FQDN
> from "hostname -f" (or equivalent) you should be able to get by without
> pre-configuring visible_hostname.

Interesting part is that if you add the visible_hostname, you can put in
whatever you want, even visible_hostname = foobar, and then squid will
start. I don't know what it will do afterwards - haven't had time to try
it, but it will start via sudo /etc/init.d/squid start (or restart). So
it doesn't actually appear to be checking hostname -f or anything else
that I can see. I think it's just looking for a hostname to put in the logs.




--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 07:10 PM
Derek Broughton
 
Default How to load squid was localhost

Bart Silverstrim wrote:

> Derek Broughton wrote:
>
>> Well, I agree this seems like a bug. We _do_ have debconf, so surely it
>> should be used to _get_ your visible hostname so that the install doesn't
>> b0rk. But do you really need to set visible_hostname? The implication
>> of the messages, to me, seems to be that if it can find a proper FQDN
>> from "hostname -f" (or equivalent) you should be able to get by without
>> pre-configuring visible_hostname.
>
> Sorry, I don't mean to make it sound like an argument. I was just
> telling you what I've run into while configuring it on Linux and FreeBSD
> in the past.

No, I didn't think you were arguing, I just wondered if the visible_hostname
absolutely has to be set, or if it's only needed if squid can't find the
FQDN otherwise. So there was only one thing to be done - install it and
find out...
>
> Personally I'm not sure hostname -f would always work on every platform
> (or guarantee it would always work), so maybe that's why it's avoided.

gethostname always has to work on a 'nix system, and "hostname" just uses
that.

> Also the proxy could be set up to work as a virtual host or a forwarder
> chained to other systems, so it may not be good to "autoconfigure" it
> out of fear that it'll bork up what you're trying to do.

Except that the message suggested to me that it _does_ try to
autoconfigure - and only uses visible_hostname if it can't find an FQDN.
Having now installed squid, and not having had any kind of error, I can see
that in fact if you have a valid FQDN set, it doesn't
need "visible_hostname" (in fact, /etc/squid/squid.conf says so).

> Squid is
> really really flexible in deployment, so the maintainer may have opted
> to support the lowest common denominator.

Still, if all you need is one variable to be set (visible_hostname) that's
exactly what debconf is for.
--
derek


--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 02-11-2008, 07:31 PM
Derek Broughton
 
Default How to load squid was localhost

NoOp wrote:

> On 02/11/2008 09:09 AM, Derek Broughton wrote:
>
>>
>> Well, I agree this seems like a bug. We _do_ have debconf, so surely it
>> should be used to _get_ your visible hostname so that the install doesn't
>> b0rk. But do you really need to set visible_hostname? The implication
>> of the messages, to me, seems to be that if it can find a proper FQDN
>> from "hostname -f" (or equivalent) you should be able to get by without
>> pre-configuring visible_hostname.
>
> Interesting part is that if you add the visible_hostname, you can put in
> whatever you want, even visible_hostname = foobar, and then squid will
> start. I don't know what it will do afterwards - haven't had time to try
> it, but it will start via sudo /etc/init.d/squid start (or restart). So
> it doesn't actually appear to be checking hostname -f or anything else
> that I can see. I think it's just looking for a hostname to put in the
> logs.

That's what it is. It uses gethostbyname(), and if that doesn't give it a
usable name, it uses visible_hostname, and you can specifically set
visible_hostname to be anything, because that's what you want it to report.
--
derek


--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 

Thread Tools




All times are GMT. The time now is 11:45 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org