Home
Help
Search
Login
Register
OPNsense Forum
»
Archive
»
15.1 Legacy Series
»
Installing X and virtualbox
« previous
next »
Print
Pages: [
1
]
Author
Topic: Installing X and virtualbox (Read 42059 times)
cdburgess75
Newbie
Posts: 46
Karma: 8
Installing X and virtualbox
«
on:
June 25, 2015, 09:33:09 pm »
Thanks for the help on the repos: Here is a quick dirty virtual box with a vncserver to manage ---this install works on version: OPNsense 15.1.12-amd64 (don't forget to allow ports for vnc:5001) **This is not complete but close, any suggestions would be helpful.
1. change repo:
goto /usr/local/etc/pkg/repo/FreeBSD.conf and change the value "no" to "yes"
2. install pkg:
pkg update -f
pkg install -fy xorg
pkg install -fy mate-desktop
pkg install -fy mate
pkg install -fy slim
pkg install -fy virtualbox-ose
pkg install -fy virtualbox-ose-additions
pkg install -fy vboxtool
pkg install -fy tightvnc
3.file changes:
cp -p /etc/rc.conf /etc/rc.conf-old
cp -p /etc/rc.conf /root
echo 'apache24_enable="YES"' >> /etc/rc.conf
echo 'mysql_enable="YES"' >> /etc/rc.conf
echo 'dbus_enable="YES"' >> /etc/rc.conf
echo 'hald_enable="YES"' >> /etc/rc.conf
echo 'slim_enable="YES"' >> /etc/rc.conf
echo 'vboxguest_enable="YES"' >> /etc/rc.conf
echo 'vbox_service="YES"' >> /etc/rc.conf
echo 'vboxnet_enable="YES"' >> /etc/rc.conf
echo 'vboxservice_flags="--disable-timesync"' >> /etc/rc.conf
echo 'vboxheadless_enable=“YES"' >> /etc/rc.conf
cp -p /boot/loader.conf /boot/loader.conf-old
cp -p /boot/loader.conf /root
echo "kldload vboxdrv" >> /boot/loader.conf
echo "kldload vboxguest" >> /boot/loader.conf
echo "kldload vboxnetflt" >> /boot/loader.conf
echo "kldload vboxnetadp" >> /boot/loader.conf
echo "exec ck-launch-session mate-session" > /root/.xinitrc
4. Allow ports for vnc:5001 in firewall Rules section
run: "vncserver" to set password
login: with a vnc client and run "VirtualBox &" from command line in X windows
Logged
weust
Hero Member
Posts: 650
Karma: 57
Re: Installing X and virtualbox
«
Reply #1 on:
June 25, 2015, 10:58:12 pm »
So you converted a firewall/router into a desktop?
Logged
Hobbyist at home, sysadmin at work. Sometimes the first is mixed with the second.
franco
Administrator
Hero Member
Posts: 17656
Karma: 1610
Re: Installing X and virtualbox
«
Reply #2 on:
June 26, 2015, 07:22:19 am »
I really don't recommend pulling in X11 without building your own packages on top of our ports tree. We turn it off to keep the system slim, and this turning off will have bad side effects with packages from FreeBSD that have it turned on. Any pkg-upgrade can potentially destroy your OPNsense system. Use with great care.
Logged
cdburgess75
Newbie
Posts: 46
Karma: 8
Re: Installing X and virtualbox
«
Reply #3 on:
June 29, 2015, 10:17:35 pm »
Thanks for the heads up. I truly did not want to install X, however I could not get vbox working in headless mode. But headless mode is the goal, and that will be all CLI. I will continue to work toward this and keep the post updated. The point of this is to host (hypervisor) some applications (vm's for spam filters/etc) for small businesses. Definitely not a desktop weust
Logged
weust
Hero Member
Posts: 650
Karma: 57
Re: Installing X and virtualbox
«
Reply #4 on:
June 29, 2015, 10:28:22 pm »
If you're installing X on a firewall you might as well be calling it a desktop.
You're headless part doesn't make any sense at all.
Detach a VM and it's headless.
Logged
Hobbyist at home, sysadmin at work. Sometimes the first is mixed with the second.
cdburgess75
Newbie
Posts: 46
Karma: 8
Re: Installing X and virtualbox
«
Reply #5 on:
June 29, 2015, 10:48:02 pm »
weust,
While any VM started from the VirtualBox Manager is capable of running virtual machines remotely, it is not convenient to have to run the full-fledged GUI if you never want to have VMs displayed locally in the first place. In particular, if you are running server hardware whose only purpose is to host VMs, and all your VMs are supposed to run remotely over VRDP, then it is pointless to have a graphical user interface on the server at all -- especially since, on a Linux/BSD/Solaris host, the VirtualBox manager comes with dependencies on the Qt and SDL libraries. This is inconvenient if you would rather not have the X Window system on your server at all.
VirtualBox therefore comes with yet another front-end called VBoxHeadless, which produces no visible output on the host at all, but instead only delivers VRDP data. This front-end has no dependencies on the X Window system on Linux/BSD/Solaris hosts.
You can call it whatever you like weust. This firewall not in production dude, relax!
Logged
weust
Hero Member
Posts: 650
Karma: 57
Re: Installing X and virtualbox
«
Reply #6 on:
June 29, 2015, 10:55:57 pm »
I am relaxed. Messing with your head does that
The way you describe virtual box sounds like it's a pile of crap which you can even remotely manage.
Logged
Hobbyist at home, sysadmin at work. Sometimes the first is mixed with the second.
franco
Administrator
Hero Member
Posts: 17656
Karma: 1610
Re: Installing X and virtualbox
«
Reply #7 on:
June 29, 2015, 11:16:17 pm »
Guys, keep it cool.
Logged
cdburgess75
Newbie
Posts: 46
Karma: 8
Re: Installing X and virtualbox
«
Reply #8 on:
June 30, 2015, 01:52:37 am »
I copied from their documentation. Tell me about it though! I can't really find another hypervisor on FreeBSD that I am comfortable with yet. Virtualbox works though, it's simple to use. I don't use it for production systems though. I have been watching bhyve progress and it looks promising. But that's beyond the scope of this. My goal is to run a hypervisor on CLI only (no X). Just jumping through the hoops of learning. Stop messing with me, I'm delicate
Logged
franco
Administrator
Hero Member
Posts: 17656
Karma: 1610
Re: Installing X and virtualbox
«
Reply #9 on:
June 30, 2015, 09:43:31 am »
I've tested bhyve a couple of times and even managed to start an operational OPNsense inside it. Hopefully, we'll use it for testing/QA mid-term, but I can also see use cases for adding a GUI package for managing virtual instances / VMs in OPNsense itself.
FYI, there is a tool called iohyve
https://github.com/pr1ntf/iohyve
which wraps around bhyve (and ZFS) to make it simple to use...
Logged
cdburgess75
Newbie
Posts: 46
Karma: 8
Re: Installing X and virtualbox
«
Reply #10 on:
July 01, 2015, 04:43:48 pm »
That is awesome. You may have just pointed me in the right direction man, thanks.
«
Last Edit: July 01, 2015, 04:48:17 pm by cdburgess75
»
Logged
Print
Pages: [
1
]
« previous
next »
OPNsense Forum
»
Archive
»
15.1 Legacy Series
»
Installing X and virtualbox