OS Hacking and more.


Bundle: OpenSolaris Live USB

Up until now I've posted all the instructions and ideas behind my OpenSolaris Live USB system, the sum of which serves as mostly informative for all but the most intrepid...
Attached here is the kit of all the tools you need to make a persistent OpenSolaris Live USB drive, from start to finish.
In the Zip file is the main conversion script, which will take a standard OpenSolaris Install and make it live, and an additional tool for use after you've converted your system.
This tool works with both 2008.05 and 2008.11, and should work with Nevada builds as well.

Now, the easiest howto:

You'll need:
1x OpenSolaris Live CD (Indiana Preferred)
1x USB stick, at least 4gb suggested.
1x Conversion kit convert.zip

1. Boot from the live CD, with the USB drive plugged in. Install OpenSolaris to the USB drive.
2. Reboot and boot from the USB drive for the first time. After logging in, shutdown.
3. Boot from the live CD again.
4. Unzip the conversion kit.
5. Open zfsconverter with a texteditor, and change the value of "protodir" to the directory where you extracted the zip, + /convert/proto. Everything else should be ok for a normal setup.
6. In a superuser shell run zfsconverter

bash> zpool import -f rpool
bash> ./zfsconverter
bash> zpool export rpool

7. Reboot, and boot from the usb drive.
That should be all you need. After converting the usb drive to a live usb drive, you can install any packages you like. If a package you install adds kernel modules or boot files, you'll need to run the updatemicroroot script after installation.

OpenSolaris now can be taken in your pocket and used wherever you roam...


天昏地昏 said...

Have you done a dd'able liveusb image? nice idea!We want it.

Ahmed Kamal said...

If osol is installed to a USB stick, I can already take it with me anywhere .. why would I want to convert it to a persistent live image ? I'm not even sure how that's different from an installed system

Anand Gupta said...

@ahmed: However much i would like that to be true, it is absolutely not true. If you move an opensolaris install from one machine to another, or even another port on the same machine, the deviceid strings will be invalid and osol will fail to boot. Sorry.
I've done a dd'able image, but i'm not entirely sure where to post it considering its size.

Yaceq said...

Hi Anand,
I have a problem with your method. I do everything what it's said but with no result.
I use Indiana LiveCd distro 2008.11 snv_111 x86 to run the system. Then installed OpenSolaris to my USBkey.
Unfortunately, when I try tu run your script "zfsconverter" after changing protodir to
I get this message as follow:
root@opensolaris:/jack/convert# ./zfsconverter
Initializing installation, ensure that all prerequisites are fulfilled
mounting filesystems
mkdir: Failed to make directory "/mntzfs"; File exists
filesystem 'rpool/ROOT/opensolaris' cannot be mounted using 'mount -F zfs'
Use 'zfs set mountpoint=/mntzfs' instead.
If you must use 'mount -F zfs' or /etc/vfstab, use 'zfs set mountpoint=legacy'.
See zfs(1M) for more information.
mkdir: Failed to make directory "/mntram"; File exists
mount: I/O error
mount: Cannot mount /dev/lofi/3
preparing protodir
copying files
umounting filesystems
umount: warning: /mntram not in mnttab
umount: /mntram not mounted
mv: cannot create /mntzfs/boot/: Not a directory
umount: warning: /mntzfs not in mnttab
umount: /mntzfs not mounted
scrub zpool...if any errors arise, fix them and rerun this program
pool: rpool
state: ONLINE
scrub: none requested

rpool ONLINE 0 0 0
c7t0d0s0 ONLINE 0 0 0

errors: No known data errors
if there are no errors, the installation process has suceeded
fixing menu.lst
Done...Reboot to continue

Can you help me with it?
Thanks, Jack

Rodney Graves said...

The link to your conversion file is non-functional. An updated link or e-mail (rodney.g.graves@gmail.com) to the current location would be most appreciated!

karld said...

I would be pleased also to get the convert.zip file.

If you have a dd'able image, that would be great, maybe you could host it temporary on rapidshare or megaupload ?

Zaphod said...

Hey!!! Could you paste the content of the script? Or at least upload it to another site?


Aaron said...

The link to the convert.zip file is broken. Any chance you might post an update?

Anonymous said...

You've been a great help, thanks a lot. I've installed osol to my promo usb stick and now I can take it anywhere I need to use it!

Frank FindMeABetterName said...


Omnimous said...

Do you have an updated link to convert.zip?

Jasmine wilson said...

We are pleased to read this information providing brief article.
The loss of data almost always causes an individual to some feeling of dissatisfaction.
In order to resolve this concern, the specialists have proposed a lot of information recovery solutions.
Individual should be well aware of the available info retrieval resources with the intention that he'll deal the data damage situation in just a most convenient way.
recover deleted pst