Ask Your Question
0

Nova Instances : can't ping

asked 2014-03-27 15:30:45 -0500

Zike gravatar image

updated 2014-03-28 03:51:19 -0500

Hello everybody,

I have a problem with Openstack. I installed it thanks to devstack's script in a VirtualBox VM. I can create instances (cirros, ubuntu minimal...), but I can't ping or SSH them. When I try to ping, I have the error "Host not reachable", so when I try to access an instance via SSH , I have the "No route to host" error.

When I launch an instance, it has an IP like 10.0.0.x.

My interfaces:

br100     Link encap:Ethernet  HWaddr 08:00:27:54:cd:a5  
          inet addr:10.0.0.1  Bcast:10.0.0.255  Mask:255.255.255.0
          inet6 addr: fe80::9099:caff:fedf:fccc/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:305 errors:0 dropped:0 overruns:0 frame:0
          TX packets:453 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:73771 (73.7 KB)  TX bytes:48010 (48.0 KB)

eth0      Link encap:Ethernet  HWaddr 08:00:27:54:cd:a5  
          inet6 addr: fe80::a00:27ff:fe54:cda5/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:345 errors:0 dropped:0 overruns:0 frame:0
          TX packets:545 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:89214 (89.2 KB)  TX bytes:62839 (62.8 KB)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:578658 errors:0 dropped:0 overruns:0 frame:0
          TX packets:578658 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:9784674757 (9.7 GB)  TX bytes:9784674757 (9.7 GB)

virbr0    Link encap:Ethernet  HWaddr 4e:72:95:3e:8e:09  
          inet addr:192.168.122.1  Bcast:192.168.122.255  Mask:255.255.255.0
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

Here is my route table:

Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         10.0.2.2        0.0.0.0         UG    0      0        0 br100
10.0.0.0        0.0.0.0         255.255.255.0   U     0      0        0 br100
10.0.2.0        0.0.0.0         255.255.255.0   U     0      0        0 br100
192.168.122.0   0.0.0.0         255.255.255.0   U     0      0        0 virbr0

Does anyone see the problem?

Thank you! :)

edit retag flag offensive close merge delete

Comments

can you ping the gateway ?

Aref gravatar imageAref ( 2019-03-21 08:37:34 -0500 )edit

6 answers

Sort by ยป oldest newest most voted
3

answered 2014-03-29 13:50:57 -0500

SGPJ gravatar image

In security group; add all icmp, tcp & ssh rule for default group. This should solve issue. Thanks.

edit flag offensive delete link more
1

answered 2015-02-18 04:15:22 -0500

im having the same issue any one know how to solve

edit flag offensive delete link more
1

answered 2014-04-01 08:04:27 -0500

Zike gravatar image

updated 2014-04-01 08:05:45 -0500

Hi,

I have already added rules for TCP, UDP, ICMP and SSH. It doesn't work. Moreover, I have executed the following commands

# nova secgroup-add-rule default icmp -1 -1 0.0.0.0/0
# nova secgroup-add-rule default tcp 22 22 0.0.0.0/0

but it is not working.

Here is the result when I run "nova list" :

| baf68aba-d317-4834-b7dd-e8e5e533b4d6 | myUbuntuServer | ACTIVE | -          | Running     | private=10.0.0.2, 172.24.4.2 |

Here is the result when I show the details of my VM :

+--------------------------------------+----------------------------------------------------------+
| Property                             | Value                                                    |
+--------------------------------------+----------------------------------------------------------+
| OS-DCF:diskConfig                    | MANUAL                                                   |
| OS-EXT-AZ:availability_zone          | nova                                                     |
| OS-EXT-SRV-ATTR:host                 | benji-os                                                 |
| OS-EXT-SRV-ATTR:hypervisor_hostname  | benji-os                                                 |
| OS-EXT-SRV-ATTR:instance_name        | instance-00000008                                        |
| OS-EXT-STS:power_state               | 1                                                        |
| OS-EXT-STS:task_state                | -                                                        |
| OS-EXT-STS:vm_state                  | active                                                   |
| OS-SRV-USG:launched_at               | 2014-04-01T12:48:32.000000                               |
| OS-SRV-USG:terminated_at             | -                                                        |
| accessIPv4                           |                                                          |
| accessIPv6                           |                                                          |
| config_drive                         |                                                          |
| created                              | 2014-04-01T12:48:27Z                                     |
| flavor                               | m1.micro (84)                                            |
| hostId                               | 6f3e85e7180241e2c4325d571b1331704e8fa71e17b1e19b933f6d94 |
| id                                   | baf68aba-d317-4834-b7dd-e8e5e533b4d6                     |
| image                                | ubuntu-lamp (d3ffadc6-6a20-49bd-ad55-3edf3bf71d54)       |
| key_name                             | -                                                        |
| metadata                             | {}                                                       |
| name                                 | myUbuntuServer                                           |
| os-extended-volumes:volumes_attached | []                                                       |
| private network                      | 10.0.0.2, 172.24.4.2                                     |
| progress                             | 0                                                        |
| security_groups                      | default                                                  |
| status                               | ACTIVE                                                   |
| tenant_id                            | db1a3cddda9c4151acb900355638fe06                         |
| updated                              | 2014-04-01T12:48:32Z                                     |
| user_id                              | e623eeef467348e1abfa7b4df4856cd5                         |
+--------------------------------------+----------------------------------------------------------+

