Bug 476922 - Error 400 (Bad request) for remote (http) rpm installation
Error 400 (Bad request) for remote (http) rpm installation
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: rpm (Show other bugs)
10
All Linux
low Severity medium
: ---
: ---
Assigned To: Panu Matilainen
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-12-17 18:58 EST by Jonathan Underwood
Modified: 2008-12-20 12:21 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-12-20 12:21:39 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jonathan Underwood 2008-12-17 18:58:59 EST
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-17 19:05:16 EST
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 05:25:01 EST
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 13:54:16 EST
Ah, yes, so it is.

What info do you need from me?
Comment 4 Jindrich Novy 2008-12-20 12:21:39 EST
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.