Red Hat - KVM Guest connectivity to KVM Host via HTTP
It had been about 10 months since I had done any "hardcore" Linux stuff and I need to get ramped up on a bunch of Red Hat technologies again - namely OCP and Satellite. So, I decided I would use my laptop to spin-up a bunch of VMs. I build my own "kickstart" environment using ISOs on my "KVM Host" to build the KVM Guests. They are NAT'd using 192.168.122.0/24 address space and virbr0.
I had everything setup and when I would monitor the console of the VM I was building, I would see "connection refused" when it would go to pull any content (i.e. my kickstart configuration).
Initially I thought I simply had to update the "public" firewall zone.
Then, I assumed I had to add the "virbr0" or "virbr0-nic0" to the zone's interfaces.
Nope...
Then I ran "setenforce 0" to see if SELinux was hosing it up. Nope.
chcon -Rvv --type=httpd_sys_content_t /var/www/html. Nope (still a good measure though).
Finally, right before I was going to bed.. I thought I would try one more thing.
# firewall-cmd --list-all-zones
And, of course, there is a libvirt zone. Ugh
TL;DR:
# firewall-cmd --permanent --zone=libvirtd --add-service=httpd
# firewall-cmd --reload
I had everything setup and when I would monitor the console of the VM I was building, I would see "connection refused" when it would go to pull any content (i.e. my kickstart configuration).
Initially I thought I simply had to update the "public" firewall zone.
Then, I assumed I had to add the "virbr0" or "virbr0-nic0" to the zone's interfaces.
Nope...
Then I ran "setenforce 0" to see if SELinux was hosing it up. Nope.
chcon -Rvv --type=httpd_sys_content_t /var/www/html. Nope (still a good measure though).
Finally, right before I was going to bed.. I thought I would try one more thing.
# firewall-cmd --list-all-zones
And, of course, there is a libvirt zone. Ugh
TL;DR:
# firewall-cmd --permanent --zone=libvirtd --add-service=httpd
# firewall-cmd --reload
Comments
Post a Comment