Cannot Ping or ssh to my VM - OPEN NEBULA 4.12


(ivan andrade castañeda) #1

Hi everyone,

I’m really new in opennebula and i’m trying to configure both “the frontend and worker node” in a single server. I have attempted to follow the documentation here for configuring Open Nebula:

http://docs.opennebula.org/4.12/design_and_installation/quick_starts/qs_ubuntu_kvm.html

Unfortunately, i can’t ping my virtual machine neither connect by ssh.

I have de following configuration:

network inteface configuration:

The loopback network interface

auto lo
iface lo inet loopback

auto br0
iface br0 inet dhcp
bridge_ports eth0
bridge_fd 9
bridge_hello 2
bridge_maxage 12
bridge_stp off


ifconfig -a

br0 Link encap:Ethernet direcciónHW 00:09:3d:13:49:a3
Direc. inet:158.42.104.139 Difus.:158.42.107.255 Másc: 255.255.252.0
ACTIVO DIFUSIÓN FUNCIONANDO MULTICAST MTU:1500 Métrica:1
Paquetes RX:14171349 errores:0 perdidos:0 overruns:0 frame:0
Paquetes TX:33911 errores:0 perdidos:0 overruns:0 carrier:0
colisiones:0 long.colaTX:0
Bytes RX:1215082462 (1.2 GB) TX bytes:4477371 (4.4 MB)

eth0 Link encap:Ethernet direcciónHW 00:09:3d:13:49:a3
ACTIVO DIFUSIÓN FUNCIONANDO MULTICAST MTU:1500 Métrica:1
Paquetes RX:26205686 errores:0 perdidos:15549 overruns:0 frame: 0
Paquetes TX:36656 errores:0 perdidos:0 overruns:0 carrier:0
colisiones:0 long.colaTX:1000
Bytes RX:3187181063 (3.1 GB) TX bytes:4892183 (4.8 MB)
Interrupción:24

virbr0 Link encap:Ethernet direcciónHW 8a:96:61:a8:2a:40
Direc. inet:192.168.122.1 Difus.:192.168.122.255 Másc:255.255 .255.0
ACTIVO DIFUSIÓN MULTICAST MTU:1500 Métrica:1
Paquetes RX:0 errores:0 perdidos:0 overruns:0 frame:0
Paquetes TX:0 errores:0 perdidos:0 overruns:0 carrier:0
colisiones:0 long.colaTX:0
Bytes RX:0 (0.0 B) TX bytes:0 (0.0 B)


my network template

NAME = "private simple"
BRIDGE = br0

AR = [
TYPE = IP4,
IP = 192.168.122.100,
SIZE = 5
]


As you can see i can instantiate a new VM without problem:

onevm list

ID   USER     GROUP    NAME            STAT UCPU    UMEM HOST             TIME
10  oneadmin oneadmin my_vm_2_basic   runn  1.0    512M localhost    5d  08h55

onevm show 10
VIRTUAL MACHINE 10 INFORMATION
ID : 10
NAME : my_vm_2_basic
USER : oneadmin
GROUP : oneadmin
STATE : ACTIVE
LCM_STATE : RUNNING
RESCHED : No
HOST : localhost
CLUSTER ID : -1
CLUSTER : default
START TIME : 06/03 15:15:50
END TIME : -
DEPLOY ID : one-10

VIRTUAL MACHINE MONITORING
CPU : 0.5
MEMORY : 512M
NETTX : 79K
NETRX : 320.5M

PERMISSIONS
OWNER : um-
GROUP : —
OTHER : —

VM DISKS
ID DATASTORE TARGET IMAGE SIZE TYPE SAVE
0 default hda CentOS-6.5_x86_64 817M/267M file NO
1 - hdb CONTEXT 0M/- - -

VM NICS
ID NETWORK VLAN BRIDGE IP MAC
0 private simple no br0 192.168.122.100 02:00:c0:a8:7a:64

SECURITY

NIC_ID NETWORK SECURITY_GROUPS
0 private simple 0

SECURITY GROUP TYPE PROTOCOL NETWORK RANGE
ID NAME VNET START SIZE
0 default OUTBOUND ALL
0 default INBOUND ALL

VIRTUAL MACHINE HISTORY
SEQ HOST ACTION DS START TIME PROLOG
0 localhost stop 0 06/03 15:16:05 1d 04h01m 0h00m35s
1 localhost none 0 06/07 16:53:13 1d 07h28m 0h00m00s

VIRTUAL MACHINE TEMPLATE
AUTOMATIC_REQUIREMENTS="!(PUBLIC_CLOUD = YES)"
CONTEXT=[
DISK_ID=“1”,
SSH_PUBLIC_KEY=“public key is here”,
TARGET=“hdb” ]
CPU="1"
GRAPHICS=[
LISTEN=“0.0.0.0”,
PORT=“5910”,
TYPE=“vnc” ]
MEMORY="512"
OS=[
ARCH=“x86_64” ]
TEMPLATE_ID="6"
VCPU="1"
VMID=“10”

After several attempts i don’t know where is the problem, anyone maybe know what can be the reason why i can’t ping my VM??? Please :disappointed_relieved: :disappointed_relieved:


(Anton Zubkov) #2

