Hi Brain,

Thanks for the quick response. I will try editing this property and let you
know how it goes.

Regards
Vivek

On Fri, Dec 4, 2020 at 12:49 AM FREEMAN, BRIAN D <[email protected]> wrote:

> Looks like GLOBAL_INJECTED_PRIVATE_KEY is the variable in
> /share/config/robot_properties.py  that contains the path to the keyfile
> and in your case it is null.
>
>
>
> Populate it in the robot container configmap to point to where you have
> put the private key to be used.
>
>
>
> Brian
>
>
>
>
>
> root@dev-robot-c6cdb77c4-r92nz:/var/opt/ONAP/robot/resources/stack_validation#
> cat validate_common.robot
>
> *** Settings ***
>
> Documentation    Testing openstack.
>
> Library    OperatingSystem
>
> Library    SSHLibrary
>
> Library    RequestsLibrary
>
> Library    ONAPLibrary.JSON
>
> Library    ONAPLibrary.Openstack
>
> Library    Collections
>
> Resource          ../../resources/openstack/keystone_interface.robot
>
> Resource          ../../resources/openstack/nova_interface.robot
>
> Resource          ../../resources/openstack/heat_interface.robot
>
> Resource          ../../resources/ssh/files.robot
>
> Resource          packet_generator_interface.robot
>
>
>
>
>
> *** Variables ***
>
>
>
> *** Keywords ***
>
> Wait For Server
>
>     [Documentation]    Attempts to login to the passed server info and
> verify (??). Uses server info to get public ip and locate corresponding
> provate key file
>
>     [Arguments]    ${server_ip}    ${timeout}=300s
>
>     Wait Until Keyword Succeeds    ${timeout}    5 sec    Open Connection
> And Log In    ${server_ip}    root    ${GLOBAL_INJECTED_PRIVATE_KEY}
>
>     ${lines}=   Grep Local File    "Accepted publickey"
> /var/log/auth.log
>
>     Log    ${lines}
>
>     Should Not Be Empty    ${lines}
>
>
>
>
>
> ssh/files.robot
>
>
>
> *** Settings ***
>
> Documentation     Some handy Keywords for accessing log files over SSH.
> Assumptions are that logs will belong to users other than the currently
> logged in user and that sudo will be required
>
> Library           OperatingSystem
>
> Library               SSHLibrary
>
> Library           String
>
> Library           Collections
>
>
>
> *** Keywords ***
>
> Open Connection And Log In
>
>    [Documentation]    Open a connection using the passed user and SSH key.
> Connection alias will be the host name by default.
>
>    [Arguments]    ${HOST}    ${user}    ${pvt}    ${password}=
> ${alias}=${HOST}    ${timeout}=120s
>
>    Open Connection    ${HOST}    alias=${alias}    timeout=${timeout}
>
>    Login With Public Key    ${user}    ${pvt}    password=${password}
> delay=0.5 seconds
>
>
>
>
>
>
> http://robotframework.org/SSHLibrary/SSHLibrary.html#Login%20With%20Public%20Key
>
>
>
> ${pvt} is the path to the OpenSSH keyfile.
>
>
>
> *From:* [email protected] <[email protected]> *On
> Behalf Of *Vivekanandan Muthukrishnan
> *Sent:* Thursday, December 3, 2020 12:41 PM
> *To:* [email protected]
> *Subject:* [onap-discuss] Robot vFW instantiation fails with SSH private
> key access issue
>
>
>
> Hi Robot team,
>
>
>
> Robot vFW instantiation fails however we can see that VNFs just came up
> fine and it  is up and running in Openstack. We are using Elalto release.
>
>
>
> It seems like Robot scripts are not able to load the SSH private key to
> validate the vFW VNF SSH connection.
>
>
>
> We did try to copy the private key file into the following folder in the
> Robot pod but the same issue persists.
>
>
>
> */var/opt/ONAP/robot/assets/keys/onap_dev.pvt*
>
> */var/opt/ONAP/robot/assets/keys/id_rsa*
>
>
>
> Below is the log snippet for your reference. We will appreciate any
> workaround to resolve this issue.
>
>
>
> Thanks & Regards
>
> Vivek
>
>
>
> ./demo-k8s.sh onap instantiateVFW
> Number of parameters:
> 2
> KEY:
> instantiateVFW
> ++ kubectl --namespace onap get pods
> ++ sed 's/ .*//'
> ++ grep robot
> + POD=dev-robot-robot-6d444f4cdd-nr7hw
> ++ dirname ./demo-k8s.sh
> + DIR=.
> + SCRIPTDIR=scripts/demoscript
> + ETEHOME=/var/opt/ONAP
> + '[' ']'
> ++ kubectl --namespace onap exec dev-robot-robot-6d444f4cdd-nr7hw -- bash
> -c 'ls -1q /share/logs/ | wc -l'
> + export GLOBAL_BUILD_NUMBER=9
> + GLOBAL_BUILD_NUMBER=9
> ++ printf %04d 9
> + OUTPUT_FOLDER=0009_demo_instantiateVFW
> + DISPLAY_NUM=99
> + VARIABLEFILES='-V /share/config/robot_properties.py'
> + kubectl --namespace onap exec dev-robot-robot-6d444f4cdd-nr7hw --
> /var/opt/ONAP/runTags.sh -V /share/config/robot_properties.py -v
> GLOBAL_BUILD_NUMBER:642 -d /share/logs/0009_demo_instantiateVFW -i
> instantiateVFW --display 99
> Starting Xvfb on display :99 with res 1280x1024x24
> Executing robot tests at log level TRACE
>
> ==============================================================================
> Testsuites
>
> ==============================================================================
> Testsuites.Demo :: Executes the VNF Orchestration Test cases including
> setu...
>
> ==============================================================================
> Instantiate VFW
> Submitting vf module instance Vfmodule_Ete_vFW_566838b6_0 in VID
> | FAIL |
> *Keyword 'Open Connection And Log In' failed after retrying for 5 minutes.
> The last error was: Given key file '' does not exist.*
>
> ------------------------------------------------------------------------------
> Testsuites.Demo :: Executes the VNF Orchestration Test cases inclu... |
> FAIL |
> 1 critical test, 0 passed, 1 failed
> 1 test total, 0 passed, 1 failed
>
> ==============================================================================
> Testsuites                                                            |
> FAIL |
> 1 critical test, 0 passed, 1 failed
> 1 test total, 0 passed, 1 failed
>
> ==============================================================================
> Output:  /share/logs/0009_demo_instantiateVFW/output.xml
> Log:     /share/logs/0009_demo_instantiateVFW/log.html
> Report:  /share/logs/0009_demo_instantiateVFW/report.html
>
> 
>


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#22572): https://lists.onap.org/g/onap-discuss/message/22572
Mute This Topic: https://lists.onap.org/mt/78690062/21656
Group Owner: [email protected]
Unsubscribe: https://lists.onap.org/g/onap-discuss/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to