https://rancher.com/ logo
Title
l

loud-nest-3266

12/23/2022, 7:30 AM
I have deployed rancher on 3 VM instances but unable to access it through external network i am new to harvester kindly guide me through. Here is my rancher vm.yaml
apiVersion: <http://kubevirt.io/v1|kubevirt.io/v1>
kind: VirtualMachine
metadata:
  annotations:
    <http://harvesterhci.io/vmRunStrategy|harvesterhci.io/vmRunStrategy>: RerunOnFailure
    <http://harvesterhci.io/volumeClaimTemplates|harvesterhci.io/volumeClaimTemplates>: '[{"metadata":{"name":"rancher-01-disk-0-jx4np","annotations":{"<http://harvesterhci.io/imageId|harvesterhci.io/imageId>":"default/image-kfdjn"}},"spec":{"accessModes":["ReadWriteMany"],"resources":{"requests":{"storage":"10Gi"}},"volumeMode":"Block","storageClassName":"longhorn-image-kfdjn"}},{"metadata":{"name":"rancher-01-disk-1-arr2i"},"spec":{"accessModes":["ReadWriteMany"],"resources":{"requests":{"storage":"10Gi"}},"volumeMode":"Block","storageClassName":"harvester-longhorn"}}]'
    <http://kubevirt.io/latest-observed-api-version|kubevirt.io/latest-observed-api-version>: v1
    <http://kubevirt.io/storage-observed-api-version|kubevirt.io/storage-observed-api-version>: v1alpha3
    <http://network.harvesterhci.io/ips|network.harvesterhci.io/ips>: '[]'
  creationTimestamp: "2022-12-22T11:21:03Z"
  finalizers:
  - <http://wrangler.cattle.io/VMController.UnsetOwnerOfPVCs|wrangler.cattle.io/VMController.UnsetOwnerOfPVCs>
  generation: 2
  labels:
    <http://harvesterhci.io/creator|harvesterhci.io/creator>: harvester
  managedFields:
  - apiVersion: <http://kubevirt.io/v1alpha3|kubevirt.io/v1alpha3>
    fieldsType: FieldsV1
    fieldsV1:
      f:metadata:
        f:annotations:
          f:<http://kubevirt.io/latest-observed-api-version|kubevirt.io/latest-observed-api-version>: {}
          f:<http://kubevirt.io/storage-observed-api-version|kubevirt.io/storage-observed-api-version>: {}
    manager: Go-http-client
    operation: Update
    time: "2022-12-22T11:21:03Z"
  - apiVersion: <http://kubevirt.io/v1|kubevirt.io/v1>
    fieldsType: FieldsV1
    fieldsV1:
      f:metadata:
        f:annotations:
          .: {}
          f:<http://harvesterhci.io/vmRunStrategy|harvesterhci.io/vmRunStrategy>: {}
          f:<http://harvesterhci.io/volumeClaimTemplates|harvesterhci.io/volumeClaimTemplates>: {}
          f:<http://network.harvesterhci.io/ips|network.harvesterhci.io/ips>: {}
        f:finalizers:
          .: {}
          v:"<http://wrangler.cattle.io/VMController.UnsetOwnerOfPVCs|wrangler.cattle.io/VMController.UnsetOwnerOfPVCs>": {}
        f:labels:
          .: {}
          f:<http://harvesterhci.io/creator|harvesterhci.io/creator>: {}
      f:spec:
        .: {}
        f:runStrategy: {}
        f:template:
          .: {}
          f:metadata:
            .: {}
            f:annotations:
              .: {}
              f:<http://harvesterhci.io/sshNames|harvesterhci.io/sshNames>: {}
            f:labels:
              .: {}
              f:<http://harvesterhci.io/vmName|harvesterhci.io/vmName>: {}
              f:<http://harvesterhci.io/vmNamePrefix|harvesterhci.io/vmNamePrefix>: {}
          f:spec:
            .: {}
            f:accessCredentials: {}
            f:affinity:
              .: {}
              f:podAntiAffinity:
                .: {}
                f:preferredDuringSchedulingIgnoredDuringExecution: {}
            f:domain:
              .: {}
              f:cpu:
                .: {}
                f:cores: {}
                f:sockets: {}
                f:threads: {}
              f:devices:
                .: {}
                f:disks: {}
                f:inputs: {}
                f:interfaces: {}
              f:features:
                .: {}
                f:acpi:
                  .: {}
                  f:enabled: {}
              f:machine:
                .: {}
                f:type: {}
              f:resources:
                .: {}
                f:limits:
                  .: {}
                  f:cpu: {}
                  f:memory: {}
            f:evictionStrategy: {}
            f:hostname: {}
            f:networks: {}
            f:volumes: {}
    manager: harvester
    operation: Update
    time: "2022-12-22T11:21:03Z"
  - apiVersion: <http://kubevirt.io/v1alpha3|kubevirt.io/v1alpha3>
    fieldsType: FieldsV1
    fieldsV1:
      f:status:
        .: {}
        f:conditions: {}
        f:created: {}
        f:printableStatus: {}
        f:ready: {}
        f:volumeSnapshotStatuses: {}
    manager: Go-http-client
    operation: Update
    subresource: status
    time: "2022-12-22T11:21:35Z"
  name: rancher-01
  namespace: harvester-public
  resourceVersion: "93095"
  uid: 7ac03fdb-8b03-4f41-ab64-fde0b1dfeb1e
