Bug 260407 - Update fails on a proxy
Summary: Update fails on a proxy
Status: RESOLVED DUPLICATE of bug 162800
Alias: None
Product: openSUSE 10.2
Classification: openSUSE
Component: Update Problems (show other bugs)
Version: Final
Hardware: Other Other
: P5 - None : Normal (vote)
Target Milestone: ---
Assignee: Katarina Machalkova
QA Contact: Jiri Srain
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-04-03 16:24 UTC by Michael Andres
Modified: 2007-04-04 12:55 UTC (History)
3 users (show)

See Also:
Found By: Other
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Andres 2007-04-03 16:24:00 UTC
I updated my PROXY from 10.1 to 10.2.

1st stage was fine. After booting YaST tried to finalize the installation:

Problem is that YaST honors the settings found in /etc/sysconfig/proxy. As I wrote above, this machine IS the proxy. All connections to the internet using the proxy will fail until sqid is up.

Thus internet test fails, (on SLES probably the registration), no update sources can be created, etc... Sorry, but the logs are no longer available.


2nd stage should test whether the proxy is usable, and if not try to fall back to direct connection.
Comment 1 Lukas Ocilka 2007-04-04 06:27:45 UTC
miracle:/usr/share/YaST2 # grep -r "/etc/sysconfig/proxy" *
clients/inst_do_net_test.ycp:       string cmd = ". /etc/sysconfig/proxy; http_proxy=${HTTP_PROXY} /usr/bin/curl -s -S -v -f -m 300 " + url + " -o " + filename;
modules/Proxy.ycp:    /* Read /etc/sysconfig/proxy */
modules/Proxy.ycp:    /* Update /etc/sysconfig/proxy */
scrconf/cfg_proxy.scr: * Summary:       Agent for reading/writing /etc/sysconfig/proxy
scrconf/cfg_proxy.scr: * Read/Sets the values defined in <tt>/etc/sysconfig/proxy</tt>
scrconf/cfg_proxy.scr:    `SysConfigFile("/etc/sysconfig/proxy")

Network test uses proxy before online update is called. Online update uses the result of network test. Installation/Update workflow doesn't influence using or not using proxy and will never do that.

Network test could do that but... that needn't be the best solution.

First try: reassigning to network-test maintainer.
Next try could be: maintainer of online update.
Comment 2 Katarina Machalkova 2007-04-04 09:32:45 UTC
(In reply to comment #0)
> Problem is that YaST honors the settings found in /etc/sysconfig/proxy. As I
> wrote above, this machine IS the proxy. 

Alors, is proxy set to 'localhost' in sysconfig?

> All connections to the internet using
> the proxy will fail until sqid is up.

Yes, the solution would be to start proxy service before network test comes up, but ... which one? There are several possibilities (squid, tinyproxy,... etc.). This is certainly not a way to go.

> 2nd stage should test whether the proxy is usable, and if not try to fall back
> to direct connection.

But wouldn't e.g. download of release notes fail without proxy? Would registration stuff work with direct connection? I don't know since I've never maintained proxy server ...
Comment 3 Michael Andres 2007-04-04 11:00:10 UTC
(In reply to comment #2)
 
> Alors, is proxy set to 'localhost' in sysconfig?

No, in my case: HTTP_PROXY="http://proxy:3128/"

My /etc/hosts resolves '127.0.0.1 localhost proxy'. But it's probably not a sufficient to test for (proxy==127.0.0.1).


> But wouldn't e.g. download of release notes fail without proxy? Would
> registration stuff work with direct connection? I don't know since I've 
> never maintained proxy server ...

You don't have to maintain one. Look at your browser (preferences -> proxy settings). It does not make a difference to you whether a proxy or direct connection to the internet is configured there. You type an URL and the browser shows the data.

A) If the client we're updating has no proxy configured, ftp/http downloads
will connect to the appropriate server providing the data.

B) If the client has a proxy configured, ftp/http downloads will connect to 
the proxy and ask him to provide the data. 

If the proxy is not available, download fails. It actually does not matter whether the proxy is the local machine or a remote one which is e.g. powered off. When updating the proxy itself, you can simply be shure the proxy is not available, that's it.

But we can't simply turn off proxy by default, as using a proxy might be required (direct connections forbidden).


Thus I'd suggest to test whether a configured proxy is actually available, and if not, continue without proxy. If this fails as well, then the result is not worse. 

Comment 4 Katarina Machalkova 2007-04-04 12:55:16 UTC

*** This bug has been marked as a duplicate of bug 162800 ***