[VAL-5] Test OPNFV Functest for Kubernetes testing Created: 07/Mar/19  Updated: 10/Apr/19  Resolved: 10/Apr/19

Status: Done
Project: Validation
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Medium
Reporter: Tapio Tallgren Assignee: Cristina Pauna
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: Text File functest-k8s.log     Text File functest_k8s_x86.txt    

 Description   

Run OPNFV Functest-kubernetes against an IEC deployment for both x86 and aarch64.



 Comments   
Comment by Cristina Pauna [ 19/Mar/19 ]

ns156u Not sure what the genesis node is, we usually run functest from a jumpserver (a server from which k8s is installed, separate from the cluster itself).

I ran the test also from the k8s master today and the test passed.

{{ubuntu@iec01:~$ cat k8.creds }}
export KUBERNETES_PROVIDER=local
export KUBE_MASTER_URL=https://127.0.0.1:6443
export KUBE_MASTER_IP=127.0.0.1

In your case it seems connection to https://127.0.0.1:6553/api/v1 is denied to localhost. What is the output of the command below?

wget https://127.0.0.1:6553/api/v1 --no-check-certificate

 

Comment by Naga Sugguna [ 15/Mar/19 ]

I am running it form genesis node.

Comment by Naga Sugguna [ 15/Mar/19 ]

Mar 15 05:28:25.275: INFO: >>> kubeConfig: /root/.kube/config
Mar 15 05:28:25.278: INFO: Waiting up to 30m0s for all (but 0) nodes to be schedulable
Mar 15 05:28:25.278: INFO: Unexpected error listing nodes: Get https://127.0.0.1:6553/api/v1/nodes?fieldSelector=spec.unschedulable%3Dfalse&resourceVersion=0: dial tcp 127.0.0.1:6553: connect: connection refused
Mar 15 05:28:25.278: INFO: Unexpected error occurred: Get https://127.0.0.1:6553/api/v1/nodes?fieldSelector=spec.unschedulable%3Dfalse&resourceVersion=0: dial tcp 127.0.0.1:6553: connect: connection refused
Failure [0.003 seconds]
[BeforeSuite] BeforeSuite
_output/local/go/src/k8s.io/kubernetes/test/e2e/e2e.go:70

Unexpected error:
<*url.Error | 0xc001e85260>: {
Op: "Get",
URL: "https://127.0.0.1:6553/api/v1/nodes?fieldSelector=spec.unschedulable%3Dfalse&resourceVersion=0",
Err: {
Op: "dial",
Net: "tcp",
Source: nil,
Addr:

{ IP: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 127, 0, 0, 1], Port: 6553, Zone: "", }

,
Err:

{Syscall: "connect", Err: 0x6f}

,
},
}
Get https://127.0.0.1:6553/api/v1/nodes?fieldSelector=spec.unschedulable%3Dfalse&resourceVersion=0: dial tcp 127.0.0.1:6553: connect: connection refused
occurred

_output/local/go/src/k8s.io/kubernetes/test/e2e/e2e.go:104
------------------------------
Mar 15 05:28:25.279: INFO: Running AfterSuite actions on all nodes
Mar 15 05:28:25.279: INFO: Running AfterSuite actions on node 1
Mar 15 05:28:25.279: INFO: Dumping logs locally to: /home/opnfv/functest/results/k8s_smoke
Mar 15 05:28:25.279: INFO: Error running cluster/log-dump/log-dump.sh: fork/exec ../../cluster/log-dump/log-dump.sh: no such file or directory

Ran 1 of 0 Specs in 0.004 seconds
FAIL! – 0 Passed | 1 Failed | 0 Pending | 0 Skipped — FAIL: TestE2E (0.11s)

Comment by Jingzhao Ni [ 14/Mar/19 ]

Ran the opnfv/functest-kubernetes-healthcheck:latest image against an arm64 k8s deploy.

The environmental-setting is same as x86 platform's. You can directly reference the x86 configurations. And the default.log is attached functest-k8s.log.

On the other hand, when deploying the functest-kubernetes-healthcheck, i found that the status of coredns pod in kube-system namespace is crashed. It caused by host dns configuration. And i will updated the automatic scripts in future.

Comment by Juha Kosonen [ 14/Mar/19 ]

In this case results were attempted to push to database because option '-r' (report) was set in execution command:

run_tests -r -t all

 

 

$ run_tests --help
usage: run_tests [-h] [-t TEST] [-n] [-r]
optional arguments:
 -h, --help show this help message and exit
 -t TEST, --test TEST Test case or tier (group of tests) to be executed. It
 will run all the test if not specified.
 -n, --noclean Do not clean OpenStack resources after running each
 test (default=false).
 -r, --report Push results to database (default=false).
$

 

Comment by Cristina Pauna [ 13/Mar/19 ]

Ran the opnfv/functest-kubernetes-healthcheck:latest image against an x86 k8s deploy. The image can be used as is, with some prerequisites:

  • copy admin.conf file in jenkins home (for the parameter -v /home/jenkins/admin.conf:/root/.kube/config)
  • create k8.creds (for the parameter -v /home/jenkins/k8.creds:/home/opnfv/functest/conf/env_file)
    • $ cat /home/jenkins/k8.creds
      export KUBERNETES_PROVIDER=local
      export KUBE_MASTER_URL=https://172.16.10.36:6443
      export KUBE_MASTER_IP=172.16.10.36

Start the tests from the jumpserver:

docker run -e DEPLOY_SCENARIO=k8-nosdn-nofeature-noha -v /home/jenkins/k8.creds:/home/opnfv/functest/conf/env_file -v /home/jenkins/opnfv/functest/results/master:/home/opnfv/functest/results -v /home/jenkins/admin.conf:/root/.kube/config opnfv/functest-kubernetes-healthcheck:latest /bin/bash -c 'run_tests -r -t all'

 

One additional note, the tests try to push the results to http://testresults.opnfv.org/test/api/v1/results by default. Log of the run is attached.

Generated at Sat Feb 10 06:06:33 UTC 2024 using Jira 9.4.5#940005-sha1:e3094934eac4fd8653cf39da58f39364fb9cc7c1.