Skip to end of metadata
Go to start of metadata

This page was deprecated, then updated, but it's still not recommended, not supported, and most likely not a good idea.

A better idea is to use SmartOS as intended: http://wiki.smartos.org/display/DOC/Getting+Started+with+SmartOS#GettingStartedwithSmartOS-CreatingaPersistentzpool

Creating a bootable zones pool

THIS WILL WIPE YOUR DISKS AND DESTROY YOUR BITS AND WILL BE COMPLETELY UNSUPPORTED IF YOU DO IT
Seriously, unless you understand what every step in this process does, don't do this.

And if you understand every step in the process, think very hard before you do this.

This is not supported, and if you have problems with your system you will politely be told to boot off a USB stick, a CD, or a PXE server.

These instructions are based on notes and haven't been verified
  1. Install SmartOS to a single disk or a single mirror (no RAIDZn or stripes of vdevs) (e.g. c0d0, d0d1, c0t0d0, c0t1d0, etc.), in this example, a mirror on c0d0 and c0d1:
  2. Let the system reboot after the install and log in as root.
  3. Download the latest iso, rip it open, copy files to where they are needed.
  4. Fix up your /zones/boot/grub/menu.lst file (note the path!) and install GRUB.
  5. Remove the CD and do a reboot. You should now boot directly off of your zones pool.

Updating to the latest release

The only good reasons to do this

  1. This machine you've just set up hosts your Simple PXE Server for the rest of your SmartOS machines and nothing else.
  2. You are a developer and want to be able to do fresh build of SmartOS, slurp the platform directory out of your build zone into your zones/smartos filesystem, and reboot onto your freshly built image. Those details are again left to the reader.

If you upgrade your zpool...

You might hit one of the reasons this is not recommended; newer pool versions / feature flags may require you to re-install grub.
If this is a development machine where you've rebuilt SmartOS, it's not so bad... From the GZ:

If you forget to do this and reboot to find that grub is broken, you will need to rescue yourself with a USB stick or CD so that you can do it.

So in case it wasn't clear yet, DO NOT RUN A PRODUCTION SERVER THIS WAY!!!

References

Labels:
None
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Aug 22, 2011

    See early discussion here.

  2. Jan 24, 2012

    I'm wondering if SmartOS will have more convenient installation method..

    1. Jan 24, 2012

      No. The live image model was chosen intentionally

    2. Apr 29, 2012

      Alexander, actually it was never meant to be installed to disk. It actually works a lot better this way, booting from a live media like PXE, CDROM, or USB thumb drive.

      This video really explains it a lot better than I ever could. http://www.youtube.com/watch?v=ieGWbo94geE

  3. May 29, 2012

    I like the Live image approach but the live image is perpetually rebooting asking the same questions each time.  I don't really ever "get into" the live image.  Any common pitfalls?

    1. May 30, 2012

      If you step through the configuration it should not ask you again after a reboot.

      You should check if you enter the disk names if asked - just pressing enter at this point does not configure any disks and will guide you through the settings again after reboot.

  4. May 31, 2012

    TK

    I would like to use SmartOS but our datacentre is managed remotely. How do I use SmartOS in this case? I would definitely not want the boot process to depend on a PXE server because it means a reliance on a separate server. If this separate server goes down, then my SmartOS hypervisor won't start.

    Surely there is a solution to this kind of (relatively common) scenario?

    1. Jun 01, 2012

      use an usbkey to boot

      For the initial configuration you should use some remote keyboard/display thingy

      Updates can be done remotely as well

      1. Jun 01, 2012

        TK

        Hi Daniel, thanks for your reply but it's not going to work as I have no means to insert the USB key into the remote server.

        So it's really a remote server in the true sense of the word - it's even on a different continent. This is a pretty common scenario with dedicated server offerings around the world.

        I suppose I could ask one of the remote techs to insert a USB key into the machine. But at a later stage when someone using the same shared rackspace pulls out my USB drive, it's also going to mean potential downtime.

        Is there no way to put the boot volume on disk? I.e. on a mirrored vdev zpool.

        1. Jun 01, 2012

          I also use a dedicated server hosted by some company. There was no problem getting a 16GB USB key inserted.

          You could also use some extra disk inside the chassis but you could just use the disk to boot and nothing else (I guess).

          Some small 8GB ssd on an IDE or SATA interface should work - but I think it's easier to get an USB key and use that ;)

          You also have potential downtime if someone needs YOUR network cable and just pulls it out ;) Something like that should just not happen.

          And also it's just critical if you reboot your box at exact that time. The USB key is just used while booting. (A dvd in a dvd-rom would also work - but someone could also go there and remove the disk)

          1. Jun 01, 2012

            TK

            I see your point regarding the network cable, but I believe that's quite different. If a tech sees a network cable sticking out he will put it back in. He will not at any point look at a network cable and pull it out.

            However let's assume they are doing some restructuring of their server racks. A tech sees a USB key sticking out of a dedicated server. Well, none of the other dedicated servers have a USB key sticking out, so why should this one? He might pull it out! And if he does pull it out, there's nothing you can do to complain to the hosting company because it's a special request that nobody has taken any responsibilities for.

            I still think it should be possible to boot up SmartOS from the actual main storage. I prefer servers to be resiliant and to always boot up with no human intervention. You can still use USB keys to boot up, but potentially have a backup SmartOS image on the physical drives somewhere. What do you think about this?

            1. Jun 26, 2013

              Dedicated hosting companies tend to do once off's for customers (like inserting USB keys into dedicated servers) when you submit support tickets so they have a paper trail and use customer notes to track this sort of thing.

              I wrote a script (available from https://gist.github.com/jacques/34b8767b549a379fdb28) which I am using to write to the USB keys in SmartOS Compute Nodes.  For critical systems you can do dual USB keys and if the one fails you can change your boot order using IPKVM.

  5. Jul 30, 2013

    Hi All

    I am trying to install Zones using above method on VM created on Virtualbox but it never able to rcognize network when "smartos=true" removed and "standalone=true,noimport=true" used. In that case it fails to authenticate. Is there anyway to get network recognized with that option so that I can install or is there any other option to configure this.

    If I configure with "smartos=true" and follow above steps than when it reboots with disk it comes up in grub mode and not able to find root.

    Please let me know if there is simple process to configure zones on virtualbox vm.

    Thanks

    1. Jul 30, 2013

      Do not use this wiki page for setting up a Virtualbox VM of SmartOS! Use SmartOS the way it was intended to be used. Use the ISO and just leave the virtual CD in all the time.

      See also: SmartOS on VirtualBox and SmartOS as a Sandboxed VirtualBox Guest