Koozali.org: home of the SME Server

phpvirtualbox-5.0 and VirtualBox-5.0

Online stephdl

  • *
  • 1,519
  • +0/-0
    • Linux et Geekeries
phpvirtualbox-5.0 and VirtualBox-5.0
« on: August 08, 2015, 02:40:49 PM »
new update of my contrib smeserver-phpvirtualbox, due to the politic of oracle, VirtualBox-5.0 doesn't obsolete Virtualbox-4.3, therefore you have to remove first the old rpm (think to pause your VM )

http://wiki.contribs.org/Phpvirtualbox#Installation_phpvirtualbox-5.0_For_SME8_and_SME9

as a side note, it is a huge work that ian moore has done for this update, I think that the development has started again :)
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline DanB35

  • ****
  • 764
  • +0/-0
    • http://www.familybrown.org
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #1 on: August 17, 2015, 05:37:05 PM »
Following the instructions in the Wiki, the install went smoothly.  However, after a reboot, I'm having trouble accessing the phpvb web GUI.  When I browse to that page, I get the following error in a dialog box:

"An error occurred communicating with your vboxwebsrv.  No more requests will be sent by phpVirtualBox until the error is corrected and this page is refreshed.  The details of this connection error should be displayed in a subsequent dialog box."

When I click the OK button on that dialog, I get another saying, "Could not connect to host (http://127.0.0.1:18083/", with a link for Details.  When I click that link, I get the following:

