hpe-storage / python-hpedockerplugin

HPE Native Docker Plugin
Apache License 2.0
36 stars 64 forks source link

Replication backend fails to initialize when optional snap_cpg_map parameter is not present in hpe.conf file #711

Open leenaj0hn opened 5 years ago

leenaj0hn commented 5 years ago
  1. Added a replication backend in hpe.conf file without the snap_cpg_map label [ActivePassive] hpe3par_username=3paradm hpe3par_password=3pardata hpe3par_cpg=FC_r6 hpedockerplugin_driver=hpedockerplugin.hpe.hpe_3par_fc.HPE3PARFCDriver san_ip=15.213.71.156 san_login=3paradm san_password=3pardata hpe3par_api_url=https://vp2-158.in.rdlabs.hpecorp.net/api/v1 replication_device = backend_id:S2928, replication_mode:synchronous, cpg_map:FC_r6:SSD_r6, hpe3par_api_url:https://s2928.in.rdlabs.hpecorp.net/api/v1, hpe3par_username:vrops, hpe3par_password:vrops123, san_ip:15.213.68.207, san_login:vrops, san_password:vrops123

  2. The backends fails on restarting the plugin with the below error:

2019-08-07 05:47:59,672 [INFO] hpedockerplugin.backend_orchestrator [140355703184264] MainThread Backends INITIALIZED => dict_keys(['ActivePassive', 'DEFAULT', 'merlin']) 2019-08-07 05:47:59,673 [INFO] hpedockerplugin.volume_manager [140355547667176] Thread-1 Getting source backend configuration... 2019-08-07 05:47:59,673 [INFO] hpedockerplugin.volume_manager [140355546606312] Thread-2 Overriding the value of multipath flags to True 2019-08-07 05:47:59,676 [INFO] hpedockerplugin.volume_manager [140355545545448] Thread-3 Overriding the value of multipath flags to True 2019-08-07 05:47:59,679 [INFO] hpedockerplugin.volume_manager [140355547667176] Thread-1 Got source backend configuration! 2019-08-07 05:47:59,680 [INFO] hpedockerplugin.volume_manager [140355546606312] Thread-2 Getting source backend configuration... 2019-08-07 05:47:59,680 [INFO] hpedockerplugin.volume_manager [140355545545448] Thread-3 Getting source backend configuration... 2019-08-07 05:47:59,682 [INFO] hpedockerplugin.hpe.array_connection_params [140355547667176] Thread-1 ACP Key: snap_cpg_map 2019-08-07 05:47:59,684 [INFO] hpedockerplugin.volume_manager [140355546606312] Thread-2 Got source backend configuration! 2019-08-07 05:47:59,687 [INFO] hpedockerplugin.volume_manager [140355545545448] Thread-3 Got source backend configuration! 2019-08-07 05:47:59,688 [ERROR] hpedockerplugin.backend_async_initializer [140355547667176] Thread-1 CHILD-THREAD: INITIALIZING backend: ActivePassive FAILED Error:'NoneType' object has no attribute 'split'

bhagyashree-sarawate commented 5 years ago

Need changes to handle the specified error

bhagyashree-sarawate commented 4 years ago

Fixed and merged

amitk1977 commented 4 years ago

Leena to verify and close

sonawane-shashikant commented 4 years ago

This bug is verified as FIXED. Below is the output for reference.

[root@master-node ~]# cat /etc/hpedockerplugin/hpe.conf

[DEFAULT] host_etcd_ip_address=10.50.9.10 hpe3par_username=3paradm hpe3par_password=3pardata hpe3par_cpg=SHASHI_SRC_CPG hpedockerplugin_driver=hpedockerplugin.hpe.hpe_3par_iscsi.HPE3PARISCSIDriver host_etcd_port_number=23790 ssh_hosts_key_file=/root/.ssh/known_hosts logging=DEBUG hpe3par_snapcpg=SHASHI_SNAP_CPG san_ip=10.50.3.7 san_login=3paradm san_password=3pardata hpe3par_api_url=https://10.50.3.7:8080/api/v1 hpe3par_iscsi_ips=10.50.17.220,10.50.17.221,10.50.17.222,10.50.17.223 replication_device = CSIM-EOS12_1611702, replication_mode:synchronous, cpg_map:SHASHI_SRC_CPG:SHASHI_DEST_CPG, hpe3par_api_url:https://10.50.3.22:8080/api/v1, hpe3par_username:3paradm, hpe3par_password:3pardata, san_ip:10.50.3.22, san_login:3paradm, hpe3par_iscsi_ips:10.50.1.25, san_password:3pardata [root@master-node ~]#

[root@master-node ~]# docker-compose up -d Pulling hpedockerplugin (hpestorage/legacyvolumeplugin:3.3)... 3.3: Pulling from hpestorage/legacyvolumeplugin c87736221ed0: Pull complete 674ad566676a: Pull complete bd21eb3ebfac: Pull complete 2882ae55f920: Pull complete e7824c20e2b4: Pull complete 4f4d0faba616: Pull complete 39dc489c35e7: Pull complete 6248ff5e65f4: Pull complete 141f504bc18e: Pull complete 81c6dd89716a: Pull complete 78ab44f9a50d: Pull complete 47b7f294ae86: Pull complete ab9b6884d3ac: Pull complete 6976eae40ece: Pull complete 4c628abc813d: Pull complete b747444523fb: Pull complete 1d5fbf29ad1d: Pull complete ba351dc05725: Pull complete cb398810f092: Pull complete Creating plugin_container ... done [root@master-node ~]# docker ps | grep plugin 5ee0625a3523 hpestorage/legacyvolumeplugin:3.3 "/bin/sh -c ./plug..." 9 seconds ago Up 9 seconds plugin_container [root@master-node ~]# vi /etc/hpedockerplugin/hpe.conf [root@master-node ~]# docker volume create -d hpe -o help=backends Error response from daemon: create 58d39a03bdfbef6170f526a86b9e80180b275be6bdff136b090f1006b3edad41:

NAME STATUS

DEFAULT OK [root@master-node ~]#

@leenaj0hn Please close this bug..