# APSK-VBSK - VirtualBox Setup Kit
APSK = Apollia's Puppy Linux Setup Kit
Formerly at: [https://apollia.org/gitlist/APSK---VirtualBox-Guest-Setup-Scripts.git](https://apollia.org/gitlist/APSK-VBSK---VirtualBox-Setup-Kit.git)
by Apollia - [http://apollia.org/](http://apollia.org)
Most of these scripts should be run inside the guest system, not the host. Most scripts for the host are inside the "00-For Host System to Run" folder.
For Lighthouse 64 Puppy Linux 6.02 Beta 2 (LH64_602_B2) as Both Host and Guest
LH64_602_B2 as Host and Lucid Puppy 5.2.8 version 004 (Lupu5284) as Guest
Updates from Jan. 14, 2018:
* Just added lots of new volumes to the list of shared folders. Will be more useful if/when I finally make something to automate the creation of shared folders via an existing list rather than only via the dragdrop script I made.
Maybe I'll make that next time I have to create a new virtual machine from scratch. But, it wasn't worth making yet, because it seems VirtualBox won't let me update my virtual machine via a script, even though VirtualBox's GUI lets me add new shared folders while my virtual machine is running or while my virtual machine has system snapshots.
So, since I didn't want to discard my already set up virtual machine, I actually had to add all those new folders manually!
* An update from later the same day. Soon after my previous update, my entire computer (host and guest) crashed when I forgot that I had almost totally filled up my ramdisk with VirtualBox system snapshots, and I accidentally saved one too many. My computer completely froze, and the only way I could fix it was to reboot.
So, sooner than I expected, I ended up making a script to build my entire ABDesktop Lupu5284 virtual machine using only console commands, instead of manually adjusting VirtualBox settings via VirtualBox's GUI.
Fortunately, this somehow resulted in my new script-created virtual machines running faster than the ones I had made with the GUI. I thought maybe it was because I had increased the amount of RAM from 2 GB to 3 GB - but even with just 2 GB of RAM, it's still faster!
<br>Jan. 10, 2018:
* Can now set up Lucid Puppy Linux 5.2.8 version 004 guests.
* Now off by default: seamless mode and dragdrop between host and guest systems.
* Some improvements to the Lighthouse 64 setup.
These scripts make it easier for me to set up VirtualBox guests running either of my two usual Puppy Linuxes:
* Lighthouse 64 Puppy Linux 6.02 Beta 2 (LH64_602_B2).
* Lucid Puppy Linux 5.2.8 version 004 (Lupu5284).
So, if my virtual machines or system snapshots ever get messed up again, it won't be as much of a nuisance anymore for me to remake them.
This blog post contains details on how to manually do some of the things these scripts do (more) automatically:
Originally, these scripts were designed only for LH64_602_B2 hosts and LH64_602_B2 guests. But it turned out I scarcely needed to change anything to make them work with Lupu5284 guests as well, so instead of making a separate almost identical repo, I just slightly modified this repo.
<br><br>Haven't tested these scripts with any other hosts and guests, though perhaps they might work with other GNU/Linuxes if modified. Or, with luck, no modifications - which I'm guessing might be most probable if your host or guest is another, similar Puppy Linux.
<br>For some things, I actually prefer a Lupu5284 guest over an LH64_602_B2 guest, because LH64_602_B2 has a very annoying tendency to sometimes get jammed up and extremely slow, such as if I just open certain web pages, or scroll down a page with a lot of large images.
And when it gets jammed, it even often takes a long time to even react to Ctrl-Alt-Backspace (the keyboard shortcut which is supposed to instantly break out of X Windows and end a lot of processes).
That glitch is even worse with virtual LH64_602_B2, since virtual systems run slower than real systems. And in general in Puppy Linux, that sort of thing seems more likely to happen when running low on RAM - and usually, I don't give my virtual machines as much RAM as I give to my real systems.
<br>In similar situations, non-virtual Lucid5284 often used to just instantly close my web browser rather than jamming up my entire computer. (Except in the cases when it sometimes froze up unrecoverably - which usually seemed to happen when I was running low on RAM - and all I could do was reboot.)
And even non-virtual Lupu5284 feels quicker and more responsive, while LH64_602_B2 sometimes feels a little laggy to me. But I'm unusually sensitive to such things, and usually LH64_602_B2 is fine, and still tremendously better than any proprietary OS I've ever used, like Windows XP, Vista, 7, 10, and Mac OS X Lion.
On one of my older desktops, non-virtual LH64_602_B2 did seem faster than Lupu5284 for some things, like some web browsing, except when it got jammed. But if Lupu5284 could use more than 4 GB of RAM, I might actually switch back to Lupu5284.
<br>Even my 2008 [giant cheese grater-like](http://www.souledesigns.com/blog/2013/06/mac-pro-kitchen-nightmare) Mac Pro, with 32 GB of RAM, and eight 2.8 GHz cores, gets jammed up annoyingly often, just by browsing the web in non-virtual LH64_602_B2! But at least that happens less often and less easily than it does on my less powerful computers.
I'm not sure it's my web browsers' fault, or something to do with Linux itself. Or perhaps both. But at least now I know it's definitely not from not having enough RAM.
Maybe I should try to find a PAE version - [http://puppylinux.org/wikka/PAE](http://puppylinux.org/wikka/PAE) - of a 32-bit Puppy Linux which is compatible with Lupu5284, so I can still use my old collections of Lupu5284 software.
<br>Another annoying glitch in LH64_602_B2 that I haven't figured out how to permanently fix is, sometimes trying to save things in the web browsers Firefox or Pale Moon cause my web browser to freeze up, and then I have to use Pprocess to end their processes.
I suspect a related glitch is what causes Xarchiver, Gimp, and SpaceFM to sometimes refuse to even open at all, since these things often happen at the same time.
Restarting the X server fixes all that temporarily, but eventually, the problems come back, whereupon I have to restart the X server yet again.
Notes for Lucid Puppy Linux 5.2.8 version 004 (Lupu5284):
Unlike LH64_602_B2, Lupu5284 apparently can't properly read most optical discs inside a virtual optical disc drive attached to a virtual SATA controller.
For some reason, I was only able to read my ISO containing this VirtualBox Guest Setup repo. Even trying to open the official Lucid Puppy 5.2.8 version 004 virtual disc gave me errors - even though that was the very disc my virtual machine had booted from!
<br>So, to get around that problem, I changed my virtual machine's Storage settings to make it use a virtual IDE controller. That means I can only have 4 virtual optical discs mounted in Lupu5284 at the same time - or less if I wanted a virtual hard disk attached to my virtual IDE controller (which I didn't).
Which is a bit of a nuisance, but not that bad, since it's possible to put Lucid's DevX SFS, kernel headers SFS, and this VirtualBox Guest Setup Scripts repo inside the same virtual disc.
(But, if you plan on editing the VirtualBox Guest Setup Scripts, it might actually be better to keep them on a separate disk without the other stuff - especially the SFS files - since that will make it easier to unmount the VirtualBox Guest Setup Scripts ISO so you can mount an updated version.)
You can put them all in the same ISO by putting Lucid's DevX SFS and kernel headers SFS inside the VirtualBox Guest Setup folder before running the script "Make an ISO Containing This Package" inside the "For Host System To Run" folder.
It might even be possible to add the contents of the official VirtualBox Guest Additions ISO, but I haven't tried that. But that would make it so you only need 2 virtual discs instead of 3 or 4.
<br>I'm not sure the Lucid Puppy 5.2.8 version 004 ISO is available anywhere anymore, but the version 005 ISO is. I haven't used it much, but I'm guessing they're probably compatible, and it looks like it uses the version 528-4 DevX file.
Both the ISO and the DevX file are available here:
<br>Lucid Puppy 5.2.8 version 004's kernel headers (which you sometimes need in addition to the DevX SFS file to compile some software, such as VirtualBox Guest Additions) are available from:
<br>Lucid Puppy 5.2.8 version 004's DevX SFS file of software development tools, and kernel header SFS file, are also available from: [https://archive.org/download/Puppy_Linux_Devx](https://archive.org/download/Puppy_Linux_Devx)
Direct link to the DevX:
Direct link to the kernel headers:
Here are details on where you can get the Lighthouse 64 Puppy Linux 6.02 Beta 2 ISO, and the DevX SFS file of software development tools (which I believe already contains kernel headers for Lighthouse):
<br>Pros of Lupu5284 guests:
* Less chance than Lighthouse 64 of the entire system getting so jammed up that even Ctrl-Alt-Backspace takes a long time to work.
* Potentially much smaller system snapshots than LH64_602_B2 guests, even when using the same amount of RAM. One of my first Lupu5284 snapshots was around 256 MB. (But they do get bigger when you install more stuff.) Being smaller, they also reload faster.
* Virtual optical discs and shared folders somehow mount faster.
<br>Cons of Lupu5284 guests:
* Mouse integration doesn't work, so switching between host and guest isn't as smooth, and seamless mode doesn't work very well.
* After installing official VirtualBox Guest Additions and restarting X server twice, the mouse cursor would disappear, if my setup scripts didn't install a Xorg settings file which fixes that.
<br>Cons of dragdrop:
* For me, dragdrop never works from guest to host.
* Dragdrop from host to guest seems to work OK with single files, but copying an entire folder caused my virtual machine to freeze up, leaving me with no option but to turn off my virtual machine and go back to the most recent snapshot. (This is why I made it so dragdrop mode is no longer on by default.)
* Wasn't able to dragdrop this into my Lupu5284 virtual machine, perhaps because the path is so long (260 characters):
/root/VB Shared/safe/Read and Write/ABDesktop VB/VirtualBox-Guest-Setup-Scripts---Lighthouse-64-Puppy-Linux-6.02-Beta-2-as-Both-Host-and-Guest/VirtualBox Guest Setup/Lupu5284/Xorg Screen Settings so mouse cursor does not disappear/Install 800x600 Xorg Settings
* My [legacy Puppy Linux Setup Kit](https://apollia.org/gitlist/Puppy-Linux-Setup-Kit--Legacy-Versions.git) sometimes overwrites the .xinitrc file.
So, after you run my legacy Puppy Linux Setup Kit, you'll have to re-run the VirtualBox Guest Setup scripts in the "For .xinitrc" folder, to make it so VirtualBox Guest Additions features will remain on.