Debugging Bluval

Here are some ways to debug Bluval.

Blucon.sh

Blucon.sh builds and runs a Docker container that runs the Bluval tests. This uses the Docker builder pattern, in which it creates a container inside a container. The container sometimes has DNS problems which can be tested simply by running a Ubuntu container and testing that it can access the outside world.

The root cause for this may be found from iptables.


ssh access

The tests can fail if there is no ssh access to the system under test, so one has to check what is the reason for the failure. Bluval uses the Robot Framework SSH Client library which in turn uses the Python paramiko library. Paramiko has sometimes problems with the configured keys. The following can be tried:

  • Create new keys with ssh-keygen
  • Check if ssh-agent is running, it can confuse paramiko
  • Check what is in ~/.ssh/config. It could define what are allowable algorithms which could then confuse paramiko
  • Turn on debugging in Vuls. In Robot this is " Set Default Configuration loglevel=DEBUG"


Bluval Troubleshooting

## Debug
$ sudo docker run -i -t ubuntu:14.04 /bin/bash
# apt-get update
docker rmi -f $(docker image ls -a -q)

apt-get purge docker-* -y --allow-change-held-packages

reinstall docker

then run the bluval

Workaround steps:
We have tried some workaround inorder to solve ssh-connectivity issue between os container and arm-VM

We have tried to debug
By entering into the container akraino/validation:os-latest using below cmd
$ docker run --rm -it \
-v /root/demo/validation:/opt/akraino/validation \
-v/root/demo/validation/results:/opt/akraino/results \
-v /root/.ssh:/root/.ssh \
akraino/validation:os-latest /bin/sh

$ pip3 install -r /opt/akraino/validation/bluval/requirements.txt
$ sudo apt install openssh-client
$ sudo apt install openssh-server

We have enabled passwordless authentication from container to host VM
$ ssh-copy-id root@<ip_VM>
From Bart to Everyone: 10:18 AM
Then Run the below command from the VM_arm_node to run bluval
$ sudo ./bluval/blucon.sh -l os <BP_name>

source /etc/os-release && echo $ID


Referred BluVal Architecture and Concept Link:
https://wiki.akraino.org/display/AK/Bluval+User+Guide#BluvalUserGuide-devenv

  • No labels