https://rancher.com/ logo
s

stale-painting-80203

06/03/2022, 9:02 PM
With Harvester, I am blocked on couple of issues and would very much appreciate someone's help or suggestions: 1. Unable to reach Harvester created VM using it's IP from outside the host on which it's running 2. VM not being able to resolve an internal FQDN for my Rancher instance I have installed Harvester on a physical server which has only one interface with a static IP: 10.255.156.88/24, gateway and a private DNS IP. I am able ping the Harvester server using it's IP and it is able to ping the Rancher instance using FQDN. I create VMs, which seem to get a dynamic IP assigned and I can see the IP from Harvester console: 10.52.0.116. I am also able to ping this IP from the host on which it's running. From within the VM I see a different IP:10.0.2.2/24. The VM is able to ping external domains such as google.com, but not the Rancher instance (I get Temporary failure in name resolution )
s

square-orange-60123

06/03/2022, 10:46 PM
what network are you using to create your VMs? It sounds like they might not be getting an IP from your network. Which might be part of the problem for both 1 and 2
s

stale-painting-80203

06/03/2022, 10:55 PM
Based on the guide it seems a DHCP server is a must. I don't have DHCP. https://docs.harvesterhci.io/v1.0/networking/harvester-network/
w

witty-jelly-95845

06/04/2022, 9:31 AM
You can use your Harvester node as a jump host to your VM:
ssh –J rancher@<harvester_vip_address> <image_username>@<vm_ip_address>
Smoother if you've added your public SSH key to Harvester nodes and VMs so no password required
s

sticky-summer-13450

06/04/2022, 11:36 AM
Unless your Harvester nodes with one network interface are connected to a VLAN capable network switch, practically, you're only going to be able connect to VMs which are not in the same network - in your case 10.255.156.0/24. 1. have you created a VLAN 1 network in your Harvester cluster (see image 1)? 2. have you connected your VMs to that network (see image 2)? 3. have you configure your VMs with static IPs in that network?
s

stale-painting-80203

06/06/2022, 3:52 PM
Thanks for the responses. I have configured a vlan, but since I only have one interface card, for now the vlan is on the management interface. I have not been able to configure a static IP. I tried using Network Data configuration in Cloud Config when creating the VM, but it does not seem to take.
s

sticky-summer-13450

06/06/2022, 3:56 PM
So - in the switch connected to your Harvester nodes, do you actually have VLAN 30 tagged on the network interfaces your Harvester nodes are connected to?
s

stale-painting-80203

06/06/2022, 4:00 PM
Most likely not. I did not setup the physical network.
s

sticky-summer-13450

06/06/2022, 4:01 PM
If you just want the network that the Harvester node is connected on to get into the VMs you must create a Network in Harvester with the special VlanID of 1.
Like I showed in my screen grabs above....
s

stale-painting-80203

06/06/2022, 4:03 PM
ok. I didn't catch that the first time. I will change the VlanID to 1.
👍 1
@sticky-summer-13450 Thanks, that was very helpful and indeed I was able to create a VM from which I can reach my rancher instance and able to reach the VM from my rancher instance. You mentioned above that without a vlan switch I am only going to be able connect to VMs which are not in the same network 10.255.156.0/24. I didn't exactly understand. Can you elaborate?
s

sticky-summer-13450

06/07/2022, 7:59 AM
Yeh - sorry. It looks like I wrote the sentence in one way and then changed it, but did not remove the 'not'. It should say "Unless your Harvester nodes with one network interface are connected to a VLAN capable network switch, practically, you're only going to be able connect to VMs which are in the same network - in your case 10.255.156.0/24."
👍 1
i

incalculable-nail-18520

06/11/2022, 1:06 AM
well, I just solved that issue. you need to create another network, set mode to bridge, use network parameters matching your host network and it's working.
s

sticky-summer-13450

06/11/2022, 9:37 AM
You mean you've put to subnets on the same Ethernet collision-zone? Yeh, that'll work but routing can be a bit exciting 😉
83 Views