OESF Portables Forum

Everything Else => General Support and Discussion => Zaurus General Forums => Archived Forums => Software => Topic started by: dys on April 07, 2004, 07:47:20 pm

Title: ozone - OpenZaurus cloning tool
Post by: dys on April 07, 2004, 07:47:20 pm
Hi all,
        Just thought I\'d post to say that I have written a little script that makes a flashable image (clone) of an openzaurus filesystem. I wrote this for myself but it works good for me so I thought someone else might benefit from it so I thought I\'d release it

In a nutshell what it does:

- Can create a flashable image of an OZ system so as if the system needs reinstalling (for whatever reason) then it can be done with some apps/data etc already there.
- Can also create a regular backup (tarball) of an OZ system. This tarball can be encrypted if required.

What I\'ve found it useful for:

- Checking out new ROM\'s. I just took an image of the OZ with the old ROM and then could test out the new ROMs without worrying about loosing anything / doing a lengthy reinstall of old ROM + Apps if I didn\'t like the new ROM.
- As I play round LOTS with my zaurus there is always the chance I will kill it somehow. If I have a recent flashable image its very quick and easy to restore back to a good and happy zaurus

Anyway I thought that someone other than me might find it useful so here ya go. If you do like it / dont like it / want to see new features or bugfixes feel free to let me know and I\'ll try and do them.

!! --WARNING-- !!
I have only tested it on a 5500 but it \"should\" (cough) work on the other models that OZ works on as I have included the initrd build values from the OZ CVS. In any case if it does work on another model / you tweak the script to get it to work on another model it would be cool if you let me know.

It can be downloaded from my website :
http://www.iodboi.co.uk/ozone/ (http://www.iodboi.co.uk/ozone/)

cheers
           dys
Title: ozone - OpenZaurus cloning tool
Post by: Snooby on April 07, 2004, 09:45:45 pm
Neat idea !!

Could you adapt the script to work with other ROMs ? I prefer use tkc 2.0 Alpha 3.0 on my Sl-5500 for daily use but am forever re-flashing to test new ROMs/apps etc and then re-installing tkc afterwards, this could save me a lot of time !!!
Title: ozone - OpenZaurus cloning tool
Post by: dys on April 08, 2004, 03:59:26 am
Yeah I was thinking about this the other night, I think all I would to know for each ROM are the mountpoints so as the script can get the partitions right. I\'m off to work now but I\'ll try and have a look into it tonight, hopefully it shouldn\'t prove too much of a prob.

Cheers
           dys
Title: ozone - OpenZaurus cloning tool
Post by: braindrop on April 08, 2004, 12:56:08 pm
wow! this sounds exactly like what ive been looking for. like that ghost thing from that one company right?  i just have to ponder any possible implications of having my /usr and /opt on sd partitions.
Title: ozone - OpenZaurus cloning tool
Post by: dys on April 08, 2004, 02:14:01 pm
Quote
i just have to ponder any possible implications of having my /usr and /opt on sd partitions

