maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   [Depreciated] BackupMenu - Backup & restore OS images(+ other features) (https://talk.maemo.org/showthread.php?t=58633)

Rob1n 2010-07-23 20:29

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by AlMehdi (Post 762560)
If i want to extract the rootfs on my Ubuntu machine. How do i do? I understand it is DD. But whatever i try don't work.

I thought it would be something like this.. but it wasn't
Code:

dd if=/path/to/file.img of=/to/folder/

You can't just use dd straight from the image, otherwise you end up with just a smaller chunk of the image. You'll need to mount the image as a filesystem. Assuming you've got all the necessary kernel modules built, you should be able to do:
Code:

mount -t ubifs -o loop /path/to/file/img /to/folder

Tiboric 2010-07-23 20:39

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by RobbieThe1st (Post 761369)
Hm, this is interesting - You had it in the backup? And it didn't carry past a reflash to 1.2 then restore? What did(does) uname -a state?

Well i've reinstalled titans kernel now but can do another restore if you want... wouldn't be a problem

Quote:

Originally Posted by RobbieThe1st (Post 761369)
I don't think its possible to flash OptFS through the flasher, which was why I implemented it in my menu.

Thats what I thought

Quote:

Originally Posted by RobbieThe1st (Post 761369)
Can you elaborate? I can't improve it if I don't have error reports...

Yeah sorry, it just stopped at about 60% and rebooted, then couldn't get it to boot(obviously) and wouldn't reflash with normal flashing procedure(with pr1.2 image + flasher) as would get stuck at byte 1024 saying the 'resource was busy' while flashing. only way i could get it do anything was with flasher + the .img file I made with your menu...

but all good now

Thanks for all your hard work, will try the menu way again next time I have to restore, just in case it was a one off.

AlMehdi 2010-07-23 21:27

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by Rob1n (Post 762578)
You can't just use dd straight from the image, otherwise you end up with just a smaller chunk of the image. You'll need to mount the image as a filesystem. Assuming you've got all the necessary kernel modules built, you should be able to do:
Code:

mount -t ubifs -o loop /path/to/file/img /to/folder

I tried that to with the exception of ubifs.. didn't think it of that it was ubifs. ;)

Thanks!

RobbieThe1st 2010-07-24 04:48

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by Rob1n (Post 762578)
Code:

mount -t ubifs -o loop /path/to/file/img /to/folder

When I try this I get:
Code:

robbiethe1st@rb-lt-new /Data/n900 $ sudo mount -t ubifs -o loop ./20100721-backup-rootfs.img /media/rootfsmnt/
mount: wrong fs type, bad option, bad superblock on /dev/loop0,
      missing codepage or helper program, or other error
      In some cases useful info is found in syslog - try
      dmesg | tail  or so

What did I do wrong?

leighw 2010-07-26 18:19

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Hi,

I am having trouble restoring images.

As you have probably guessed creating the back up images worked okay.

I boot up with the keypad open, BackupMenu starts.
I press 'r' to restore a backup.
I press 'p' to restore OptFS.
I press 'p' to tell BackupMenu to look at eMMC/MyData for the images. (I only have a 1Gb SD card which is pretty full).
I press 'a' to restore the previously saved '20100725-backup-optfs.img'

At this point nothing further happens; the Select File screen remains, I have tried leaving it for a while (4 hours!) just in case something was happening in the background but still the screen remains unchanged.

This happens with both OptFS and RootFS images although I have managed to restore a RootFS image via flasher-3.5.

I would be grateful if anyone can tell me where I am going wrong.

Cheers

jsbigs 2010-07-26 20:12

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by dj_steve (Post 756561)
ill have a quick look at gettign this going on MultiBoot for ya :)

dj_steve -

Just wondering if you've made any progress on this. I know you're doing incredible work on NITdroid and I'm currently waiting for the arrival of a microSD card so that I can test it out, but I'd love to be able to have BackupMenu installed as well, and usable without any conflicts. Do you think that will be possible? Thanks!