Hi! Update your vm template and add network.


(Carlos Martín) #3

Hi,

Is your VM contextualized? Can you access it via VNC and confirm the interface is configured with the right IP?


(ivan andrade castañeda) #4

Hi,

Thanks for your response, i updated my vm template and i add the option “network”

Despite this i can’t ping my VM, What could be the problem??? This is my new configuration of my VM template:

oneadmin@ubuntu002:~$ onetemplate show 8
TEMPLATE 8 INFORMATION
ID : 8
NAME : new_template
USER : oneadmin
GROUP : oneadmin
REGISTER TIME : 06/09 11:54:06

PERMISSIONS
OWNER : um-
GROUP : u–
OTHER : —

TEMPLATE CONTENTS
CONTEXT=[
NETWORK=“YES”,
SSH_PUBLIC_KEY="$USER[SSH_PUBLIC_KEY]" ]
CPU="1.0"
DISK=[
IMAGE=“CentOS-6.5_x86_64” ]
GRAPHICS=[
LISTEN=“0.0.0.0”,
TYPE=“vnc” ]
MEMORY="512"
NIC=[
NETWORK=“private simple” ]
OS=[
ARCH=“x86_64” ]
VCPU=“1”


After that i instantiate a new VM and now i have this configuration for my VM:

oneadmin@ubuntu002:~$ onevm show 14
VIRTUAL MACHINE 14 INFORMATION
ID : 14
NAME : new_template-14
USER : oneadmin
GROUP : oneadmin
STATE : ACTIVE
LCM_STATE : RUNNING
RESCHED : No
HOST : localhost
CLUSTER ID : -1
CLUSTER : default
START TIME : 06/09 11:57:17
END TIME : -
DEPLOY ID : one-14

VIRTUAL MACHINE MONITORING
CPU : 0.0
MEMORY : 512M
NETTX : 6K
NETRX : 35.9M

PERMISSIONS
OWNER : um-
GROUP : —
OTHER : —

VM DISKS
ID DATASTORE TARGET IMAGE SIZE TYPE SAVE
0 default hda CentOS-6.5_x86_64 811M/267M file NO
1 - hdb CONTEXT 0M/- - -

VM NICS
ID NETWORK VLAN BRIDGE IP MAC
0 private simple no br0 192.168.122.101 02:00:c0:a8:7a:65

SECURITY

NIC_ID NETWORK SECURITY_GROUPS
0 private simple 0

SECURITY GROUP TYPE PROTOCOL NETWORK RANGE
ID NAME VNET START SIZE
0 default OUTBOUND ALL
0 default INBOUND ALL

VIRTUAL MACHINE HISTORY
SEQ HOST ACTION DS START TIME PROLOG
0 localhost none 0 06/09 11:57:43 0d 02h18m 0h00m45s

VIRTUAL MACHINE TEMPLATE
AUTOMATIC_REQUIREMENTS="!(PUBLIC_CLOUD = YES)"
CONTEXT=[
DISK_ID=“1”,
ETH0_IP=“192.168.122.101”,
ETH0_MAC=“02:00:c0:a8:7a:65”,
NETWORK=“YES”,
SSH_PUBLIC_KEY=“ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC16HeCl9yqvKITQw7lpDvq3ezXWu29zfadDNnOaEBCwobAgbK0AXnAsWy3mk6dDPlnZrp+LBsFG2iCiDq6tnZdyXAeGJE1qDOopuZ99ccpCCBWTFkAhfM4ftMWRYd26S904/W+N/egrRkyZSHPppkoU/qVbhimKwqvJg3nEyQoSkbr5fTjzfpmF6Ole4P3JvkTzLZL1cqR8IlRmI4BexupVQwI0GHqHtXkwCD3d62Q6/CMnBRNwVPkoh1EsNZvyR531hjqNOzJTCtaYC22M57OMZiUNzD5kdXqljm9eIGYjGzAI0GHqHtXkwCD3d62Q6/CMnBRNwVPkoh1EsNZvyR531hjqNOzJTCtaYC22M57OMZiUNzD5kdXqljm9eIGYjGzA”,
TARGET=“hdb” ]
CPU="1"
GRAPHICS=[
LISTEN=“0.0.0.0”,
PORT=“5914”,
TYPE=“vnc” ]
MEMORY="512"
OS=[
ARCH=“x86_64” ]
TEMPLATE_ID="8"
VCPU="1"
VMID=“14”


(ivan andrade castañeda) #5

Hi,

yes to all…!! but i can`t ping and conect via ssh… what could be the problem???


(Anton Zubkov) #6

onevnet show?


(ivan andrade castañeda) #7

onevnet show 4:


(Vinoy Mohan) #8

Hi,

Please check your security group, your network you select while creating the vm should have the inbound and outbound security groups assigned.Once you create the vm, then you cant change that on fly.


(Tim Oldenbuerger) #9

Hi,

is your iptables firewall on that machine enabled and blocking your requests?

Also, you seem to have a public ip on br0 and try to bridge br0 to the internal net there? Or is this a typo and you want the vm to bridge to virbr0 instead?

What is it exactly you are doing in order to ping the device?

KR, Tim

PS: OMG, this was 2 years old… hopefully it is fixed by now ^^