0

I'm setting up a Spacewalk 2.6 server on CentOS 7 to manage updates on my various CentOS 6/7 physical and virtual machines. I've got the server stood up, added some channels and repos, and registered some clients. And I can even initiate package updates from the Spacewalk interface.

These systems (including Spacewalk itself) are running as VMs on a Server 2016 Hyper-V host. More machines that I've yet to register are running on a separate Server 2016 Hyper-V failover cluster.

So far the clients I've registered show up as a Virtual Guest system type. When I go to Systems > Virtual Systems, each of the systems shows up under a Host: (Unknown Host) entry.

  • How do I (or, can I) get a Hyper-V host registered in Spacewalk?
  • How do I associate the guest machines to the host?
  • Can I work with a failover cluster as as single host?

I've been looking into virt-who but that seems like it pertains strictly to the subscription services of Satellite and RHN and not Spacewalk. I'm at a loss on how to get it set up with Spacewalk and Hyper-V, or if that's even possible. I found no mention of virt-who in the Spacewalk UserDocs.

ghaberek
  • 111
  • 5

1 Answers1

0

I was able to get virt-who working with Hyper-V, which required configuring the necessary WinRM settings on the host. It worked well enough but the problem I ran into was that it also reported my Windows guests to Spacewalk, and of course those machines aren't managed so they showed up as a bunch of unknown UUID values. I opted to use a fake backend instead and just specified the list of associated machines manually. Use virt-who-password to generate the sat_encrypted_password value in the file below and then run virt-who --one-shot to load the configuration manually.


# cat /etc/virt-who.d/hvhost1.conf
[hvhost4]
type=fake
file=/etc/virt-who.d/hvhost1.json
is_hypervisor=True
hypervisor_id=hostname
sat_server=spacewalk.mydomain.local
sat_username=admin
sat_encrypted_password=

# cat /etc/virt-who.d/hvhost1.json
{"hypervisors": [{
    "hypervisorId": {
        "hypervisorId": "HVHOST1"
    },
    "name": "hvhost1.mydomain.local",
    "uuid": "B2C3D4A1-F6E5-3412-123456567890",
    "guests": [
        {
            "guestId": "A1B2C3D4-E5F6-1234-567890123456",
            "name": "hvguest1.mydomain.local",
            "state": 1,
            "attributes": {
                    "active": 1,
                    "virtWhoType": "hyperv"
            }
        }
    ],
    "facts": {
        "hypervisor.type": "hyperv",
        "cpu.cpu_socket(s)": "2",
        "hypervisor.version": "10.0.14393.1198"
    }
}]}
ghaberek
  • 111
  • 5