Bug 476922 - Error 400 (Bad request) for remote (http) rpm installation
Summary: Error 400 (Bad request) for remote (http) rpm installation
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: rpm
Version: 10
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Panu Matilainen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-12-17 23:58 UTC by Jonathan Underwood
Modified: 2008-12-20 17:21 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2008-12-20 17:21:39 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Jonathan Underwood 2008-12-17 23:58:59 UTC
Description of problem:
On a freshly installed and up to date F-10 system I encountered the following weirdness suggesting that rpm is passing a badly formed request to curl. Or maybe curl is munging it, I'm not sure:

# rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
Retrieving http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm
curl: (22) The requested URL returned error: 400
error: skipping http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm - transfer failed
Retrieving http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
curl: (22) The requested URL returned error: 400
error: skipping http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm - transfer failed

As a sanity check I then did:

# wget http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
--2008-12-17 23:45:21--  http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm
Resolving wwwcache.rl.ac.uk... 130.246.135.176, 130.246.132.26
Connecting to wwwcache.rl.ac.uk|130.246.135.176|:8080... connected.
Proxy request sent, awaiting response... 200 OK
Length: 6739 (6.6K) [application/x-rpm]
Saving to: `rpmfusion-free-release-stable.noarch.rpm'

100%[======================================>] 6,739       --.-K/s   in 0.01s   

2008-12-17 23:45:21 (552 KB/s) - `rpmfusion-free-release-stable.noarch.rpm' saved [6739/6739]

--2008-12-17 23:45:21--  http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm
Connecting to wwwcache.rl.ac.uk|130.246.135.176|:8080... connected.
Proxy request sent, awaiting response... 200 OK
Length: 6685 (6.5K) [application/x-rpm]
Saving to: `rpmfusion-nonfree-release-stable.noarch.rpm'

100%[======================================>] 6,685       --.-K/s   in 0s      

2008-12-17 23:45:21 (232 MB/s) - `rpmfusion-nonfree-release-stable.noarch.rpm' saved [6685/6685]

FINISHED --2008-12-17 23:45:21--
Downloaded: 2 files, 13K in 0.01s (1.07 MB/s)

So, the files are there on the remote server. Apologies if rpm is the wrong component for this bug.

Version-Release number of selected component (if applicable):
rpm-4.6.0-0.rc1.8.x86_64
libcurl-7.18.2-7.fc10.x86_64
libcurl-7.18.2-7.fc10.i386
curl-7.18.2-7.fc10.x86_64

How reproducible:
Everytime

Steps to Reproduce:
1.See above
2.
3.
  
Actual results:
Above.

Expected results:
Remote RPMs are fetched and installed

Additional info:
This particular machine access the web via a proxy server. In the shell I was calling rpm from http_proxy was correctly set (as evidenced by the working wget).

Comment 1 Jonathan Underwood 2008-12-18 00:05:16 UTC
Hm. Actually, this looks like rpm isn't using the environment variable http_proxy and passing it to curl... ?

Comment 2 Jindrich Novy 2008-12-19 10:25:01 UTC
Hi,

the problem seems to be elsewhere.

Doing:

export http_proxy=foo
rpm -Uhv http://bar

outputs:
rpm -Uhv http://bar
Retrieving http://bar
curl: (5) Couldn't resolve proxy 'foo'
error: skipping http://bar - transfer failed

Replacing /usr/bin/curl with symlink to /bin/env shows that http_proxy is exported in the curl's environment from rpm.

It seems to be some sort of communication error between curl and the proxy server IMO.

Comment 3 Jonathan Underwood 2008-12-19 18:54:16 UTC
Ah, yes, so it is.

What info do you need from me?

Comment 4 Jindrich Novy 2008-12-20 17:21:39 UTC
None. If you had any special proxy settings curl is unable to cope with just please file another bug with proxy description. But without direct access to the proxy it is nearly impossible to really figure out what fails.

Closing NOTABUG as it is not a bug of RPM.


Note You need to log in before you can comment on or make changes to this bug.