Project

General

Profile

Feature #10840

VirtualBox - vboxwebsrv missing

Added by Philip Kime almost 2 years ago. Updated almost 2 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
OI-Userland
Target version:
Start date:
2019-04-21
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

Using the latest VBox 6.04 package on 2019-04. The web service (vboxwebsrv) seems to be missing and so PhPVirtualBox won't work. Also, remote access to VM consoles on their configured ports doesn't seem to work either?


Files

stdsoap2.cpp.patch (1.84 KB) stdsoap2.cpp.patch gSOAP 2.8 source patch Philip Kime, 2019-04-24 07:45 PM
#1

Updated by Philip Kime almost 2 years ago

The remote access is ok, that was my mistake. However, can someone comment on the absence of vboxwebsrv? This is quite a problem for phpVB users. I have tried using the binary from the Oracle dist for 6.04 but that needs two .sos which breaks all sorts of other things.

#2

Updated by Michal Nowak almost 2 years ago

VirtualBox webservice requires gSOAP, which we miss from the distrigution. I tried to package it but it tends to be not quite friendly towards distributions, so quite some hacks to gSOAP are needed. Help welcome.

#3

Updated by Philip Kime almost 2 years ago

I don't know much about openindiana packaging but I could have a look. What exactly is the issue? Is it the packaging or compiling for openindiana?

#4

Updated by Philip Kime almost 2 years ago

If it is of help, I managed to compile and "make check" the latest gSOAP (2.8) with the attached small patch to one file. The problem was getting the right arguments to "gethostbyname_r" which wasn't detected correctly. Might be something to do with the _XOPEN_SOURCE value setting (600) on my system:

The Illumos Project SunOS 5.11 illumos-555d674d5d April 2019

using gcc 6 but I haven't delved into it. Anyway, this small patch seems to work. There is one other repeated compiler warning about a redefinition but it's harmless. Since "make check" shows no problems, I hope that this is all we need ...

#5

Updated by Michal Nowak almost 2 years ago

Thanks Philip, the patch is of great help to me. With your patch (and other workarounds necessary for gSOAP to fit our build system) I am able to build gSOAP.

About the warning, I am able to silence it by a tiny patch.

Wrt make check: --enable-samples is what enables test cases, right? Currently I see following error:

libtool: link: /usr/gcc/6/bin/g++ -DWITH_OPENSSL -DWITH_GZIP -m64 -O3 -I../../../gsoap/samples/databinding -m64 -o .libs/address address-addressC.o address-address.o  -L../../../gsoap/samples/databinding ../../../gsoap/.libs/libgsoap++.so
Undefined            first referenced
 symbol                  in file
recv                                ../../../gsoap/.libs/libgsoap++.so
send                                ../../../gsoap/.libs/libgsoap++.so
__xnet_connect                      ../../../gsoap/.libs/libgsoap++.so
__xnet_sendto                       ../../../gsoap/.libs/libgsoap++.so
__xnet_socket                       ../../../gsoap/.libs/libgsoap++.so
__xnet_getsockopt                   ../../../gsoap/.libs/libgsoap++.so
accept                              ../../../gsoap/.libs/libgsoap++.so
listen                              ../../../gsoap/.libs/libgsoap++.so
getnameinfo                         ../../../gsoap/.libs/libgsoap++.so
setsockopt                          ../../../gsoap/.libs/libgsoap++.so
__xnet_getaddrinfo                  ../../../gsoap/.libs/libgsoap++.so
recvfrom                            ../../../gsoap/.libs/libgsoap++.so
freeaddrinfo                        ../../../gsoap/.libs/libgsoap++.so
__xnet_bind                         ../../../gsoap/.libs/libgsoap++.so
gai_strerror                        ../../../gsoap/.libs/libgsoap++.so
shutdown                            ../../../gsoap/.libs/libgsoap++.so
ld: fatal: symbol referencing errors. No output written to .libs/address
collect2: error: ld returned 1 exit status

It seems that some combination of -lxnet -lsocket -lnsl is missing.

#6

Updated by Michal Nowak almost 2 years ago

Michal Nowak wrote:

It seems that some combination of -lxnet -lsocket -lnsl is missing.

I fixed this one as well. I will come up with a pull request in the next couple of days.

#7

Updated by Philip Kime almost 2 years ago

Excellent, let me know if I can do anything.

#8

Updated by Michal Nowak almost 2 years ago

gSOAP 2.8.83 was published to OpenIndiana repository. I work on some fixes to the VirtualBox webservice SMF. I am able to start the webse SMF service, pointing Firefox to http://localhost:18083 gets me:

<SOAP-ENV:Envelope>
 <SOAP-ENV:Body>
  <SOAP-ENV:Fault>
   <faultcode>SOAP-ENV:Client</faultcode>
   <faultstring>HTTP GET method not implemented</faultstring>
  </SOAP-ENV:Fault>
 </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

How do I test that the webservice works correctly? Can I do some API calls via curl?

#9

Updated by Philip Kime almost 2 years ago

Hmm, not sure. However, if you have a pkg or something I can get, I could install it (or is just the vboxwebserv binary enough?) and test phpvirtualbox which uses it extensively ...

#10

Updated by Michal Nowak almost 2 years ago

  • Subject changed from VirtualBox - vboxwebsrv missing? to VirtualBox - vboxwebsrv missing
  • Category set to OI-Userland
  • Status changed from New to In Progress
  • Assignee set to Michal Nowak
  • Target version set to Hipster
  • % Done changed from 0 to 50
  • Tags deleted (needs-triage)

VirtualBox 6.0.6 with web service enabled is in the process of being published to the hipster repository. Later today update virtualbox component, restart and test with phpvirtualbox, please. This is how to start the web service via SMF: https://www.virtualbox.org/manual/UserManual.html#vboxwebsrv-solaris. Let me know should you find problems.

#11

Updated by Philip Kime almost 2 years ago

All works fine, including vboxwebsrv started by SMF. Excellent work, many thanks.

#12

Updated by Michal Nowak almost 2 years ago

  • Tracker changed from Bug to Feature
  • Status changed from In Progress to Resolved
  • % Done changed from 50 to 100

Thanks for reporting back!

Also available in: Atom PDF