GithubHelp home page GithubHelp logo

barteksz95 / phpvirtualbox Goto Github PK

View Code? Open in Web Editor NEW
55.0 12.0 15.0 5.93 MB

A web interface to manage and access Virtualbox machines.

License: Other

Shell 1.14% JavaScript 21.82% PHP 47.48% CSS 2.81% HTML 26.74% Dockerfile 0.01%

phpvirtualbox's Introduction

About

This repository is a continuation of phpVirtualBox, which is no longer supported by the official authors (last commit on thier repository was sent on Jan 27, 2021 - written on Jan 18, 2023).

Right now (from 2022), this software is updated by Bartek Sz. and various contributors (see https://github.com/BartekSz95/phpvirtualbox/graphs/contributors).

phpVirtualBox was from 2017 to 2021 maintained by Smart Guide Pty Ltd (tudor at smartguide dot com dot au) with support from various contributors.

Originally Copyright © 2010-2015 by Ian Moore (imoore76 at yahoo dot com).

FREE, WITHOUT WARRANTY:

All files of this program (phpVirtualBox) are distributed under the terms contained in the LICENSE.txt file in this folder unless otherwise specified in an individual source file. By using this software, you are agreeing to the terms contained therein. If you have not received and read the license file, or do not agree with its conditions, please cease using this software immediately and remove any copies you may have in your possession.

Requirements

  • PHP

    • >= 8.1
  • Webserver (eg. Apache HTTPD, nginx)

See supported PHP version by developers: https://www.php.net/supported-versions.php.

Older versions are not considered.

Installation from ZIP file

  1. Download ZIP file from GitHub project site: https://github.com/BartekSz95/phpvirtualbox/archive/main.zip.
  2. Unzip the ZIP file into a folder accessible by your web server.
  3. Rename config.php-example to config.php and edit as needed.

Read the wiki for more information : https://github.com/phpvirtualbox/phpvirtualbox/wiki

Post installation

Default login is (username/password): admin/admin

Please report bugs/feature requests to GitHub: https://github.com/BartekSz95/phpvirtualbox/issues

Password Recovery

Rename the file recovery.php-disabled to recovery.php, navigate to it in your web browser, and follow the instructions presented.

phpvirtualbox's People

Contributors

h6w avatar imoore76 avatar barteksz95 avatar chotaire avatar tom077 avatar adam5wu avatar stianvis avatar cesium147 avatar p-bo avatar der-eismann avatar thedisbo1125 avatar arthurfreycobraag avatar ams-tschoening avatar ashway83 avatar twingg avatar clcain avatar chrjorgensen avatar krakentyio avatar mylux avatar ti4luciano avatar mikedld avatar remcodm avatar svetlana-t avatar rozhuk-im avatar scootergrisen avatar tioigor96 avatar

Stargazers

 avatar Sandro Beni avatar Julian avatar Vinicius Ribeiro Ferreira da Silva avatar Blagovest Kambarev avatar Shaun Hoffer avatar Sophie Marie avatar Simon Sebold avatar Alexandre Santos avatar Sumer Ahmed avatar Simon Cheng avatar  avatar  avatar  avatar  avatar  avatar Milan Kragujević avatar Giovanni avatar Andrew Kambaroff avatar Valfman avatar Maravento avatar  avatar  avatar  avatar  avatar Crystal_Alchemist avatar 0ow avatar Gilang Pratama avatar Paul Rensing avatar Eric Hao avatar Jonas avatar  avatar TrasherDK avatar Tommy Wu avatar Dmitry avatar MYZ6 avatar Fábio Mendes avatar Fiberian avatar  avatar Afonso Duarte avatar hello avatar  avatar Mathieu CONAN avatar Rudimar Remontti avatar  avatar Славик NarkoHeal avatar zexilonoxiouz avatar Anatoly S. avatar PlatinumThinker avatar Antonín Skala avatar  avatar Adrian Sandu avatar Oleg Tikhomiroff avatar Ryan A Whelan avatar Ramon Fischer avatar

Watchers

Neustradamus avatar Славик NarkoHeal avatar TrasherDK avatar Antonín Skala avatar  avatar Ryan A Whelan avatar  avatar Simon Sebold avatar Anatoly S. avatar  avatar  avatar Blagovest Kambarev avatar

phpvirtualbox's Issues

Error message if system only have PHP 7 or below?

If the host machine only installed PHP 7 or below, the dialog of error message shows 500 internal error.
Is there any chance that it could show a more specific error message like "PHP failed"?
Or what files and how to achieve this If I want to do this myself?

Thanks for any advice!!

Refresh the VM list when vboxwebservice is running

Hello,

I have a setup with several servers managed by vboxwebservice (and phpvirtualbox as frontend).

All VMs on these servers are created on the same NFS share.

All the servers, have the same VM list as the others (in the same cluster).

The problem is, if I create a VM on the one of the cluster nodes, the other cluster nodes does not update their VM list until I restart vboxweb-service on the other cluster nodes.

There is a way to refresh the VM list without restarting vboxwebservice, in this setup? I have searched through the virtualbox manual and does not seem to be an answer to this.

Virtualbox 7.0-10

Thank you!

VMs with disk encryption do not start

when I try to start a VM with an encrypted disk, I get error 500.

The logged error is:

PHP Fatal error: Uncaught Error: Call to undefined method IConsole::removeDiskEncryptionPassword() in /server/vol1/wwwroot/vbox/endpoints/lib/vboxconnector.php:4404\nStack trace:\n#0 /server/vol1/wwwroot/vbox/endpoints/lib/vboxconnector.php(952): vboxconnector->remote_consoleAddDiskEncryptionPasswords()\n#1 /server/vol1/wwwroot/vbox/endpoints/api.php(316): vboxconnector->__call()\n#2 {main}\n thrown in /server/vol1/wwwroot/vbox/endpoints/lib/vboxconnector.php on line 4404

LINUX ISSUE vboxweb-service

im install virtualbox using deb files

default service
/lib/systemd/system/vboxweb-service.service

sudo mkdir -p /etc/default
sudo nano /etc/default/virtualbox

VBOXWEB_USER=remote_vbox
VBOXWEB_HOST=192.168.100.106

systemctl stop vboxweb-service.service
systemctl start vboxweb-service.service

in php virtualbox still error (after login) :

phpVirtualBox
Exception Object
(
   [message:protected] => Could not connect to host (http://192.168.100.106:18083/)
   [string:Exception:private] => 
   [code:protected] => 64
   [file:protected] => /var/www/vbox.rnd/endpoints/api.php
   [line:protected] => 134
   [trace:Exception:private] => Array
       (
       )

   [previous:Exception:private] => 
)

Remote VM access via browser

Hello. Please, tell me, is it possible to control VM via browser now?
I get "Adobe Flash Player not installed". If I install Ruffle, I just get gray square.
Please, tell me, do you have any examples how to set up such remote control?

Error 500 in Linux Gentoo

The following error is displayed when trying to load the page:

readyState: "4"
responseText: ""
status: "500"
statusText: "Internal Server Error"

Log Apache:

PHP Fatal error:  
Uncaught TypeError: Return value of VBox_Collection::current() must be an instance of mixed, instance of IGuestOSType returned in /home/www/store/virtualbox/phpvirtualbox/endpoints/lib/vboxServiceWrappers.php:156
Stack trace:
#0 /home/www/store/virtualbox/phpvirtualbox/endpoints/lib/vboxServiceWrappers.php(172): VBox_Collection->current()
#1 /home/www/store/virtualbox/phpvirtualbox/endpoints/lib/vboxconnector.php(3170): VBox_Collection->valid()
#2 /home/www/store/virtualbox/phpvirtualbox/endpoints/lib/vboxconnector.php(952): vboxconnector->remote_vboxGetGuestOSTypes()
#3 /home/www/store/virtualbox/phpvirtualbox/endpoints/api.php(316): vboxconnector->__call()
#4 {main}

So far I've been running VirtualBox 6 and the initial project running without a problem. After upgrading to version 7 and this version of phpvirutalbox I see that the errors occur.

  • Virtualbox 7.0.8a
  • Php 7.4
  • Apache 2.4.57
  • Linux Gentoo

Can not take snapshots - vboxweb-service errors with VBOX_E_INVALID_VM_STATE

Using VirtualBox 7.0.12 on Ubuntu 22.04, with RC1:

When trying to create a new snapshot, the vboxweb-service echos the following error message:
00:00:49.625848 SQW02 API method name: IMachine::TakeSnapshot
00:00:49.625855 SQW02 API return code: 0x80bb0002 (VBOX_E_INVALID_VM_STATE)
00:00:49.625861 SQW02 COM error info result code: 0x80bb0002 (VBOX_E_INVALID_VM_STATE)
00:00:49.625865 SQW02 COM error info text: Cannot take a live snapshot of a virtual machine unless it is running.

When I look at the request / response to take a snapshot, here is the request body:
{ "{\"fn\":\"snapshotTake\",\"params\":{\"vm\":\"a205117d-2e0f-4eb8-99f4-9d58263a6105\",\"name\":\"Snapshot 1\",\"description\":\"\"},\"persist\":null}": "" }

And this is the response body:
{"data":{"responseData":false,"success":false,"key":"53474945cfd7ac0bf8114767c209c2a6"},"errors":[],"persist":[],"messages":[]}

I can create snapshots using the local VirtualBox UX.

I have tried creating snapshots with the VM running and stopped, and get the same result.

Of note: Restoring, deleting, other management tasks of snapshots seem to work fine. The only problem seems to be creating a new snapshot of a VM.

It does not appear that I have any general issues with my VirtualBox install or vboxweb-service -- but happy to investigate and return any info on my install. I just upgraded from VirtualBox 6.1 / phpvirtualbox, and creating snapshots was working before my upgrade.

PHP problem in Debian 12 and PHP version 8.2.7

Hi,
I have a problem with phpvirtualbox Version 7.0 (Release Candidate 1).
When I try to login I receive "An unknown PHP error occurred. This is most likely a syntax error in config.php in phpVirtualBox's folder. The most common errors are an unclosed quote or a missing semicolon in a configuration item that has been entered (e.g. location, username, or password).
Depending on your PHP configuration, navigating directly to config.php in your web browser may display the PHP error message. ..."

My system is Debian 12, PHP version 8.2.7 and VirtualBox installd ist 7.0.10.
This version should be work with PHP 8.2, but I don't know what about 8.2.7 version.

How can I resolve it?

Regards

SOLVED_This XML file does not appear to have any style information associated with it. The document tree is shown below.

Hello friends.
When i try to pass the http://localhost:18083 link browser shows me:
2023-11-03_10-53

if I try to pass http://localhost/phpvirtualbox/ i see: An unknown PHP error occurred. This is most likely a syntax error in config.php in phpVirtualBox's folder.
xxx

with the apache is the same.

I am runing Arch Linux OS
PHP - 8.2.12
VirtualBox - 7.0.12 r159484

I tried diferent methods but nothing doesn't work. What can I do to solve it? Installed modules php82-xml and php-xmlrpc but this not worked for me.

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:vbox="http://www.virtualbox.org/"> <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>

PHP fatal error when attempting to open folders (e.g. to add existing VM)

I get the following php error when attempting to open folders when trying to open a folder in phpvirtualbox:

[Mon Jan 29 20:41:00.393871 2024] [php:error] [pid 29825] [client xxxxxxx ] PHP Fatal error: Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in /var/www/html/phpvbox/endpoints/jqueryFileTree.php:256\nStack trace:\n#0 /var/www/html/phpvbox/endpoints/jqueryFileTree.php(203): getdir()\n#1 {main}\n thrown in /var/www/html/phpvbox/endpoints/jqueryFileTree.php on line 256, referer: http://xxxx/phpvbox/

Internal server error with vbox 7.0.14

I'm trying to upgrade to vbox 7 and when I run the home page a get an internal server error:

readyState: "4"
responseText: ""
status: "500"
statusText: "Internal Server Error"

from the logs:

PHP Fatal error: Uncaught TypeError: Return value of VBox_Collection::current() must be an instance of mixed, instance of IMediumFormat returned in /usr/local/share/vbox-BartekSz95/endpoints/lib/vboxServiceWrappers.php:156
Stack trace:
#0 /usr/local/share/vbox-BartekSz95/endpoints/lib/vboxServiceWrappers.php(172): VBox_Collection->current()
#1 /usr/local/share/vbox-BartekSz95/endpoints/lib/vboxconnector.php(5565): VBox_Collection->valid()
#2 /usr/local/share/vbox-BartekSz95/endpoints/lib/vboxconnector.php

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.