rpm-software-management / yum

[DEPRECATED] YUM package manager
GNU General Public License v2.0
127 stars 87 forks source link

Output response body or log file location when receiving a 503 response code #92

Closed ElijahLynn closed 4 years ago

ElijahLynn commented 5 years ago

Just spend a couple hours debugging an issue inside a firewall where yum was getting a 503 response code but no response body. And a message around "Failure talking to yum: Cannot find a valid baseurl for repo: remi". Turns out it was blocked by the firewall and tshark actually showed the whole response body, explaining the reason for the 503 (blocked yum useragent) and who to email etc.

yum needs to output the response body or a log file location with the response body in it. A user shouldn't need tshark to read the response body of a 503.

How does this sound or is their a functionality built into yum already to show this information? eg. debug mode etc.

Even if there is most users won't know about it and if there is a 503 then yum should probably at least say "re-run yum with --debug to see all response bodies".

ElijahLynn commented 5 years ago

Also, side-issue "Failure talking to yum: Cannot find a valid baseurl for repo: remi" could be better phrased.

"Failure talking to yum" => How is this possible, it is yum. Yum can't have a failure talking to itself. How can we better word this?

"Cannot find a valid baseurl for repo: remi" => To me this implied it couldn't find a baseurl in the /etc/yum.repos.d/remi.repo config, and when I open it, there is a commented out baseurl. But in reality it was trying to "contact" another, default baseurl, that wasn't in that file. So maybe "Cannot establish connection to baseurl $BASEURL for repo: remi" would be better.

dmnks commented 4 years ago

Thank you for the report. However, please note that this project has been deprecated and is no longer maintained upstream. Please consider migrating to DNF which is the successor of YUM. That said, I’ll close this issue now.