I added a floating IP (but is it necessary ?) with the following commands :

nova floating-ip-create public

nova add-floating-ip baf68aba-d317-4834-b7dd-e8e5e533b4d6 172.24.4.2

But when I try to ping 10.0.0.2 or 172.24.4.2, still the same error message "Host not reachable". Here is my route table :

10.0.0.0/24 dev br100  proto kernel  scope link  src 10.0.0.1 
10.0.2.0/24 dev br100  proto kernel  scope link  src 10.0.2.15 
172.24.4.0/24 dev br100  proto kernel  scope link  src 172.24.4.0 
192.168.122.0/24 dev virbr0  proto kernel  scope link  src 192.168.122.1

Thank you for your help. ;-)

edit flag offensive delete link more

Comments

Please, view Kashyap Setup Specially starting with Create Neutron networks on Controller node section. Neutron network management. It works for me every time I need this setup ti be done manually. Sorry, I presumed you had Neutron Server installed, if you manage networks via Nova. It is obviously useless suggestion.

dbaxps gravatar imagedbaxps ( 2014-04-01 13:24:15 -0500 )edit
0

answered 2019-03-19 07:06:47 -0500

d@kj gravatar image

updated 2019-03-26 16:31:09 -0500

I've the same issue, I've opened these posts:

  • https://ask.openstack.org/en/question/119783/no-route-to-instance-ssh-and-ping-no-route-to-host/ (no route to instance via Ping and Ssh)
  • https://ask.openstack.org/en/question/120627/error-could-not-add-network-device-eno2-to-ofproto-device-or-resource-busy/ (error: "could not add network device eno2 to ofproto)
edit flag offensive delete link more
0

answered 2016-04-15 05:58:38 -0500

Following worked for me

nova secgroup-add-rule default icmp -1 -1 0.0.0.0/0

nova secgroup-add-rule default tcp 22 22 0.0.0.0/0

edit flag offensive delete link more
0

answered 2014-03-28 04:52:15 -0500

dbaxps gravatar image

updated 2014-03-28 05:03:56 -0500

Have you run :-

# nova secgroup-add-rule default icmp -1 -1 0.0.0.0/0
# nova secgroup-add-rule default tcp 22 22 0.0.0.0/0

If "yes",then I would check first does it have floating IP.
For instance :

    [root@dfw02 ~(keystone_boris)]$ nova list
    +--------------------------------------+--------------+-----------+------------+-------------+------------------------------+
    | ID                                   | Name         | Status    | Task State | Power State | Networks                     |
    +--------------------------------------+--------------+-----------+------------+-------------+------------------------------+
    | c113fa70-ee79-4d5e-bc00-54f5c612b4d7 | UbuntuTRS028 | ACTIVE    | None       | Running     | int1=40.0.0.7, 192.168.1.101 |
    | 9081cf06-c540-4279-92b8-19faca78c31a | VF20RS007    | ACTIVE    | None       | Running     | int1=40.0.0.5, 192.168.1.116 |
    | e237b214-d170-4c79-8fcb-a32a11863733 | VF20RS037    | SUSPENDED | None       | Shutdown    | int1=40.0.0.2, 192.168.1.115 |
    | 97825e96-b4d1-4638-9212-480a37c61dd5 | VF20RS047    | SUSPENDED | None       | Shutdown    | int1=40.0.0.6, 192.168.1.107 |
    | e896bf9f-e48b-4863-b30f-7bacde1abf4f | VF20RS050    | SUSPENDED | None       | Shutdown    | int1=40.0.0.4, 192.168.1.108 |
    +--------------------------------------+--------------+-----------+------------+-------------+------------------------------+
    [root@dfw02 ~(keystone_boris)]$ nova show UbuntuTRS028
    +--------------------------------------+----------------------------------------------------------+
    | Property                             | Value                                                    |
    +--------------------------------------+----------------------------------------------------------+
    | status                               | ACTIVE                                                   |
    | updated                              | 2014-03-28T08:48:49Z                                     |
    | OS-EXT-STS:task_state                | None                                                     |
    | key_name                             | oskey25                                                  |
    | image                                | Attempt to boot from volume - no image supplied ...
(more)
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

2 followers

Stats

Asked: 2014-03-27 15:30:45 -0500

Seen: 15,081 times

Last updated: Mar 26