Code: [Select]
Exception Object
(
    [message:protected] => Could not connect to host (http://127.0.0.1:18083/)
    [string:Exception:private] =>
    [code:protected] => 64
    [file:protected] => /opt/phpvirtualbox/endpoints/lib/vboxconnector.php
    [line:protected] => 220
    [trace:Exception:private] => Array
        (
            [0] => Array
                (
                    [file] => /opt/phpvirtualbox/endpoints/lib/vboxconnector.php
                    [line] => 5266
                    [function] => connect
                    [class] => vboxconnector
                    [type] => ->
                    [args] => Array
                        (
                        )

                )

            [1] => Array
                (
                    [file] => /opt/phpvirtualbox/endpoints/lib/vboxconnector.php
                    [line] => 951
                    [function] => remote_vboxRecentMediaGet
                    [class] => vboxconnector
                    [type] => ->
                    [args] => Array
                        (
                            [0] =>
                        )

                )

            [2] => Array
                (
                    [file] => /opt/phpvirtualbox/endpoints/api.php
                    [line] => 316
                    [function] => __call
                    [class] => vboxconnector
                    [type] => ->
                    [args] => Array
                        (
                            [0] => vboxRecentMediaGet
                            [1] => Array
                                (
                                    [0] =>
                                    [1] => Array
                                        (
                                            [0] => Array
                                                (
                                                    [data] => Array
                                                        (
                                                            [responseData] => Array
                                                                (
                                                                )

                                                        )

                                                    [errors] => Array
                                                        (
                                                        )

                                                    [persist] => Array
                                                        (
                                                        )

                                                    [messages] => Array
                                                        (
                                                        )

                                                )

                                        )

                                )

                        )

                )

            [3] => Array
                (
                    [file] => /opt/phpvirtualbox/endpoints/api.php
                    [line] => 316
                    [function] => vboxRecentMediaGet
                    [class] => vboxconnector
                    [type] => ->
                    [args] => Array
                        (
                            [0] =>
                            [1] => Array
                                (
                                    [0] => Array
                                        (
                                            [data] => Array
                                                (
                                                    [responseData] => Array
                                                        (
                                                        )

                                                )

                                            [errors] => Array
                                                (
                                                )

                                            [persist] => Array
                                                (
                                                )

                                            [messages] => Array
                                                (
                                                )

                                        )

                                )

                        )

                )

        )

    [previous:Exception:private] =>
)


Location:http://127.0.0.1:18083/

/var/log/messages contains the following warning, which may or may not be relevant:
"Aug 17 11:27:55 e-smith httpd: PHP Warning:  file_get_contents(/opt/phpvirtualbox/languages/en.xml) [<a href='function.file-get-contents'>function.file-get-contents</a>]: failed to open stream: No such file or directory in /opt/phpvirtualbox/endpoints/lib/language.php on line 73"

There is no en.xml file in /opt/phpvirtualbox/languages:
Code: [Select]
[root@e-smith ~]# ll /opt/phpvirtualbox/languages/
total 144
-rw-r--r-- 1 root root 8908 Aug  8 08:27 de.xml
-rw-r--r-- 1 root root 8804 Aug  8 08:27 es.xml
-rw-r--r-- 1 root root 9059 Aug  8 08:27 fr.xml
-rw-r--r-- 1 root root 8819 Aug  8 08:27 it.xml
-rw-r--r-- 1 root root 8989 Aug  8 08:27 ja.xml
-rw-r--r-- 1 root root 8365 Aug  8 08:27 languages.txt
-rw-r--r-- 1 root root 8801 Aug  8 08:27 pl.xml
-rw-r--r-- 1 root root 8761 Aug  8 08:27 pt_br.xml
-rw-r--r-- 1 root root 8739 Aug  8 08:27 ro.xml
-rw-r--r-- 1 root root 9832 Aug  8 08:27 ru.xml
drwxr-xr-x 2 root root 4096 Aug 14 09:07 source
-rw-r--r-- 1 root root 8198 Aug  8 08:27 zh_cn.xml
-rw-r--r-- 1 root root 8145 Aug  8 08:27 zh_tw.xml

......

Online stephdl

  • *
  • 1,519
  • +0/-0
    • Linux et Geekeries
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #2 on: August 17, 2015, 08:25:59 PM »
Which version of phpvirtualbox, virtualbox, smeserver-virtualbox and smeserver-phpvirtualbox, do you have installed ?

rpm -qa |grep -i virtualbox
« Last Edit: August 17, 2015, 08:29:10 PM by stephdl »
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline DanB35

  • ****
  • 764
  • +0/-0
    • http://www.familybrown.org
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #3 on: August 17, 2015, 08:28:30 PM »
Code: [Select]
[dan@e-smith phpvirtualbox]$ rpm -qa | grep virtualbox
smeserver-phpvirtualbox-5.0-5.0.0-1.el6.sme.noarch
smeserver-virtualbox-5.0-5.0.0-2.el6.sme.noarch
phpvirtualbox-5.0-5.0.1-1.el6.sme.noarch
[dan@e-smith phpvirtualbox]$ rpm -qa | grep VirtualBox
VirtualBox-5.0-5.0.2_102096_el6-1.x86_64
......

Online stephdl

  • *
  • 1,519
  • +0/-0
    • Linux et Geekeries
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #4 on: August 17, 2015, 08:30:20 PM »
Upgrade phpvirtualbox please
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline DanB35

  • ****
  • 764
  • +0/-0
    • http://www.familybrown.org
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #5 on: August 17, 2015, 08:32:53 PM »
Code: [Select]
[root@e-smith ~]# yum --enablerepo=stephdl update phpvirtualbox
Loaded plugins: changelog, fastestmirror, smeserver
Setting up Update Process
Loading mirror speeds from cached hostfile
 * base: distro.ibiblio.org
 * smeaddons: mirror.canada.pialasse.com
 * smeextras: mirror.canada.pialasse.com
 * smeos: mirror.canada.pialasse.com
 * smeupdates: mirror.canada.pialasse.com
 * updates: mirror.oss.ou.edu
Package(s) phpvirtualbox available, but not installed.
No Packages marked for Update
[root@e-smith ~]#
......

Online stephdl

  • *
  • 1,519
  • +0/-0
    • Linux et Geekeries
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #6 on: August 17, 2015, 08:41:28 PM »
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline DanB35

  • ****
  • 764
  • +0/-0
    • http://www.familybrown.org
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #7 on: August 17, 2015, 10:39:15 PM »
That seems to have solved it, thanks!
......

Online stephdl

  • *
  • 1,519
  • +0/-0
    • Linux et Geekeries
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #8 on: August 17, 2015, 10:41:32 PM »
You are welcome
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline sages

  • *
  • 182
  • +0/-0
    • http://www.sages.com.au
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #9 on: August 18, 2015, 10:24:59 AM »
needed to add the -5.0 to the end of the command to get it to work.

yum --enablerepo=stephdl update phpvirtualbox-5.0
...

Online stephdl

  • *
  • 1,519
  • +0/-0
    • Linux et Geekeries
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #10 on: August 18, 2015, 11:12:00 AM »
Yes....the fault goes to virtualbox team. Each major version of virtualbox gets its own branch.....and you must manually remove the old branch.

It is a pain ;)

One day i will use proxmox....or directly quemu/kvm....
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline Xavier.A

  • ***
  • 104
  • +0/-0
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #11 on: August 18, 2015, 02:57:08 PM »
One day i will use proxmox....or directly quemu/kvm....
maybe a good idea  :lol:
“When the wise man points to the moon, the fool looks at the finger.”