RobbieThe1st 2010-07-27 06:53

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by leighw (Post 765530)
Hi,

I am having trouble restoring images.

As you have probably guessed creating the back up images worked okay.

I boot up with the keypad open, BackupMenu starts.
I press 'r' to restore a backup.
I press 'p' to restore OptFS.
I press 'p' to tell BackupMenu to look at eMMC/MyData for the images. (I only have a 1Gb SD card which is pretty full).
I press 'a' to restore the previously saved '20100725-backup-optfs.img'

At this point nothing further happens; the Select File screen remains, I have tried leaving it for a while (4 hours!) just in case something was happening in the background but still the screen remains unchanged.

This happens with both OptFS and RootFS images although I have managed to restore a RootFS image via flasher-3.5.

I would be grateful if anyone can tell me where I am going wrong.

Cheers

Hm, what -version- of BackupMenu are you using?
Also, what keyboard layout do you have? Does the first row of keys start "qwerty..." or perhaps "azerty..."?
My system is currently only setup to deal with the American layout,
and for that system, the 'A' key is on the second row of the keyboard, second key from the left side(next to the blue alt key).

leighw 2010-07-27 17:25

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by RobbieThe1st (Post 766042)
Hm, what -version- of BackupMenu are you using?
Also, what keyboard layout do you have? Does the first row of keys start "qwerty..." or perhaps "azerty..."?
My system is currently only setup to deal with the American layout,
and for that system, the 'A' key is on the second row of the keyboard, second key from the left side(next to the blue alt key).

Hi, I am using version 0.31-2 and the keyboard is the qwerty layout and the 'A' key is 2nd row, 2nd column as you describe. I didn't know that was American, learn something new every day.

Thanks for your help.

RobbieThe1st 2010-07-28 07:49

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Alright then, things should be working right.
Note for future reference that my system is designed such that once it accepts input, you will see something different on the screen - For example, if there was a bug that made it crash when it got a certain combination, it would most likely display "loading xxx", and then crash, not crash at a "waiting for input" screen.

Try pressing B, C, D etc - Perhaps the input-checker counter is off by one?
Also, if that doesn't fix it, make a second dummy ".img" file on the eMMC(contents can be blank) - this will trick it into thinking there's two images, in case its not accepting input due to an error in the "counter-checker" script-chunk.

Let me know how those go; If you can get it working(or not), I will know what to fix and fix it in a day or two.

exuvo 2010-07-28 17:06

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Hello, i installed 'bootmenu-n900' from the extras-devel repository and have done a backup of the rootFS and opt, both went well.
My question is: is it supposed to start at once when i boot with keyboard open? I was hoping on having it as an option in the bootmenu instead.
Currently i have moved the script away from /etc/bootmenu.d/ for the bootmenu to show again.

Otherwise seen no problems. If i corrupt my fs again this will save me about 1 day of restoring (reinstalling,configurations etc). Awesome work!

lartistemoez 2010-07-28 20:46

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Hi All

please i need your help,i can not escape or close the script.
how can i open my n900 normally without this screen,every time when i restart the phone i get the same script please help me.

thanks

lartistemoez 2010-07-28 20:48

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by AlMehdi (Post 762645)
I tried that to with the exception of ubifs.. didn't think it of that it was ubifs. ;)

Thanks!

hi Almahdi,
please i m not expert and i don t know why this script appear in my phone after restart it,
please can you help me to open my n900 normally.

thanks

lartistemoez 2010-07-28 20:54

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
please expert i need your help,i dont know why in the first reboot after taking the phone from the service center in my country this script appear,and from that time for 6 hours know im checking for solutions no results
please i want to open my phone normally without this script.
every time when i restart the handset the script appear i dont know the solutions

please any one can help me.

thanks in advance.

DrWilken 2010-07-28 20:57

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Close the keyboard when booting? :)

First post:
Quote:

