Sunday, March 3, 2013

Using OpenVPN with DD-WRT

I have a Belkin N300 running DD-WRT 24-SP2 mega.  I want to configure OpenVPN on it so that I can connect to my home network when I am on the road.

There is a good guide here.

It was still a bit much for me to process.  I was hoping to get by without having to edit a bunch of configuration files and setting up routes.

I generated certificates, but the ca.crt did not take, even after setting the router to use GMT.  I'll wait a day and try again.

Install SS4200E EMC OS to VirtualMachine

I have had an Intel SS4200E for a while now.  It is an intel based, single core celeron computer with 512MB ram, 4 internal SATA ports, one PATA port, 4 USB 2.0 ports, and 2 e-SATA ports.  The default software is EMC Lifeline.  The last version is 1.1.11.32736.  The software runs on a 256MB Disk-on-Module (DOM) in the PATA port.  This is like an early SSD.

I recently got another SS4200E so that I could run NAS4Free on it.  I want to do this for several reasons.
  • NAS4Free is more capable and flexible
  • NAS4Free can run ZFS
  • I can install a different media server.  The media server on the EMC server will not serve out certain file types.
I had looked into the media server once before, and it is an older version of twonky.  I think that twonky can be configured to serve out additional files.  I also think that the OS loads from the DOM into memory, so any changes to the configuration would be lost during reboot.  I know that I should not mess around with configuration files and reboot my working server.

So now I have some options.  I can test using the 2nd SS4200E.  I have another DOM, and I have installed the EMC software using a file called: EmcImager-1.1.1-1.0.8.29352.zip.  It isn't hosted on Intel's site, but it can be found.  It creates a bootable USB, which is used to install a previous version of the OS to the PATA disk.

Once the older OS is installed, you can update to the current OS.  In order to update, you have to put at least two disks in.  For the disks to be recognized, they have to be empty.  I was able to delete everything off one disk and have it be recognized, but this didn't work for another disk.  I tried to reformat it in Windows 7, but that didn't work.  I finally cloned the original disk to the 2nd disk.

Once two disks are installed, you can upgrade the SS4200E to the current OS using the "firmware" downloaded from Intel's site.  I did all of this over several days, then I wondered if I could just install the OS to a virtual machine.  After all, the SS4200E is a standard Intel system running linux.

So, I tried to figure out how to get VirtualBox to boot a USB drive.  It is not supported.  I tried several work-arounds without success.  Then I tried to convert the USB drive to an ISO image so I could boot from CD.  The USB drive is based on SLAX linux.  I first tried to "burn" an ISO using ImgBurn.  There are some options that you set to tell it what file to boot from.  I apparently did not guess correctly.

Then I looked in the USB drive.  There is a make_iso script.  That is just what I needed.

I ran the make_iso.bat script, attached the new ISO to the virtual machine, and booted.  For the first time, I saw video output from the SS4200E OS (the SS4200E is a headless machine, although you can hack a video card in).  The cd iso installed the OS to the 256MB hard drive in my virtual machine.  After installing, it ejected itself.  This even removed it from the virtual machine.  I removed the cdrom from the virtual machine and started it.

It booted up to a login prompt.  I was unable to connect to the web server, probably because the network adapter was bridged.  I changed the adapter to be bridged and rebooted.  Then I was able to connect to the web server.

Now I can play around with the settings to see what changes are persistent.  If I get brave, I can even try to modify the OS image itself.