Hi,
Great repository and tutorial on your blog. I have a problem. I would like to use VirtualBox VMs on the same GCP machine and to use VirtualBox VMs remotely on my GNS3 GUI. I followed https://docs.gns3.com/1f6uXq05vukccKdMCHhdki5MXFhV8vcwuGwiRvXMQvM0/index.html to modify /etc/gns3/gns3_server.conf
installed through your playbook. I added, for example:
vboxmanage_path = /usr/bin/VboxManage
vbox_user = root
Issue was firstly detected with GNS3 GUI. It didn't list the VMs under remote server when I tried to add VirtualBox VMs in Preferences. Then I started to debug gns3server API myself to see where the problem is.
Indeed, executing curl -X GET -H 'User-Agent: Python/3.6 aiohttp/2.3.10' -v -i 'http://loca lhost:3080/v2/compute/virtualbox/vms'
on server node locally returns an empty JSON array []
. However, log file (path /var/log/gns3/gns3.log
) has these lines:
2019-02-23 13:01:05 INFO __init__.py:112 Executing VBoxManage with command: /usr/bin/VBoxManage --nologo list vms
2019-02-23 13:01:05 INFO helpers.py:534 127.0.0.1 [23/Feb/2019:13:01:05 +0000] "GET /v2/compute/virtualbox/vms HTTP
/1.1" 200 197 "-" "Python/3.6 aiohttp/2.3.10"
(root, my user and gns3 are added to vboxusers
)
I tried different combinations of the listed shell command under my user logged from GCP (login based on email), root
user and gns3
. I have also added gns3
to sudoers, but I needed to set new password. From executing command in shell everything seems to be ok:
$ sudo vboxmanage list vms
"alpine" {ef848483-ad64-42ca-8ee0-587b8ce5f24a}
$ sudo su - root
$ sudo vboxmanage list vms
"alpine" {ef848483-ad64-42ca-8ee0-587b8ce5f24a}
$ sudo su - gns3
$ sudo vboxmanage list vms
"alpine" {ef848483-ad64-42ca-8ee0-587b8ce5f24a}
Maybe my configurations are bad and I would like to kindly ask you to evaluate my question. Another option is bug in gns3server so I created issue on their GitHub.
Best regards
JB