How to use:
Reboot the N900 with the keyboard open.
So to "not use it" close the keyboard and reboot... ;)

And please stop, double, no triple posting... That doesn't exactly speed things up... :)

lartistemoez 2010-07-28 21:08

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by DrWilken (Post 768347)
Close the keyboard when booting? :)

First post:


So to "not use it" close the keyboard and reboot... ;)

And please stop, double, no triple posting... That doesn't exactly speed things up... :)

thank you verry much Dr Wilken,
but before was not like this,the problem was with the speaker so i send it to the care center. maybe the program was changed.or software updated.

any way thank you verry much,and i m so proud to get friends like you experts.

thanks

DrWilken 2010-07-28 21:22

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
No problem lartistemoez... I'm glad it worked... ;)

RobbieThe1st 2010-07-28 21:43

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by exuvo (Post 768026)
Hello, i installed 'bootmenu-n900' from the extras-devel repository and have done a backup of the rootFS and opt, both went well.
My question is: is it supposed to start at once when i boot with keyboard open? I was hoping on having it as an option in the bootmenu instead.
Currently i have moved the script away from /etc/bootmenu.d/ for the bootmenu to show again.

I'm pretty sure that it launches multiple scripts in alphebetical order - Just make your other script named something -before- mine(say add a 1 to the front?), and it should boot that instead.

Then, you can probably launch mine by simply adding "/etc/bootmenu.d/BackupMenu.item" where its needed in the other script.


Quote:

Originally Posted by DrWilken (Post 768347)
So to "not use it" close the keyboard and reboot... ;)

:P Added to first post.

lartistemoez 2010-07-28 21:48

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
thank you guys you are the best.
:)

leighw 2010-07-30 06:26

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by RobbieThe1st (Post 767450)
Try pressing B, C, D etc - Perhaps the input-checker counter is off by one?
Also, if that doesn't fix it, make a second dummy ".img" file on the eMMC(contents can be blank) - this will trick it into thinking there's two images, in case its not accepting input due to an error in the "counter-checker" script-chunk.

I tried pressing B, C, D etc, but if I press any key - apart from the ones suggested in the current menu - the screen returns to the main menu.

If I create an empty .img file it is found and offered as a menu choice (b). As soon as I press 'b' the screen returns to the main menu.

I get the same behaviour if I choose the rootfs image (c) file rather than the optfs image.

I will try creating another fresh image from scratch later.

Thanks

RobbieThe1st 2010-07-30 10:41

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Thanks. Fixed in 0.32-1
It seems I had a bit of an error in my "button press value -> usable letter code" line. That has now been fixed.

zement 2010-08-02 11:34

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by RobbieThe1st (Post 762886)
When I try this I get:
Code:

robbiethe1st@rb-lt-new /Data/n900 $ sudo mount -t ubifs -o loop ./20100721-backup-rootfs.img /media/rootfsmnt/
mount: wrong fs type, bad option, bad superblock on /dev/loop0,
      missing codepage or helper program, or other error
      In some cases useful info is found in syslog - try
      dmesg | tail  or so

What did I do wrong?

you did nothing wrong, the mentioned way does not work!

correct way of ubifs handling: http://www.linux-mtd.infradead.org/f...l#L_loop_mount

cheers

hawaii 2010-08-05 03:43

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
0.32 seems to stall out after reaching 251MB when dd'ing out the rootfs.

Kabouik 2010-08-06 01:50

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Hi and thank you very much for this great app!

I successfully created backups for my Opt FS and my Root FS. I have no memory card so they were stored in MyDocs. Nevertheless, I messed up something with my applications and I need to restore the Opt FS now. And the problem is that, when I reboot in Backup mode by keeping the keyboard slided out, I can't restore the img which were created because I can't see them in the menu. They exist though and they are not empty (one of 4 Go and the other of about 260 Mo). The only file listed in the restore menu is an img file which is actually a rom for PSX4ALL. :/

