SmartOS – Part 1

SmartOS is a hypervisor and a live image based on Illumos (Open Solaris, Unix-based). It supports the creation of zones (Unix/Ubuntu/Centos, very much like Promox) as well as regular virtual machines via KVM. Site is http://smartos.org/, you can find a good basic overview of the possibilities is at http://www.machine-unix.com/beginning-with-smartos/ (other user experience at http://opusmagnus.wordpress.com/2012/02/14/discovering-smartos/)and a very good description of the virtulization approach and OS basics at http://www.perkin.org.uk/posts/smartos-and-the-global-zone.html.

SmartOS is a 64bits only OS and I don’t have many x64 capable machines so I decided to experiment with SmartOS as a virtual machine on ESXi.

The First Challenge
ESXi will only boot from the ISO image in the virtual CD tray the first time after the VM is created. The second time and thereafter, it will try to start from the hard drive and crash, since SmartOS is loaded into RAM at launchtime and isn’t actually installed on the drive. For some reason, you can’t have a virtual USB key through ESXi, just share a physical one plugged into the hypervisor, which just isn’t an elegant solution. So I went about adding SmartOS to my PXE server (a Windows XP machine, which incidentally I need to have a look at because it has been crashing regularly on me but that’s another story) and well, that wasn’t as straightforward as that at all. I checked those links for reference – http://nahamu.github.com/2011/08/17/smartos-pxe.html – http://blog.smartcore.net.au/smartos-network-boot-with-pxe/ but nothing fit and I had to play around <<ADD DETAILS OF THE SETUP HERE>>

The Second Challenge
I then went about creating a zone to install FIFO on (http://project-fifo.net/display/PF/Project+FiFo+Home) but discovered at pkgin update time (“pkgin -fy up”) that my zone didn’t have connectivity (ie it couldn’t download the package_summary.gz that I checked was available on the joyent site), the IP of the zone registered on the LAN tab on my router, yet I couldn’t ping it. It turned out that I had to update ESXi to allow Promiscuous Mode for the NIC it presents to the virtual machines (that’s done through the vSphere console, under Configuration -> Network for the hypervisor itself, not the specific VM).

The Third Challenge (User-Related)
At this stage, I then went ahead and ran the chunter script… in the fifo zone rather than the global zone, which caused some havoc not easily rolled back and this ended up prevented the web console from working. After some unsuccessful debugging, I ended up tearing the fifo zone down and rebuilding from scratch. Workin perfectly now!

For future experimentation, if I can get suitable physical hardware to deploy
http://ispire.me/how-to-create-smartos-windows-vm/

If needed
http://wiki.smartos.org/display/DOC/SmartOS+on+VirtualBox

Advertisements

Installing Gallery on Ubuntu 12.04

Easy option – running it as a virtual machine using the turnkey linux appliance at http://www.turnkeylinux.org/gallery

Doing it manually

  • Install apache,php and mysql – see previous post
  • Download Gallery at http://galleryproject.org/
  • Enable Server_Add option (to use pictures on an existing local drive rather than having to re-upload through the web interface)
  • Enable ffmpeg to be able to see movies through interface at http://codex.galleryproject.org/Gallery3:Modules:ffmpeg
  • Enable Pear theme from http://codex.galleryproject.org/Gallery3:Themes:pear4gallery3, looks really nice!

beets: the music geek’s media organizer

Shttp://beets.readthedocs.org/en/v1.1.0-beta.1/

Command line Python-based music organizer, seems to work quite nicely from initial testing.

Install Notes on regular Ubuntu 12.04 LTSP:

  • Install beets – sudo pip install beets
  • Copy /usr/local/lib/python2.7/dist-packages/beets/config_default.yaml to /home/mathieu/.config/beets/config.yaml
  • Install pylast (for the genre plugin) – sudo pip install pylast (more info at http://beets.readthedocs.org/en/v1.1.0-beta.1/plugins/lastgenre.html)
  • Edit config.yaml to change directory value to where you want the organized files to be located, add the following plugins [convert, fetchart, embedart, lastgenre]
  • To run, beet import /WhereYouWantTheFilesToBeImportedFrom
  • To reset, beet remove -d

I am still having issues with the convert piece, I installed ffmpeg and the additional package for mp3 encoding (sudo apt-get install libavcode-extra-53), the encoding works fine from the WinFF front-end but beet just skips over the .wma files when importing so I am guessing after re-reading the plugin description (http://beets.readthedocs.org/en/v1.1.0-beta.1/plugins/convert.html) that it only works on the way out, ie once the files are already in the library?