Offline Stefano

  • *
  • 10,836
  • +2/-0
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #12 on: August 18, 2015, 03:28:14 PM »
Yes....the fault goes to virtualbox team. Each major version of virtualbox gets its own branch.....and you must manually remove the old branch.

it's not a "fault" but (IMVHO) a good decision..
the same made by RH to not change to/upgrade to major version of main daemons/programs during a OS release lifetime.. as you know, during al the support life of, let's say, Centos5, apache, mysql and so on will never be upgraded to a newer major release.. and this is done for stability and reliability reasons.

VB's guys made the same decision.. you can't upgrade/overwrite a old version to/with the newer one accidentally (via a yum update, for example), breaking your server.. if you really want to upgrade, you have to do it consciously.. :)

BTW, VB behaves in the same way in windows too.. IMVHO, Redmond's guys should learn something..
« Last Edit: August 18, 2015, 03:34:19 PM by Stefano »

Offline DanB35

  • ****
  • 764
  • +0/-0
    • http://www.familybrown.org
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #13 on: August 26, 2015, 04:45:11 PM »
Well, I thought it was fixed, but after some other system updates were installed, had to do a post-upgrade;reboot.  On reboot, I'm back where I was.

When I go to the phpvb page on my server, I get the same warning dialog I had before.  When I click OK, I get the same "could not connect to host" dialog as before.  When I click the Details link, I get this:

Code: [Select]
Exception Object
(
    [message:protected] => Could not connect to host (http://127.0.0.1:18083/)
    [string:Exception:private] =>
    [code:protected] => 64
    [file:protected] => /opt/phpvirtualbox/endpoints/lib/vboxconnector.php
    [line:protected] => 220
    [trace:Exception:private] => Array
        (
            [0] => Array
                (
                    [file] => /opt/phpvirtualbox/endpoints/lib/vboxconnector.php
                    [line] => 3147
                    [function] => connect
                    [class] => vboxconnector
                    [type] => ->
                    [args] => Array
                        (
                        )

                )

            [1] => Array
                (
                    [file] => /opt/phpvirtualbox/endpoints/lib/vboxconnector.php
                    [line] => 951
                    [function] => remote_vboxGetGuestOSTypes
                    [class] => vboxconnector
                    [type] => ->
                    [args] => Array
                        (
                            [0] =>
                        )

                )

            [2] => Array
                (
                    [file] => /opt/phpvirtualbox/endpoints/api.php
                    [line] => 316
                    [function] => __call
                    [class] => vboxconnector
                    [type] => ->
                    [args] => Array
                        (
                            [0] => vboxGetGuestOSTypes
                            [1] => Array
                                (
                                    [0] =>
                                    [1] => Array
                                        (
                                            [0] => Array
                                                (
                                                    [data] => Array
                                                        (
                                                            [responseData] => Array
                                                                (
                                                                )

                                                        )

                                                    [errors] => Array
                                                        (
                                                        )

                                                    [persist] => Array
                                                        (
                                                        )

                                                    [messages] => Array
                                                        (
                                                        )

                                                )

                                        )

                                )

                        )

                )

            [3] => Array
                (
                    [file] => /opt/phpvirtualbox/endpoints/api.php
                    [line] => 316
                    [function] => vboxGetGuestOSTypes
                    [class] => vboxconnector
                    [type] => ->
                    [args] => Array
                        (
                            [0] =>
                            [1] => Array
                                (
                                    [0] => Array
                                        (
                                            [data] => Array
                                                (
                                                    [responseData] => Array
                                                        (
                                                        )

                                                )

                                            [errors] => Array
                                                (
                                                )

                                            [persist] => Array
                                                (
                                                )

                                            [messages] => Array
                                                (
                                                )

                                        )

                                )

                        )

                )

        )

    [previous:Exception:private] =>
)


Location:http://127.0.0.1:18083/

Code: [Select]
[dan@e-smith ~]$ rpm -qa | grep -i virtualbox
VirtualBox-5.0-5.0.2_102096_el6-1.x86_64
smeserver-phpvirtualbox-5.0-5.0.0-1.el6.sme.noarch
smeserver-virtualbox-5.0-5.0.0-2.el6.sme.noarch
phpvirtualbox-5.0-5.0.2-1.el6.sme.noarch
......

Online stephdl

  • *
  • 1,519
  • +0/-0
    • Linux et Geekeries
Re: phpvirtualbox-5.0 and VirtualBox-5.0
« Reply #14 on: August 26, 2015, 06:16:20 PM »
what is the output of

/etc/init.d/vboxdrv setup; /etc/init.d/vboxweb-service start
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!