Cloning OS to SD/MMC Card: Simplified instructions
These instructions apply to OS 2006 (770), OS 2007HE (770) and OS 2007/OS 2008 (N8x0).
If you're all set with root access, xterm, wget, boot menu and e2fsprogs installed *and* a 256MB+ second partition on Internal memory card, jump straight to step 7... otherwise continue with the pre-reqs. Pre-requisites to be satisfied before cloning OS 1. xterm must be installed
2. "Becomeroot" package must be installed or device in R&D mode
3. wget installed for downloading web-based files from the command line
4. e2fsprogs package installed
5. At least a 256MB partition is needed on /dev/mmcblk0p2 (partition 2, Internal SD/MMC card)
6. Fanoush's modified initfs and boot menu should be installed
Once all of the above pre-requisites are satisfied continue at step 7. Cloning the Operating System to Internal SD/MMC Card 7. Download and execute the following script and binary
7.2 As user "root" (without Sardine upgrade)
7.3 As user "user" (with Sardine upgrade)
Edit: See post #288 which details additional parameters for the nupgrade.sh script. |
Re: Cloning OS to SD Card: Simplified instructions
Why make it that hard.. why not just tar over and back the install?
|
Re: Cloning OS to SD Card: Simplified instructions
Because some people struggle to do even that...? And because it does more than just tar the OS - it formats the filesystem, insmods the various modules, mounts the mount points and tar's rootfs. And it also upgrades to Sardine if you want it to.
Once all the pre-reqs are in place (which only need to be completed once per flash) and the script and tar have been downloaded (again once per flash), the user only needs to running the script in sequence (0-4 or 0-6) whenever they want to clone the OS. No need to remember each individual command/step or cut&paste from the wiki. Seems simpler to me... :) |
Re: Cloning OS to SD Card: Simplified instructions
The commands only need to be run once per flash too.. and I put up easier instructions than the wiki once upon a time. I like your method, it will help the mindless dual boot. I guess I just like to know whats going on under the hood as I figured anyone who would bother with a dual boot wou.d
|
Re: Cloning OS to SD Card: Simplified instructions
Well I for, one, don't -- much. I just want the added space and speed, and follow Howtos :-)
Thanks Fanoush, and thanks Mil... |
Re: Cloning OS to SD Card: Simplified instructions
Quote:
Quote:
Quote:
Quote:
The only reason I dual boot nowadays is to give Sardine a whirl every now and again - with this script I can clone and upgrade the OS to Sardine inside 30 minutes and I'm only typing 6 or 7 commands which aren't exactly difficult to remember (particularly as six of them are practically the same!) :) The OS clone takes about 10-15 minutes, and the upgrade to Sardine another 15-20 minutes. Most of the time is spent waiting for files to copy or download/upgrade... run the next step... wait... run the next step... etc. until finished. Then reboot and enjoy (well as much as one can enjoy Sardine - the new finger menu is looking good though). Hopefully these instructions will make life simpler for some people and may even allow yet more people to sample Sardine. It's an alternative to the various wiki instructions (although it skimps in some important areas such as partitioning etc.) but should be easier to follow if you don't want to have to think too much! :) |
Re: Cloning OS to SD Card: Simplified instructions
Quote:
Quote:
|
Re: Cloning OS to SD Card: Simplified instructions
Is this a typo?
Quote:
The card slot on the bottom of the N800 under the stand is considered the external card and the card beside the battery on the back of the unit is the internal card--right? |
Re: Cloning OS to SD Card: Simplified instructions
Yes, that is a typo - mmcblk0px is the INTERNAL card, thanks for catching that.
I've now corrected the instructions (replacing external for internal) and uploaded an updated script - the original script worked fine, but would have displayed confusing comments... :) |
Re: Cloning OS to SD Card: Simplified instructions
Noob reporting:
I've encountered problems at step 7 of this guide. Here's what I'm getting (verbatim): sudo gainroot /home/user # cd /home/user/bin /home/user/bin # ./nupgrade 0 /bin/sh: ./nupgrade: not found /home/user/bin # Should I be typing in "./nupgrade.sh 0"? I'm running IT2006 on n770, and I should add that I've checked in the /home/user/bin directory and both nupgrade.sh and tar are present. |
Re: Cloning OS to SD Card: Simplified instructions
Yes my bad, thanks for catching that - I'll update the instructions now. :)
|
Re: Cloning OS to SD Card: Simplified instructions
I'm very interested to perform this procedure. How much faster does loading things from SD is, compared to the JFFS2 partition? Can hdparm be used to measure the jffs2 partition speed?
|
Re: Cloning OS to SD Card: Simplified instructions
Search the forum for "hdparm", you'll find the thread with the answers you seek.
|
Re: Cloning OS to SD Card: Simplified instructions
Thanks Milhouse. I did try searching for 'hdparm jffs2' but for some reason that thread didn't turn up in the result, although both terms are referenced in the thread.
|
Re: Cloning OS to SD Card: Simplified instructions
Quote:
The filename extension is just as any other part of the filename, and only there for your convenience (.sh is often used to indicate to you that it's a shellscript, but you could equally well call the file nupgrade.myscript, or, indeed, just nupgrade) |
Re: Cloning OS to SD/MMC Card: Simplified instructions
Quote:
Right now, I just got my brand new 2 G MMC, have not even opened. I would like to clone 2006OS and 2007He on MMC, and either 2006OS or 2007He on internal flash of my 770. Currently, I have 2007He on internal flash and 2006OS cloned on 1 G MMC. I am also in the middle of setting up a Ubuntu box. I guess my situation is very similar to a lot of folks in this column, got a new 770, cloned 2006OS to MMC, then flash 2007He to internal flash. I suppose, a lot of folks will be interested to see how to accomplish 2007He cloned to MMC without starting from scratch, if possible. 1) what is the most efficient partition on a 2 G MMC? I seldom use 2006OS other than occasional watch some video, I propose like .3G to 1.7G partition, would that be adequate for 2006OS boot? 2) Can I partition the 2 G MMC on a Ubuntu box? or just a PC with a USB media reader? 3) Can a ubuntu box copy the 2006OS from a 1 G MMC to the 2 G MMC mmcblk02, if a Ubuntu box can work with those USB media reader thing...please dont laugh, I am squeazing my last neuron on technology! If the answer is yes, OMG, dont be shine, could you please write the commands too? I promise you, I will learn Debian before the next 2007He from Nokia:rolleyes: 4) Then I can just clone my already flashed 2007He from 770 to the 2 G MMC mmcblk03. If the above is not possible, then I am not quite sure how am I going to clone both 2006OS and 2007He to MMC simultaneously. It sounded way too complicate, maybe I just cloned the 2007He to MMC and forget (?) about 2006OS? Thanks in advance, Mil. or anybody has good suggestions/experience, feel free to jump in, as I said, this is going to be followed by a lot of folks. bun |
Re: Cloning OS to SD Card: Simplified instructions
1) I would suggest the minimum size partition you need for OS 2006 is 256MB, that's roughly equivalent to the size of the internal (128MB compressed) flash memory. 512MB for OS 2006 should be ample.
2) Yep, no problem 3) Yep - tar up the content of the OS2006 partition on 1GB MMC and then untar it on your 2GB MMC. Once you've mounted the card on your Ubuntu box, cd to the root of the partition and create the tar as follows: "tar cvzf /tmp/os2006.tar.gz /" then swap the MMC cards and restore the clone using "cd <root of mmc partition>; tar xvzf /tmp/os2006.tar.gz". That should work, or something similar... :) If you can mount both cards at the same time you can pipe the output from the first tar command into the second tar and avoid creating a temporary file. 4) Not sure about mmcblk03... I think someone else asked some of your questions in another thread (probably the OS2007HE thread) - you should check there. |
Re: Cloning OS to SD/MMC Card: Simplified instructions
Quote:
2006OS Flash/MMC 2007He2007.36-2 MMC 2G Follow Mil's Simplified instructions, now 2007He2007.36-2 is booting of MMC 2G. Thanks Mil! As explained, the steps are easy to follow, ./nupgrade 0-4. I made some very minor change to suit my use, I give .45G for the OS and 1.37 G for media (a 2G reads only as 1.89G before formatting) and I use Fat32 instead of Fat16, /dev/mmcblk0p1: 1,45000,b /dev/mmcblk0p2: 45001,, /dev/mmcblk0p3: /dev/mmcblk0p4: I am not a SW developer, the chance of installing 1.5G app is highly unlikely for me, at this stage,;) Kind of curious what other people's partition like. I jumped right to step 7 as I already has the prerequisite, but it kicked me out on ./nupgrade.sh 3 > Internal application error, Xterm close. I re-started from step 6, no more error. Very interesting....... Now I booted from MMC and has 237 M space for apps, OMG!!! bun |
Re: Cloning OS to SD Card: Simplified instructions
I followed these instructions for my 770, everything went fine, but finally i am not able to access my FAT partition. in file manager memory card item was grayed out !! when i checked in control panel it is saying my memory card is corrupted (ofcourse i booted from memory card), can some one tell me how to resolve this problem? thanks.
|
Re: Cloning OS to SD Card: Simplified instructions
Quote:
bun |
Re: Cloning OS to SD Card: Simplified instructions
Mil, thank you, thank you, and thank you.
Had some problem with opera, and cannot undo whatever happened to it, it broke and would not work. I wiped my tears dry, and without hesitation, jumped right into step 7 of your instruction, ./nupgrade.sh 0-4, then went helping my wife to prepare breakfast. Dont know how long it take, as if I care, when I came back, it's done and everything is back to normal. That is what I call a regular automated installation.........100% hands free. Thank you again, Mil. This is day and night when I triedto clone the 2006OS to the MMC It wont download, file was missing, this TAR but not this TAR, my good grief, that is worst than to teach a pig to dance! bun |
Re: Cloning OS to SD Card: Simplified instructions
My pleasure!
I wrote this script so that when I had a spare 30 minutes I could disengage brain, run the script and walk away safe in the knowledge that when I returned I would have a succesfully cloned OS. Glad it's helping you too! :) |
Re: Cloning OS to SD Card: Simplified instructions
Quote:
Actually i am booted into my MMC without any problems, but only thing is i am not able to find the remaining FAT partition. your trick will work if i booted from internal flash, right? I guess it can be fixed by reformatting the FAT partition, but i donno how to do that? |
Re: Cloning OS to SD Card: Simplified instructions
Quote:
___________________________________________ Nay, if it works, it works. You turned the 770 off, and take out the card, bla bla bla. There is a possibility that the card was not inserted 'perfectly' but is allowing the previous format/working temporary and thus heated up the media and causing the problems. As I said, it is a last ditch effort. For hard drive, I even put it in refrigertor and will sometime allow me to recover some data before it dies again after 15min or so working. [QUOTE=____________________________________________ I guess it can be fixed by reformatting the FAT partition, but i donno how to do that?[/QUOTE] This, boot from MM, step 4 is partition, will kill the other partition too, not recommend. the formatting is next step, http://examplified.net/guide/Nokia_7...ting_from_MMC/. Tools>file manager>memory card also has a formatting command, not sure how it works, I think step 4 above should take care of you, post if questions. good luck. bun |
Re: Cloning OS to SD Card: Simplified instructions
Quote:
mkdosfs /dev/mmcblk0p1 shutdown -r now above command solved my problem, my remaining FAT partition is back, before your suggestion i was in the impression that the script by milhouse will take care of that too,,,!! I have another question. this device gives very little time to hold menu button to get boot menu, and most of the times i am little late and it defaults boots into internal flash. So I want to increse that time to press menu button and even if i didnt press button it should default boot into my MMC, how can i do that? |
Re: Cloning OS to SD Card: Simplified instructions
Im getting an error installing e2fsprogs
Package e2fsprogs is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package e2fsprogs has no installation candidate Any ideas? Also wanted to say thank you for taking the time to write this up. Was exactly what I was looking for. |
Re: Cloning OS to SD Card: Simplified instructions
I'm almost done with this process, for not knowing anything about Linux it was easy enough, just a little problems due to errors of my own. Milhouse, thanks for posting this!
Edit: How do i know if i'm using the memory card or the flash memory? |
Re: Cloning OS to SD Card: Simplified instructions
Quote:
Code:
/dev/mtdblock4 on / type jffs2 (rw,rpsize=1024,rpuid=0,rpuid=30000) |
Re: Cloning OS to SD Card: Simplified instructions
Quote:
|
Re: Cloning OS to SD Card: Simplified instructions
Quote:
|
Re: Cloning OS to SD Card: Simplified instructions
@Milhouse
For some reason i didn't even have the basic repo installed: Web address: http://repository.maemo.org/ Distribution: gregale Components: free non-free so once that was in e2fsprogs installed fine...thanks for the quick responses though..great thread topic |
Re: Cloning OS to SD Card: Simplified instructions
Thanks for that - I've added the repository details to the first post in case it catches anyone else out.
|
Re: Cloning OS to SD Card: Simplified instructions
Milhouse: I just want to join the chorus of appreciation for what you've done. I've been booting from my mmc for years now, both on the 770 and the N800. I shudder whenever a new firmware comes out, not only because of the hassle involved in flashing it to the main system, and reinstalling all my applications -- but then, even more so, of having to get it cloned onto the mmc. I've had to do it too many times already, and whereas Fanoush and his "comperes''" established instructions have proved sufficiently clear, it was not until I encountered yours that the whole matter became, if not an actual pleasure, at least an almost no-brainer. Congratulations for your initiative and your results (in efforts and accomplishments more than in just this one instance).
|
Re: Cloning OS to SD Card: Simplified instructions
[Edit: How do i know if i'm using the memory card or the flash memory?[/QUOTE]
How about a nobrainer checking:menu>control panel>memory>details>storage mem either in use or avail is >64 MB, you are booting from MMC, in general. bun |
Re: Cloning OS to SD Card: Simplified instructions
Xterm was suddenly closed in the middle of phase nupgrade.sh 3 so can i just do the command again or do i have to do it in this specific order(o, 1, 2, 3, and 4)? There came message "internal error" and xterm was closed. Is this harmful for the system?
|
Re: Cloning OS to SD Card: Simplified instructions
Okei, I solved that. I just proceed from phase 3 to 4 and all went well. I haven't noticed that system is faster but there's now more space to install applications. If I upgrade to Sardine will those installed applications be there also and will they work on Sardine? Does Sardine mean I have to install all once again? Now I'm thinking upgrading to Sardine, before this I didn't have enough courage to even think about upgrading.
Thank you Millhouse for these instructions! Great job. |
Re: Cloning OS to SD Card: Simplified instructions
Unfortunately the upgrade to Sardine has been failing for the last few weeks with dependency issues. You can try it, but I wouldn't expect it to work (although the issues will be fixed eventually) and your applications will remain intact (but they might not work due to API changes in the latest Sardine/Chinook OS). They're not kidding when they state that "Sardine is unstable and will often be badly broken and smelly". :)
|
Re: Cloning OS to SD Card: Simplified instructions
Thanks Milhouse, I'll try it later when I'm more used to this cloning process. I've read about Sardine and I'm interested about it. Like you said, maybe it's better to leave it for those who knows what they are doing, I'm still quite newbie but learning all the time!
|
Re: Cloning OS to SD Card: Simplified instructions
This doesn't work on my N770 :( The OS is 3.2006.49-2. I'm trying to clone onto a new 1GB Nokia card.
All the steps complete successfully. The problem is that the boot menu doesn't appear after reboot, and mount shows that the system is still booting from jffs2. The MMC card then shows up as corrupted, but can be formatted after this and works fine. When partitioning the card, I follow the instructions here: http://examplified.net/guide/Nokia_7...ting_from_MMC/ Step 4. I split the card between VFAT and Linux. Any ideas? EDIT: Figured it out. I didn't realise that you had to manually install the dual-boot menu software. Done that and can now boot from mmc. |
Re: Cloning OS to SD Card: Simplified instructions
Quote:
bun |
All times are GMT. The time now is 13:53. |
vBulletin® Version 3.8.8