all you would need to do is add ./opt/* and ./usr/* to the list of files that are being written to the file ozclone_exclude on the zaurus (its in an ssh\'d echo statement near the start of the ozclone function in the ozone script). This file list is used to exclude parts of the filesystem from the initrd image. Now the clone will not use the contents of /opt or /usr but still leave the mount points there. Upon flashing with that image all should be well as long as /opt and /usr on the SD haven\'t changed much.

I was going to put in some configuration options to exclude extra parts of the file system easily rather than having to hack up the main script. I\'ll try and put that in the next version.

Has anyone (other than me !!) successfully cloned an image and reflashed yet ??? I\'d appreciate feedback

cheers
         dys
Title: ozone - OpenZaurus cloning tool
Post by: Mickeyl on April 08, 2004, 04:38:20 pm
Nice idea. I\'m going to pester the Opie folks to add that to the backup application.
Title: ozone - OpenZaurus cloning tool
Post by: dys on April 08, 2004, 05:15:19 pm
Hi Mickeyl, at the moment it is run from the desktop PC (linux) but i\'m sure it can easily be done on the Z and the initrd created on CF/SD.  Is there a version of mkjffs2 that runs on the zaurus itself ?

dys
Title: ozone - OpenZaurus cloning tool
Post by: gester on April 08, 2004, 05:37:29 pm
This is a fantastic idea, I don\'t run OZ at the moment but I\'ll be happy to test this for other rom\'s as they become available.

gester.
Title: ozone - OpenZaurus cloning tool
Post by: dys on April 08, 2004, 08:45:33 pm
Done a quick update, there is now a new configuration variable CLONE_MSK which makes it easier to alter which directories will NOT be included in the flashable image. This should make it easier for people who have non-standard filesystem layouts (e.g. /opt on a SD card) to use the cloning without having to dig through the main script. Check the README for details. Did a few other cleanups as well. Get the new version from the same place as last time:
http://www.iodboi.co.uk/ozone/ (http://www.iodboi.co.uk/ozone/)

dys
Title: ozone - OpenZaurus cloning tool
Post by: Mickeyl on April 09, 2004, 05:44:37 am
Quote
Is there a version of mkjffs2 that runs on the zaurus itself ? 
Yeah, no problem in making one.
Title: ozone - OpenZaurus cloning tool
Post by: dys on April 09, 2004, 05:52:37 am
Quote
Yeah, no problem in making one.

Cool if you could send a copy to me I really appreciate it [ ozone[at]iodboi.co.uk]. I pretty sure with that I will be able to get a quick and dirty version of ozone going that will run on the zaurus itself.

cheers
          dys
Title: ozone - OpenZaurus cloning tool
Post by: Mickeyl on April 09, 2004, 11:09:52 am
Just built one with OpenEmbedded. The package is @ http://vanille.de/temp/mtd_20040409-r0_arm.ipk (http://vanille.de/temp/mtd_20040409-r0_arm.ipk) and contains the whole mtd utils.
Title: ozone - OpenZaurus cloning tool
Post by: dys on April 12, 2004, 06:19:53 am
Cheers Mickeyl, really appreciate you doing that. I\'ll get onto getting a version that runs natively on the Zaurus.

cheers
          dys
Title: ozone - OpenZaurus cloning tool
Post by: dys on April 12, 2004, 06:22:33 am
Sorry Mickeyl but the ipk installs fine but is asking for version 2.3 of libc.so.6 and as far as I know I only have version 2.2 on my 5500 (OZ 3.3.5). Is there any chance of building against libc 2.2 ?? Sorry to be a pain

dys
Title: ozone - OpenZaurus cloning tool
Post by: Mickeyl on April 12, 2004, 07:02:52 am
I\'m looking into it. Must do it manually then, because we don\'t have the older libc in OpenEmbedded. I\'ll keep you posted.
Title: ozone - OpenZaurus cloning tool
Post by: Hrw on April 25, 2004, 04:59:38 pm
Quote
Has anyone (other than me !!) successfully cloned an image and reflashed yet ???

I reflashed my SL-5500 from OZ 3.3.6-pre1 32/32 to 48/16 memory setup using ozone. Backup, reflash with just created initrd and 48/16 kernel. After that I moved things from mnt/ram backup into /mnt/ram and it works OK.

Thx for tool - it\'s great
Title: ozone - OpenZaurus cloning tool
Post by: dys on May 05, 2004, 05:03:37 pm
Quote
I reflashed my SL-5500 from OZ 3.3.6-pre1 32/32 to 48/16 memory setup using ozone. Backup, reflash with just created initrd and 48/16 kernel. After that I moved things from mnt/ram backup into /mnt/ram and it works OK.


Cool, glad that someone else has found it useful
Title: ozone - OpenZaurus cloning tool
Post by: francois.mean on May 27, 2004, 12:21:26 pm
Hi all,

I try to use ozone but it still says
\"Checking zaurus connectivity.....
Cannot locate zaurus. Check the connection to the zaurus, and that the IP is correct\"
But I am able to sync with QTopia Desktop !!!!

can someone tell me wha to do ?

Thanks,
Francois.