Any idea on how to restore my system? I have a job travel on saturday and it would be great if I could have a full working phone before leaving, because I'm not that serene when having to travel without any communication mean! :]

RobbieThe1st 2010-08-06 10:37

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by hawaii (Post 776121)
0.32 seems to stall out after reaching 251MB when dd'ing out the rootfs.

Does it finish though? Remember, the numbers given are approximate - good for a rough estimate of time remaining, but not much else.
if it jumps to the next screen, it copied it all.


Quote:

Originally Posted by Kabouik (Post 777279)
Hi and thank you very much for this great app!

I successfully created backups for my Opt FS and my Root FS. I have no memory card so they were stored in MyDocs. Nevertheless, I messed up something with my applications and I need to restore the Opt FS now. And the problem is that, when I reboot in Backup mode by keeping the keyboard slided out, I can't restore the img which were created because I can't see them in the menu. They exist though and they are not empty (one of 4 Go and the other of about 260 Mo). The only file listed in the restore menu is an img file which is actually a rom for PSX4ALL. :/

Any idea on how to restore my system? I have a job travel on saturday and it would be great if I could have a full working phone before leaving, because I'm not that serene when having to travel without any communication mean! :]

Ok, lets see.
One, what version are you running?
Two, can you check if the files actually do/still exist by:
1. Reboot with the keyboard open to get into my script
2. at the main screen, plug the N900 into your computer via USB
3. hit the key for USB mass storage mode, then on your PC, wait for it to mount and check to make sure the files *do* exist.
4. Write down the names of the files, if they exist, and paste them here.
Also, you may want to see about running chkdsk when you connect to it via USB - It can't hurt.

Let me know how these turn out; I'll do my best to try to fix it for you.
So long as the files exist, and you are running a recent version(with the terminal mode), we can do a "manual restore" from there if the normal restore won't work.

Kabouik 2010-08-06 15:14

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Many thanks Robbie for your quick answer. I don't know how to check it, but as far as I know, I'm running the last version of Maemo (I flashed in late July), PR 1.2, and I think that BackupMenu is up to date because it was therefore installed in late July too).

I haven't my USB cable here with me, but I'll try what you said tonight (18H30 @ GMT -3 hours) at the hotel and I'll keep you in touch!

I leave tomorrow so perhaps you won't have time to help me before the departure, but thanks anyways for your concern about my problem!

Kabouik 2010-08-06 15:48

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
OK I finally wen't back to the hotel for lunch and I did what you said:

The files do exist. They are named 20100725-backup-optfs.img (4.19 GB) and 20100725-backup-rootfs.img (257 MB). When I explore the N900 with Windows in USB Mass Storage mode, they are at root (same directory as .documents, .videos, and so on).

The CHKDSK didn't find any error.

As the backup files may be compatible with the Maemo-flasher, perhaps I can restore them by copying them on my laptop and flashing the N900 with them? Too bad I run Seven x64. :/

