Run Multiple WebOS Versions

THIS IS A WORK IN PROGRESS AND WILL DESTROY YOUR PRE

And especially your /media/internal filesystem

First be running the version you want to be secondary, Then on pre, run:

dd if=/dev/mapper/store-root of=/media/internal/root1.img bs=1048576 dd if=/dev/mapper/store-var of=/media/internal/var1.img bs=1048576 tar cvzf root-var.tar.gz root1.img var1.img

From host:

novacom get file:///media/internal/root-var.tar.gz > root-var.tar.gz

Now doctor to the version you want to be primary (this one will determine which kernel you run for both unfortunately)

When done, from pre:

stop LunaSysMgr pkill cryptofs umount /media/internal lvresize -L -800M /dev/mapper/store-media mkdosfs -F 32 /dev/mapper/store-media mount /media/internal

From host:

novacom put file:///media/internal/root-var.tar.gz < root-var.tar.gz

Back on pre:

cd /media/internal tar xvzf root-var.tar.gz lvcreate -L 256M -n var2 store lvcreate -L 40M -n log2 store lvcreate -l 100%FREE -n root2 store dd if=/media/internal/mb/root1.img of=/dev/mapper/store-root2 bs=1048576 dd if=/media/internal/mb/var1.img of=/dev/mapper/store-var2 bs=1048576 resize2fs /dev/mapper/store-root2 resize2fs /dev/mapper/store-var2 mke2fs -j -b4096 -m0 -L /var/log /dev/mapper/store-log2

Now you just need a /boot/init that will mount whichever root and var is desired, and a service to enumerate the ones that are available and reboot into the selected one

.. and of course this doesn't deal with the kernel.