spec:
  runStrategy: RerunOnFailure
  template:
    metadata:
      annotations:
        <http://harvesterhci.io/sshNames|harvesterhci.io/sshNames>: '["harvester-public/axon-coreos"]'
      creationTimestamp: null
      labels:
        <http://harvesterhci.io/vmName|harvesterhci.io/vmName>: rancher-01
        <http://harvesterhci.io/vmNamePrefix|harvesterhci.io/vmNamePrefix>: rancher
    spec:
      affinity:
        podAntiAffinity:
          preferredDuringSchedulingIgnoredDuringExecution:
          - podAffinityTerm:
              labelSelector:
                matchLabels:
                  <http://harvesterhci.io/vmNamePrefix|harvesterhci.io/vmNamePrefix>: rancher
              topologyKey: <http://kubernetes.io/hostname|kubernetes.io/hostname>
            weight: 1
      domain:
        cpu:
          cores: 4
          sockets: 1
          threads: 1
        devices:
          disks:
          - bootOrder: 1
            cdrom:
              bus: sata
            name: disk-0
          - bootOrder: 2
            disk:
              bus: sata
            name: disk-1
          - disk:
              bus: virtio
            name: cloudinitdisk
          inputs:
          - bus: usb
            name: tablet
            type: tablet
          interfaces:
          - macAddress: 52:54:00:65:a5:1d
            masquerade: {}
            model: virtio
            name: default
        features:
          acpi:
            enabled: true
        machine:
          type: q35
        memory:
          guest: 8092Mi
        resources:
          limits:
            cpu: "4"
            memory: 8Gi
          requests:
            cpu: 250m
            memory: 5461Mi
      evictionStrategy: LiveMigrate
      hostname: rancher
      networks:
      - name: default
        pod: {}
      volumes:
      - name: disk-0
        persistentVolumeClaim:
          claimName: rancher-01-disk-0-jx4np
      - name: disk-1
        persistentVolumeClaim:
          claimName: rancher-01-disk-1-arr2i
      - cloudInitNoCloud:
          networkDataSecretRef:
            name: rancher-01-nmowg
          secretRef:
            name: rancher-01-nmowg
        name: cloudinitdisk
status:
  conditions:
  - lastProbeTime: null
    lastTransitionTime: "2022-12-22T11:21:33Z"
    status: "True"
    type: Ready
  - lastProbeTime: null
    lastTransitionTime: null
    status: "True"
    type: LiveMigratable
  created: true
  printableStatus: Running
  ready: true
  volumeSnapshotStatuses:
  - enabled: false
    name: disk-0
    reason: 2 matching VolumeSnapshotClasses for longhorn-image-kfdjn
  - enabled: false
    name: disk-1
    reason: 2 matching VolumeSnapshotClasses for harvester-longhorn
  - enabled: false
    name: cloudinitdisk
    reason: Snapshot is not supported for this volumeSource type [cloudinitdisk]
o

orange-policeman-97710

12/24/2022, 3:36 PM
It seems that you don't select any network for the rancher VM.