Maybe it is noteworthy to mention I run an European version of the N900 (Azerty keyboard and so on, I don't know if European N900 are different on the software-side)

RobbieThe1st 2010-08-06 22:30

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
OK. The version should be shown at the top of my app, in white text on blue background.

I think the problem is the EU version.
My app's been designed for the US layout(I only get the key-numbers, not the letters they are attached to, software side), which is:
-QWERTYUIOP,-
-ASDFGHJKL.--
-ZXCVBNM ---

When asked to press a key, press the key that -would- be that letter on the US layout.
So, when asked to press "Q", press the key that would be row#1, key#2 from the left.

I'd bet that will solve the problem. If not, let me know.

Kabouik 2010-08-06 22:52

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Ok, so my version of BackupMenu is the 0.32.

To restore both RootFS and OptFS (which I want to do since I screwed up the dpkg system and I don't think that restoring OptFS will fix it), correct me if I'm wrong, I have to press successively R, T then P keys. If right, then my problem might not be due to the keyboard layout since these keys have the same row/column coordinates on both QWERTY and AZERTY layouts, as you can see on this picture (dont pay attention to the circles, I just found this picture on Google):

http://www.maemofrance.fr/wp-content...900-Qwerty.png

RobbieThe1st 2010-08-06 23:01

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Ok, when I reboot and press R, P, and T:
1. it waits for a few seconds after pressing T
2. It shows "Select file: RootFS image", and gives a list.

When you press that sequence, what do you see?
Do you just see nothing at that select file screen, or does it not -get- to that select screen?

Kabouik 2010-08-06 23:19

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
I get to that select screen, but the only file I can select is the PSX4ALL rom I mentionned in my first post here. However, it is not in MyDocs but in MyDocs/Roms/PSX.

Now I have another serious problem, not related at all I suppose: my N900 is chain rebooting. It occurs unplugged (no way to get the PIN code screen), USB plugged, and it even occurs when booting in BackupMenu mode (I can actually see the menu and I can navigate, but it finally reboots after several seconds). It really worries me because I'm affraid this is CPU-related and I see no way to fix it since the problem persists when the phone is USB connected, thus I can't flash it.

The world's against me. :|

RobbieThe1st 2010-08-07 00:56

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Can you try moving those two files to a different location on MyDocs? Say put them in your Roms directory.

I'm trying to figure out whats wrong, but even if I -do- solve the issue code-wise, it won't help you - You'd have to upgrade to a new version, and thats nigh impossible from your current status - So, we are going to have to see if we can't hack it into working right.

Chain rebooting - Hm... Sounds like something to do with the watchdog timer(which reboots things if it thinks things have gotten locked up).
With the OS, I'm betting its because the OPTfs is gone or damaged, and it won't boot without it .
With my backupmenu, have you had it reboot when you were actually -doing- something, or only after a period of inactivity?

ryanl33x1511 2010-08-07 01:23

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
just one quick question before making install and back up my stuff, does this app really work i mean to restore verything u backup , OS,apps, setting.....

RobbieThe1st 2010-08-07 01:48

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by ryanl33x1511 (Post 778437)
just one quick question before making install and back up my stuff, does this app really work i mean to restore verything u backup , OS,apps, setting.....

Generally, yes. I have successfully done it, a couple of others have too.
There have been a number of glitches over time though, but I think I fixed them; you should be able to backup and restore with no issues.
In order to back everything up, you need to backup both the RootFS and the OptFS. Same for restoring.

If you want to check and make sure, make a backup, change a few settings, then attempt to restore that backup - I'd definitely do this, especially with potential problems on non-US-keyboard layouts.
Let me know if it doesn't work; I'll fix it. But, unless I know of problems, I can't fix them.

Kabouik 2010-08-07 01:57

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by RobbieThe1st (Post 778421)
Can you try moving those two files to a different location on MyDocs? Say put them in your Roms directory.

I'm trying to figure out whats wrong, but even if I -do- solve the issue code-wise, it won't help you - You'd have to upgrade to a new version, and thats nigh impossible from your current status - So, we are going to have to see if we can't hack it into working right.

Chain rebooting - Hm... Sounds like something to do with the watchdog timer(which reboots things if it thinks things have gotten locked up).
With the OS, I'm betting its because the OPTfs is gone or damaged, and it won't boot without it .
With my backupmenu, have you had it reboot when you were actually -doing- something, or only after a period of inactivity?

No, I can't figure out how to move the files because of my rebooting problem. I can't get into Mass Storage Mode since I can't even get to the PIN code screen.

You're probably right about watchdog because when booting BackupMenu, it says that /dev/twl4030_wdt and /dev/watchdog were not found. It boots anyway and everything seems to work normally, but it reboots after several seconds, without calling a particular fonction to trigger the reboot. So no inactivity nor particular command to get into rebooting state, juste a given delay and *poof*, it reboots. Actually, it doesn't reboot when I am in BackupMenu, it just shutdown.

RobbieThe1st 2010-08-07 04:00

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
That doesn't sound good. I'm pretty sure that means that the low-level OS files on the RootFS are damaged and or missing, at least some of them.

You are probably going to want to:
1. Flash to PR1.2(Do -not- use the eMMC image, just the main image)
2. reboot. Assuming everything goes well,
3. Enable extras-devel and install my application
4. reboot into my app, see if the files are detected -now-. If you are still having trouble, then reboot into your (blank) system, change the names, and try again.

Let me know how that goes.

Kabouik 2010-08-07 04:02

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
I finally managed to solve my boot problem using Maemo-flasher 3.5 to flash the RootFS. I did that because it doesn't alter MyDocs, so my boot issue disappeared (as well as my dpkg issue) but my data are still there, including the backups files I created using BackupMenu.

I'll try moving the files into the Roms directory as you said, but if it still doesn't work I think I'll just manually reinstall all my apps, or restore them using the built-in option of the Application Manager. It won't be as good as a full restore from BackupMenu, but it will help.

Of course, I'll keep you in touch for the BackupMenu attempts as soon as possible, but for now... Time to prepare my luggage! :D

[Edit] Oh, you just answered me to flash when I posted to say I flashed. Cool, happy to see this was the right idea. :D I'm updating Maemo 5 right now but the wifi is extremely slow here and there are 113 MB to download, I'll of course install BackupMenu just after that and try again.

RobbieThe1st 2010-08-07 07:28

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Ok, great.
Now, just so you know, how my script finds image files to list at that menu is it literally runs(for mydocs):
Code:

find /home/user/MyDocs -name "*.img"
Then formats the resulting list. This means it *should* find -any- .img files on the whole partition.

Edit:
As I promised I was going to do:
A user sent me a copy of his RootFS and OptFS backups so that I could test them on my N900, see if the whole system works.
I have named them "other20100729-backup-rootfs.img" and "other20100729-backup-optfs.img".
I have backed up my own OS and files, and will (attempt to) restore them later.

1. I copied both of these files to my N900's MyDocs partition.
2. I rebooted into BackupMenu, version 0.33(0.32 + a minor bugfix I added today).
3. I pressed R for restore, T for both RootFS and OptFS, P for the eMMC.
4. I was asked to select the RootFS image, and I pressed F for the "other....rootfs.img", Same for the OptFS, and I pressed E for the "other....optfs.img".
5. I was asked "are you sure?", with the full location/path to each file shown. The files selected were correct, so I pressed P to proceed.
6. The process started, restoring RootFS first. I'm getting 3-4MB/sec usually.
7.Process finished, attempted to checksum - but no output. Bug in the checksum code I guess. I'll have to figure it out later.
8. I pressed a key to continue, and it started restoring OptFS.
9. Process continued with around 4mb/sec overall, occasionally dropping down to 2 and 1.
10. Um... Some time during this whole process, it started saying "0mb copied, 0% complete" and hanging there. I had to reboot it by removing the battery.
11. With the screen closed, I rebooted it. I got the nokia logo, it hung there for a minute or two, then shut off. Same with the keyboard open.
12. I opened my flasher directory and ran "sudo ./flasher-3.5 -r ../Backups/other20100729-backup-rootfs.img -f" from the console.
It started to flash, then I got "usb_bulk_write: resource temporarily unavailable. - Looks like I'm gonna need to flash PR1.2 first.
13. I flashed PR1.2, then with the USB still plugged in, ran the above command. This time, it flashed entirely. I did get:
Code:

Finishing flashing... Sending request 0x52 failed!

Bootloader error log follows:
  ERROR: Error reading spare of block 1847, page 0
  ERROR: Error reading block 51, page 0
  ERROR: Error reading block 52, page 0
  ERROR: Error reading block 53, page 0
  ERROR: Error reading block 54, page 0
  ERROR: Error reading block 55, page 0
  ERROR: Error reading block 56, page 0
  ERROR: Error reading block 57, page 0
  ERROR: Error reading block 58, page 0
  ERROR: Error reading block 59, page 0
  ERROR: Error reading block 60, page 0
  ERROR: Error reading block 61, page 0
  ERROR: Error reading block 62, page 0
  ERROR: Error reading block 63, page 0
  ERROR: Error reading block 64, page 0
  ERROR: Error reading block 65, page 0
  ERROR: Error reading block 66, page 0
  ERROR: Error reading block 68, page 0
  ERROR: Error reading block 69, page 0
  ERROR: Error reading block 70, page 0
  ERROR: Error reading block 71, page 0
  ERROR: Error reading block 72, page 0
  ERROR: Error reading block 73, page 0
  ERROR: Error reading block 74, page 0
  ERROR: Error reading block 75, page 0
  ERROR: Error reading block 76, page 0
  ERROR: Error reading block 77, page 0
  ERROR: Error reading block 78, page 0
  ERROR: Error reading block 79, page 0
  ERROR: Error reading block 80, page 0
  ERROR: Error reading block 81, page 0
  ERROR: Error reading block 82, page 0
  ERROR: Error reading block 85, page 0
  ERROR: Error reading block 86, page 0
  ERROR: Error reading block 87, page 0
  ERROR: Error reading block 91, page 0
  ERROR: Error reading block 92, page 0
  ERROR: Error reading block 93, page 0
  ERROR: Error reading block 94, page 0
  ERROR: Error reading block 95, page 0
  ERROR: Error reading block 96, page 0
  ERROR: Error reading block 97, page 0
  ERROR: Error reading block 98, page 0
  ERROR: Error reading block 99, page 0
  ERROR: Error reading block 100, page 0
  ERROR: Error reading block 101, page 0
  ERROR: Error reading block 102, page 0
  ERROR: Error reading block 103, page 0
  ERROR: Error reading block 104, page 0
  ERROR: Error reading block 105, page 0
  ERROR: Error reading block 106, page 0
  ERROR: Error reading block 107, page 0
  ERROR: Error reading block 108, page 0
Invalid error string data!

But this may still be OK - I'm pretty sure I have at least one bad block on my RootFS.
14. I opened my keyboard, unplugged the USB cable
15. The device rebooted into BackupMenu 0.31!
16. I restored optFS -only- this time, and it finished restoring - It didn't take long enough though, I don't think.
17. I got a checksum of the Backup file, but not of the OptFS itself, so I can't see if they really match or not.
18. Rebooted with the keyboard closed, got nokia screen > blank > reboot loop.
19 Trying to flash the OptFS again. Again, it only got to like 500mb before saying done. why? Only thing I can think of are bad blocks in the OptFS, and DD erroring out.
20. Connected to N900 vis the "read-only usb mass storage device" mode of BackupMenu. All partitions on the eMMC showed up to fdisk -l, and I ran cksum on both my backup file and the optFS partition:
612834623 2147483648 other20100729-backup-optfs.img
2389094843 2147483648 /dev/sdd2
On the one hand, this shows that the checksums are different. On the other, it shows that the -sizes- are the same, so it should have worked.

21. Now I'm going to try the previous steps with my own backup, see if its the method, or if it was a damaged file I got.
22. Flashing PR1.2, then my own rootfs.img. Both completed, and I got:
Code:

Bootloader error log follows:
  ERROR: Invalid argument for 'cmt'
  ERROR: Error processing request, stalling
  ERROR: EP0 STALL sent
  ERROR: Error reading spare of block 1847, page 0
  ERROR: Out of space: image size 263454720, partition blocks 2010, bad blocks 1
  ERROR: Error processing request, stalling
  ERROR: EP0 STALL sent
  ERROR: Premature end of control transfer

when flashing my own image(this is what makes me think I have a bad block).
23. Opened keyboard, loaded BackupMenu(ver 0.33 this time).
24. restoring Optfs. I am getting 4mb/sec average. It went over 2024mb, and I think it finished successfully. Cksum of OptFS... blank. I think there's a glitch.
25. Checksum of Backup... Nothing. Yup, some sort of glitch.
26. Rebooted. I got the 5 loading dots, then it shut off. Rebooted, got the 5 loading dots... then it booted fully! I'm guessing it shut off before after FSCKing the optfs, but I dunno.
27. Everything seems to be back where it was before - even the book position in FBreader. This is good.

This means that:
1. Potentially, current backups may be more or less tied to the N900 they were made on - due to bad block locations and such.
2. The foolproof method I talked about in the first post -seems- to work.
3. I have bugs in the checksum code, and I think that I'm gonna change the method of backup/restoring the OptFS to solve this problem.
I think instead of unmounting the OptFS and copying it byte-for-byte, I think I'll mount it and copy all the files instead using tar.
For restoring it, then, I will format the partition(it is EXT3 after all, no big deal), then restore the files.
Unless you have every byte filled in your 2GB partition, this should mean that badblocks will be rerouted by the eMMC and or the EXT3 FS.
This will mean however that backups made in the next version won't be compatible with older versions(Edit: without mounting the image, copying the files out, adding them to a .tar file, and importing them. It would work, but would require a Linux, and or possibly an OSX box. I doubt you could do it on Windows, at least without Cygwin).

MohammadAG 2010-08-08 12:44

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Can't restore the rootfs image, neither with the tool nor flasher-3.5
Code:

mohammad@mohammad-laptop:~$ sudo flasher-3.5 -r Desktop/20100807-backup-rootfs.img -f
flasher v2.5.2 (Oct 21 2009)

USB device found found at bus 001, device address 007.
Found device RX-51, hardware revision 2101
NOLO version 1.4.14
Version of 'sw-release': RX-51_2009SE_10.2010.19-1_PR_MR0
Sending and flashing rootfs image (257280 kB)...
100% (257280 of 257280 kB, avg. 34538 kB/s)
Finishing flashing... Sending request 0x52 failed!

Bootloader error log follows:
  ERROR: Invalid UBI magic in block 39, page 0
  ERROR: RX DMA IRQ, while no RX packet
  ERROR: EP2 RX for 512 bytes, but shouldn't
  ERROR: EP2 RX for 512 bytes, but shouldn't
  ERROR: Image not complete
  ERROR: Error processing request, stalling
  ERROR: EP0 STALL sent
  ERROR: Premature end of control transfer

Flashed PR1.2, then the rootfs from the backup, nothing.

Dany-69 2010-08-08 13:22

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
It's strange... i've flashed my rootfs image more than 10 times and everything worked pretty well.... =S

KOJAN 2010-08-08 14:31

Re: [Announce] BackupMenu - Backup & restore OS images(+ other features)
 
Quote:

Originally Posted by zement (Post 772949)
you did nothing wrong, the mentioned way does not work!

correct way of ubifs handling: http://www.linux-mtd.infradead.org/f...l#L_loop_mount

cheers

I can`t mount whis this commands:
Code:

# Create an 256MiB emulated NAND flash with 2KiB NAND page size
# (you should see the new MTD device in /proc/mtd)
modprobe nandsim first_id_byte=0x20 second_id_byte=0xaa \
                third_id_byte=0x00 fourth_id_byte=0x15

# MTD is not LDM-enabled and udev does not create device
# MTD device nodes automatically, so create /dev/mtd0
# (we assume that you do not have other MTD devices)
mknod /dev/mtd0 c 90 0

# Copy the contents of your image to the emulated MTD device
dd if=ubi.img of=/dev/mtd0 bs=2048

# Load UBI module and attach mtd0
modprobe ubi mtd=0

# Mount UBIFS
mount -t ubifs /dev/ubi0_0 /mnt/ubifs



All times are GMT. The time now is 02:24.

vBulletin® Version 3.8.8