Install phpVirtualBox on CentOS 7.x

I have to say, I have been bursting with some excitement to recently discover this gem. phpVirtualBox is going to make a great addition to my server by allowing me to create and manage VirtualBox VM’s direct from my web browser. So just a small guide, sticking with the theme, on getting phpVirtualBox installed and running on CentOS 7.x.

Install required packages

Install Apache Web Server

# sudo yum install httpd

Start Apache and ensure it starts automatically on boot.

# sudo systemctl start httpd
# sudo systemctl enable httpd

Finally, add an exception in the firewall so that you can access Apache over HTTP and HTTPS.

# sudo firewall-cmd --zone=public --add-service=http
# sudo firewall-cmd --zone=public --permanent --add-service=http
# sudo firewall-cmd --zone=public --add-service=https
# sudo firewall-cmd --zone=public --permanent --add-service=https

Test that Apache is running and accessible by opening a browser and navigating to http://server_ip_address.

Install PHP

# sudo yum install php php-gd php-common php-soap

Restart Apache.

# sudo systemctl restart httpd

Test that PHP is working by creating a PHP test file that will display the PHP information page (watch out for the quotes if copy/pasting).

# sudo echo "<?php phpinfo(); ?>" > /var/www/html/test.php

Verify that the PHP information page loads by opening a browser and navigating to http://server_ip_address/test.php. Read more “Install phpVirtualBox on CentOS 7.x”