Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Apart from making changes in squid did you check the local firewall setting to allow http request? Because it doesn't matter whether the sites are in whitelist or not yum will check local firewall whether it is a allowed to make http request.
You have to check the system-config-security level settings, I am explaining this in context of Redhat not sure which OS you are using but as you said yum it appears that you might be using some rebuild of that category.
iptables -F will be used to flush any deny request or any chain/rules that are mentioned in /etc/sysconfig/iptables.
Now if you have enabled your local system firewall and set selinux to enforcing but you have not select HTTP to be the trusted service then what iptables -F will do? Since there is no deny rule (and no allow rule for allowing http traffic) in /etc/sysconfig/iptables for denying HTTP traffic then obviously iptables -F will not going to create one!
Usually iptables -F is used to override any deny rules set in there as far as I know. But if there is no allow (not denying the traffic here but also not allowing, see the difference) rule then?
Your question related to iptables -F was a good one. I dig more deeper in that direction and yes iptables -F can be used to flush all firewall rules in case you are unaware about how to customize the firewall. Not sure how it integrates with sElinux.
The issue that you explained here I was also getting the same issue and trying iptables -F for like 2-3 times didnt work for me. Then when I was sitting clueless I thought of checking firewall settings and sElinux settings using system-config-securitylevel and as soon as I disabled both firewall and sElinux yum worked in one shot.
As far as my explanation goes I think it does make sense ;-) I mean if we are not allowing any service and that service is also not in deny list then by default it should be denied.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.