SSH / SCP to VM failed using NAMESPACE
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
StarlingX |
Invalid
|
Medium
|
YaoLe |
Bug Description
Brief Description
-----------------
In a Duplex configuration, while using the NAMESPACE to perform SSH or SCP from the compute to the VM, this is no possible. Port 22 Connection Timed out / lost connection error message is seen.
Severity
--------
Provide the severity of the defect.
<Critical: System/Feature is not usable due to the defect>
Steps to Reproduce
------------------
1.- Follow the steps described here to set up a Duplex Configuration:
https:/
2.- Add the following property to the flavor that you are going to use to create VMs:
openstack flavor list
openstack flavor show <Specifc_
openstack flavor set <Flavor_ID> --property hw:mem_
3.- Create an image
openstack mage create --container-format bare --disk-format qcow2 --file cirros-
4.- Create a VM
openstack server create --image cirros --flavor my_tiny --network public-net0 richo1
5.- Perform the following commands to perform the NAMESPACE commands:
controller-0:~# IP=`openstack server list --name richo1 -f value -c Networks | awk '{ split($1, v, "="); print v[2]}'`
controller-0:~# NAMESPACE=$(ip netns | grep $(neutron net-list --name public-net0 -f value -c id))
controller-0:~# sudo ip netns exec $NAMESPACE scp <file_name> cirros@$IP:~/
Expected Behavior
------------------
You should be able to perform SSH / SCP using NAMESPACE
Actual Behavior
----------------
No route to host / lost connection message is seen in the console when trying to perform SSH / SCP using NAMESPACE
Reproducibility
---------------
<Reproducible/
The issue is 100% reproducible
System Configuration
-------
<Two node system (Duplex)>
Branch/Pull Time/Commit
-------
controller-0:~# cat /etc/build.info
###
### StarlingX
### Built from master
###
OS="centos"
SW_VERSION="19.01"
BUILD_TARGET="Host Installer"
BUILD_TYPE="Formal"
BUILD_ID=
JOB="STX_
<email address hidden>"
BUILD_NUMBER="182"
BUILD_HOST=
BUILD_DATE=
Last Pass
---------
October Release (2018) / Possibly in the first 2019 releases.
Timestamp/Logs
--------------
IP=`openstack server list --name $VM_NAME -f value -c Networks | awk '{ split($1, v, "="); print v[2]}'``
NAMESPACE=$(ip netns | grep $(neutron net-list --name $NET_NAME -f value -c id))
sudo ip netns exec $NAMESPACE scp <file> $USER@$IP:~/
controller-0:~# neutron net-list
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
+------
| id | name | tenant_id | subnets |
+------
| 4275c17e-
| 89ede0af-
| c0fa315a-
| f3620ff1-
+------
controller-0:~# openstack server list
+------
| ID | Name | Status | Networks | Image | Flavor |
+------
| 242991a4-
| 629487f6-
| ca0f9090-
+------
controller-0:~# IP=`openstack server list --name richo1 -f value -c Networks | awk '{ split($1, v, "="); print v[2]}'`
controller-0:~# echo $IP
192.168.101.109
controller-0:~# NAMESPACE=$(ip netns | grep $(neutron net-list --name public-net0 -f value -c id))
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
controller-0:~# echo $NAMESPACE
qdhcp-f3620ff1-
controller-0:~# NAMESPACE=
controller-0:~# sudo ip netns exec $NAMESPACE scp /home/sysadmin/
controller-0:~# sudo ip netns exec $NAMESPACE scp /home/sysadmin/
ssh: connect to host 192.168.101.109 port 22: Connection timed out (after ~1 minute you will see the message)
lost connection
controller-0:~#
Test Activity
-------------
[Regression Testing]
Changed in starlingx: | |
assignee: | nobody → Lin Shuicheng (shuicheng) |
Changed in starlingx: | |
assignee: | Forrest Zhao (forrest.zhao) → YaoLe (yaole) |
Previously, in stx.1.0, this was not expected to work. The following bugs are marked as Invalid: /bugs.launchpad .net/starlingx/ +bug/1797217 /bugs.launchpad .net/starlingx/ +bug/1799591
https:/
https:/
I am unsure if namespaces are expected to work now that we are using upstream neutron. Assigning to the networking team for input.