i searched and my eyes hurt from being on this forum for the last few hours. i just got a new sd card that i partitioned using the parted method, and also flashed my g1 with CM 4.0.1. Realized that my new card doesnt have the apps from my old card. How do i transfer the files from one sd card to another? They both have ext3 partitions. I have an sd card reader, but i also have adb. Just need the easiest way. thanks
freaklt1z said:
i searched and my eyes hurt from being on this forum for the last few hours. i just got a new sd card that i partitioned using the parted method, and also flashed my g1 with CM 4.0.1. Realized that my new card doesnt have the apps from my old card. How do i transfer the files from one sd card to another? They both have ext3 partitions. I have an sd card reader, but i also have adb. Just need the easiest way. thanks
Click to expand...
Click to collapse
The easiest way is to clone the old sdcard to the new one and then readjust the partitions (if necessary). This works easiest if that the new sdcard is at least as large as the new one (you got a bigger one, right?).
You can do this either using usb to your computer, or by using a dedicated card reader (preferred). If using the phone as the card reader, you MUST BE SURE that NONE of the card partitions are mounted on the phone and then either way proceed as follows;
Connect the phone_with_old_card or old_card to your computer (must be LINUX/BSD/other_unix -- use a livecd if necessary).
Check the output of the 'dmesg' command to determine the device file, i.e. sd?. You need to know '?' and substitute that character throughout the rest of the instructions. Note: if you see, for example, 'sdb1', 'sdb2', then you are looking for 'sdb' which represents the ENTIRE DISK -- the numbers represent the partitions within the disk and are of no interest at this point.
As root (or other member of group 'disk') run the following:
dd if=/dev/sd? of=/some/place/with/enough/space/sdcard.img
When it finishes, swap in the NEW card (be sure to unmount if it automounts), check the output of 'dmesg' again (though unlikely, it could assign a different device file), and run the following;
dd if=/some/place/with/enough/space/sdcard.img of=/dev/sd?
The new card has now been cloned and will work as the old card, BUT, if the new card is LARGER than the old, the additional space will not yet be accessible....
To increase the accessible space, use a program called 'gparted'. Most livecds should have this installed, or you can google for 'gparted' and download their livecd. Use gparted to move/expand your partitions as you desire, then you'll be done.
Note: in the unlikely event that the new card is SMALLER than the old one, run gparted FIRST to shrink the partitions on the card such that they are SMALLER than the partitions THAT YOU CREATED on the new card, then use the dd command to copy PARTITION to PARTITION (i.e. use 'dd if=/dev/sd?1 of=...', etc.), then rerun gparted to adjust the filesystem sizes within the partitions.
Related
Is it possible if I installed apps/data on SD card to switch to another card and install apps/data on it? I removed my current card and my phone stopped working. I will take help from anyone who has it.
if you want to, you should be able to copy everything to a backup folder and upload to another sd card. you need to do this in linux cause windows does not natively read ext2 partitions. shut down your phone, remove the micro sd card, put in your computer, copy everything to the backup folder, then re-partition your new (hopefully bigger) micro sd card. put back in the phone and boot it up. i have never tried this, but it should work, just as long as you have the ext2 partition the system can read from. good luck.
I agree fully with corp769. In addition, two important things to remember are:
* ext2 must be the second (primary) partition
* you must preserve UNIX access permissions by copying apps and data directories with cp -rp ! That's the reason apps on SD doesn't work without repartitioning.
* you must use a separate card reader, you cannot do this while the card is plugged into your G1. (Unless you can do some fancy mounting/unmounting stuff on the phone, that is. It's certainly easier and safer to use a card reader).
I too have never tried this, but it should work.
creid2352 said:
Is it possible if I installed apps/data on SD card to switch to another card and install apps/data on it? I removed my current card and my phone stopped working. I will take help from anyone who has it.
Click to expand...
Click to collapse
i did this on linux from a 2G card to a new 8G card .. my partitions are named so i utilize naming to distinguish one partition from the other:
make two folders on your linux desktop .. "SDD1" and "SDD2" .. the FAT32(sdd1) can be click-and-drag to the desktop folder .. the EXT2(sdd2) needs to be run inside Terminal to retain the permissions (unless someone know a better way)
ie: sudo cp -a /media/sdd2/* /home/LucidREM/Desktop/SDD2
then switch cards
ie: sudo cp -a /home/LucidREM/Desktop/SDD2/* /media/sdd2
obviously substitute your name for mine unless you call yourself "LucidREM"
In the exact same process when you have an error nfs :
In linux with the card reader
unmount both vfat and ext2 partitions and type :
fsck -p /dev/yourext2partition.
fsck.vfat -p /dev/yourfatpartition
that's how I manage to recover 2 MicroSD card
If you want to go the GUI route - go grab a copy of the GParted Live distribution. Put that on bootable media (whatever your case may be, USB or CD/DVD) then boot into GParted and use the GUI to copy and paste the partitions over. GParted will do a consistency check and fix any errors in both partitions first, then copy over into the new SD card.
Thanks a lot for the help everyone. I will give this a shot when I get home. Appreciate all the quick responses.
no prob man, just let us know if it works for you or not.
If you don't have linux, is there a program for windows or mac I can use to do this? Thanks
legaleye2005 said:
If you don't have linux, is there a program for windows or mac I can use to do this? Thanks
Click to expand...
Click to collapse
Yes download Wubi (which is like Linux in a box, and can be installed in like 10 minutes and ready to use and removed like a normal program) or download Paragon Partition Manager 9 Trial Version, it must be version 9 not 10. I recommend Wubi however, much easier, and who knows, you might fall in love with it like I did.
I tried the LucidREM instructions and it is looping on startup.
Is there a different way to do this?
Simplest Method
Just in case people still want to know how to change SD cards (ext partition and all), which I suspect will happen a lot since the 16GB cards are going to start dropping in price soon, here's the simplest and best way I know how to do it. I have done this a bunch of times without any issues. I've even used this to go from a G1 to a myTouch (with minor compatibility changes, of course). But simply changing/upgrading SD cards is a breeze.
First thing's first. You will need bart.sh which can be found here: http://forum.xda-developers.com/showthread.php?t=562292. If you are using a myTouch or simply don't want to bother typing commands, use Amon_RA's wonderful recovery menus with bart.sh already built in. The Nexus One version can be found here (http://forum.xda-developers.com/showthread.php?t=611829) but there are links to the recovery menus for the G1, myTouch, Hero, etc. on that page.
You will need to be familiar with how bart.sh works and this is way beyond this post. There is a ton of information on the bart.sh thread. So here are the steps that need to be done.
1) Run bart.sh, either in recovery console or via recovery menu, to backup your entire ext2/3/4 partition (as well as nandroid for simplicity).
2) Back up the fat32 portion of your SD card as you normally would by mounting your SD card to your computer. Make sure that this includes the new bart.sh backup which should be located in the bart folder in the root of you SD card.
3) Partition your new SD card using the method of your choice. Amon_RA's recovery menus have an easy and painless method for this but you can use parted or any other method you choose. If you use your device to partition your new SD card do NOT boot your phone after you partition the card. You will want to finish Step 4 first. Amon_RA's recovery allows you to mount your SD card from recovery to help you complete Step 4 if you do not have a SD card reader.
4) Using Amon_RA's recovery menu or an SD card reader copy the fat32 partition, which includes your bart.sh backup, from your PC to the fat32 partition of your newly partitioned SD card. From the recovery menu, restore your bart.sh backup.
5) Voila. You now have all of your partitions moved to a new SD card.
This process can be simplified into one sentence. Do a bart.sh backup and restore it to the new SD making sure the SD card has the proper partitions and that you don't forget about the fat32 partition. The above is just a list showing the proper order so that you don't lose any data during the process.
A while back ago I purchased a Disc with all kinds of recovery and maintenance programs for all versions of Winders from a company called "Spotmau". One of the uitlities in BootCare is a great partitioning program called Partition Genius, that enables you to move, shrink, add/subtract partitions without having to wipe entire drive. Specifically, I am able to modify an SD Micro card without having to flip the non-removable bit.
My question is, should I just leave the new ext3 or ext4 partition as such or should I go ahead and format it in Linux? The program has the ability for this.
This is a bootup CD so you'll work in a non-winders environment but it does the trick really good.
G1, on AT&T
CyanogenMod 4.2.13
16GB Sandisk SDHC.
Just use the recovery image in my sig, no need to have a card reader or anything extra on the computer.
Filp the non-removable bit?
Non-Removable bit
I was taught that a PC will not partition an SD card or a USB flash drive because it is addressed as a removable drive. By flipping this "Non-Removable Bit", the PC, and any partitioning program will now recognize the USB or SD card as a permanent or fixed drive. I tried a program that was published by Lexmark but I didn't get any results. I did, however, accomplished to partition any USB or SD card with Partition Genius which is a bootable program.
Diode
Oh yeah, thanx for your recovery image, highly appreciate it.
L8Tr 4 Now.
so i either don't fully understand how images work in the SDCard itself (not on the nook), or i did something wrong and don't know how to fix the card, but at any rate, i managed to burn a 128meg image onto my 8gig sd card, didn't like the image, and now can't figure out how to get the card back to a regular 8gig card!
would love some direction. tried to search but must not be using right keywords.
didn't see any kind of format or clear option in the winimg program we're using.
thanks!
byproxy said:
so i either don't fully understand how images work in the SDCard itself (not on the nook), or i did something wrong and don't know how to fix the card, but at any rate, i managed to burn a 128meg image onto my 8gig sd card, didn't like the image, and now can't figure out how to get the card back to a regular 8gig card!
would love some direction. tried to search but must not be using right keywords.
didn't see any kind of format or clear option in the winimg program we're using.
thanks!
Click to expand...
Click to collapse
On your Nook I believe you can go to Settings, Device Info, Mount the SD card if it's not mounted and then format it. It'll erase it and you'll have a blank SD card. If you're going to put a different image on the card I don't know if you even need to bother formatting, but I' not sure about that stuff.
does the nook format work differently than a computer format? because i burned a 128meg image onto an 8gig card and now even a computer format won't get the whole 8gigs back... just the 128 megs. it's like it's got invisible partitions on it or something.
Partition
Try EASEUS Partition Manager to change the partition size/format card.
byproxy said:
so i either don't fully understand how images work in the SDCard itself (not on the nook), or i did something wrong and don't know how to fix the card, but at any rate, i managed to burn a 128meg image onto my 8gig sd card, didn't like the image, and now can't figure out how to get the card back to a regular 8gig card!
would love some direction. tried to search but must not be using right keywords.
didn't see any kind of format or clear option in the winimg program we're using.
thanks!
Click to expand...
Click to collapse
byproxy... here is the easy way...
1) Go and download "EASEUS Partition Master 7.0.1 Home Edition" --- just google it (the home edition is free and downloadable)
2) Put your microSD card into a card reader and plug into your computer
3) install EASEUS onto your computer and run the app
4) Once app is started, located your microSD card amongst the list of drives listed
5) select each one of the partitions on the SD card, and delete them individually
6) Once all partitions are deleted, make sure that you are still selecting the microSD card, and select the option to create partition (it may just say create)
7) Make sure you select FAT 32
8) Then select FORMAT
9) Lastly, click on APPLY and it will do all the things above. So in short you select all the actions that you want... and only in step 9 will it execute all those actions.
Please make sure that any changes you make are to the SD card and not any of your other drives. Last thing I would want is for you to accidentally format your Computer, NAS, or your non-SD card. =)
Enjoy...
sweet. exactly what i was looking for. thanks gents!!!
hvuong2 said:
byproxy... here is the easy way...
Enjoy...
Click to expand...
Click to collapse
OK, but isn't it easier just to do it in the Nook or am I missing something here?
...worst case there's a low level SD card formatter from Panasonic (IIRC might be Toshiba) that will do a complete low level format and has recovered uSDs for people using them with Nintendo DS dev carts...
A Google search should turn it up, or a thread on a DS site which might have a link to it. It'll be a little windows program...
(I believe that windows and most devices just do sort of a quick format of the uSD, and so can't recover from some problems like re-partitioning of the card... so monkeying around with a partition editor and assigning the card to be one big partition then re-fromatting under windows or some other device MIGHT work as well...)
[EDIT]
oops, I see post #5 has the re-partitioning solution as well... another way to do it would be to backup an image of the card BEFORE burning something like autonooter on it then restore that original image to card once finished with whatever you were trying out... it's what I did when I tried autonooter w/my old 128MB card, in linux in my case a
dd if=/path/to/sd/card of=./somefilename
dd if=./autonooter.img of=/path/to/sd/card
then later
dd if=./somefilename of=/path/to/sd/card
sd card path under linux is likely to be /dev/memc<device ref characters?>
You should also be able to do this under windows with the utility recommended for windows users to use with the autonooter image, as I'm guessing that it's just a GUI wrapper and a windows compiled version of the dd utility...
[/EDIT]
Varying opinions
BarryR1 said:
OK, but isn't it easier just to do it in the Nook or am I missing something here?
Click to expand...
Click to collapse
Some believe that there are issues with formatting on Nook... depending which ROM you are running. The surefire and safe way, is to do it from a PC.
Nook should format, but may not partition correctly.
hvuong2 said:
Some believe that there are issues with formatting on Nook... depending which ROM you are running. The surefire and safe way, is to do it from a PC.
Nook should format, but may not partition correctly.
Click to expand...
Click to collapse
No, the Nook will format the *device* and not a partition, so it always works. But you don't want to do it if you've installed NC or HC to eMMC.
If you're using Stock rooted, just boot without the card in the device, put it in, format. Done.
Or if you're on a real os just format the device... mkfs.vfat /dev/sdX
Introduction I wanted to put this into a thread since there are multiple questions about the same topics here. I'm simplifying here, Verygreen and others could give you a lot better detail. But if you are confused about some of the directions in other threads, this may help.
For most purposes, the SD card is treated as a simulated hard disk. So much of the control and terminology used is the same as HD.
For the Nook HD/HD+, the easiest (and so far only) way to access control of the machine is through an SD card. This is because the bootloader will check the SD card and boot an acceptable OS it finds there. So for now at least, ALL CM versions for these Nooks will be booted off the SD card. For those familiar with flashing their phones, it is no different except all ROMs will reside on the SD card. The internal memory, called EMMC (or internal SD) is available for use with these ROMs as of 12/28 releases so it isn't wasted, and data (not programs) you want available from both Stock and CM can be placed there.
ROMs are placed into memory with a program generically called Recovery. This is a small OS which can provide access to memory, update ROMs, wipe memory partitions, make backups of your ROM, provide access to partitions from your computer via ADB, etc. The version that we are using here is called Clockwork Mod (CWM). You will need to load this into the boot sectors of your SD card.
Burning CWM In order for the bootloader to load this program, the exact placement of bits in the SD memory is critical. So instead of copying this program over to the SD card, you must burn an 'image'. This is an exact replica of the specific bits mapped to correct sectors of the SD card. The term is usually 'burn' an image. To burn an image from Windows, the recommended program is Win32DiskImage (http://sourceforge.net/projects/win32diskimager/) but other "image writing" software will work.
When you write an image, your SD card will contain a partition exactly the size of the image you just wrote. A partition is a formatted and ready to use portion of a hard disk or something simulating a hard disk like your SD card. In windows, you might have seen instances where multiple partitions are allocated to different drive letters (e.g. C: and D: ) both on the same physical device. In Unix or Android, partitions are often known by names such as /system or /sdcard. However, native Windows installs are only able to see the first partition of a SD card. Therefore, if you write a 500MB image to a 32 GB card, at that point in time only 500MB is usable and 31.5GB is no longer available. For the CM10 installs on this thread, the rest of the card is automatically partitioned as new drives for the ROM and DATA and so becomes available (linux/android don't have the partition disabilities of Windows).
If you are using Leapinlars' CWM zips to root, etc, you can simply copy the files over after writing the image. There is room in the imaged partition for these files. IF you are using Verygreen's CM10, and possibly others, you can't copy the files over as the CWM partition is too small to start with. After the CM10 SD boots in the Nook, it will create partitions to use the rest of memory. But these new partitions are not easily accessible with Windows. This is why Verygreen's instructions include using ADB to push the zip file to the /sdcard partition.
Partitions For those writing CWM images for update zips (e.g. http://forum.xda-developers.com/showthread.php?t=2062613), you will either want to use a smallish (e.g. 4G) SD card or repartition the card after you are done. The images by Leapinlar are large enough to load a few zip files for flashing in addition to the CWM program and a couple of backups (sometimes called 'nandroids'). But if you want to access the rest of the card, you'll need to repartition. The main reason you would want to do this is to return your 32GB card to full size, either with or without CWM on it; simply reformating on windows will not restore the unused data. For this, you will need to use a partitioning tool like Easeus (http://download.cnet.com/Easeus-Partition-Master-Home-Edition/3000-2248_4-10863346.html) or Minitool (http://www.partitionwizard.com/download.html). Note, this is generally NOT needed by the instruction sets on these fora, but is just provided as information, or if you wish to return to SC card to an initial state.
Copying files to partitions For the Nook HD/HD+, you must have the boot partition in the first partition of the SD card. This will NOT be the /data partition or the /sdcard partition. Therefore, you need a way to write to these partions on the CM builds. The easiest way is to boot CWM and use your computer to write to the these partitions via Android Debug Bridge (ADB). The process is boot to CWM, then go to mounts and storage, mount the /sdcard, THEN adb with CWM running and copy the zip over. ADB is a command shell that can execute commands on a remote android machine. Leapinlar's tips thread http://forum.xda-developers.com/showthread.php?p=34168454#post34168454 gives a lot of detail about setting it up and getting it to run. If you are using Windows, there is a way (Update: this does work to see the sd card partition on CM10 SDs) to see all partitions on a SD card. See this tutorial: http://forum.xda-developers.com/showthread.php?t=1585572. When done properly, you should be able to write your zips directly to the /sdcard partiton of the sd card (if that sounds confusing, please reread all that stuff above.) Note, there are partitions formated in unrecognized formats which are NOT seen with this method.
SD Formats SD cards are 'formatted' in different ways, just like hard disks. Formatting refers to data structures and directory structures used to keep track of files on a hard disk. In fact, any hd format can be used, but the typical format (data/directory structure) on smaller SD cards is FAT32. These are limited to a max filesize of 4GB and are fully compatible with Windows XP. For the larger cards, they often come formatted to a new format called exFAT (extended FAT). These allow larger files but are not native to Windows XP. However, a driver is available from M$ that will support exFAT. Because it is unexpected, you will get an error talking about the likely damage to your hardware if you proceed when writing an image to the exfat formatted SD card. You can ignore the error, the image is written bit for bit correctly.
Lastly to completely reboot the Nook HD/+, you need to hold the power button down for 10 seconds ignoring all prompts. Then hold it down again until it turns on.
I hope this is helpful. Please feel free to post comments and corrections below if I've made any mistakes and I'll update the op. I'll also try to answer questions if you have them.
I currently have a 32 gig card but want to buy a larger 64 gig card. Can I simply copy all contents of my SD card to PC and then paste them back to the new 64 gig card? Will all my apps and their databases installed on SD card still work? Or are apps tied down to the SD card or the device for security. Have 8.1 installed on my Ativ S.
Thank you!
tboy2000 said:
I currently have a 32 gig card but want to buy a larger 64 gig card. Can I simply copy all contents of my SD card to PC and then paste them back to the new 64 gig card? Will all my apps and their databases installed on SD card still work? Or are apps tied down to the SD card or the device for security. Have 8.1 installed on my Ativ S.
Thank you!
Click to expand...
Click to collapse
I Suggest 2 Ways .
I think both of them work for you .
1.Copy apps to phone storage and move them to new sd card
2.copy WPSystem in your old sd card to new one (maybe 1% this not work but not a bad try )
ngame said:
I Suggest 2 Ways .
I think both of them work for you .
1.Copy apps to phone storage and move them to new sd card
2.copy WPSystem in your old sd card to new one (maybe 1% this not work but not a bad try )
Click to expand...
Click to collapse
Ah but the amount of internal phone storage is less than the size of my current 32 gig sd card so I will not be able to move back to phone all my apps and their data.
tboy2000 said:
Ah but the amount of internal phone storage is less than the size of my current 32 gig sd card so I will not be able to move back to phone all my apps and their data.
Click to expand...
Click to collapse
so lets test copy wpsystem folder ?
Back from my hd2 days we used to clone the smaller card to the bigger card. Bigger card will then show in your case 32gb. Then use a partition manager to expand the size of the partition. Used to work with wp7.x not sure of wp8.
Wouldn't see why it wouldn't work since it doesn't need to read any info on the actual partition it just copies whole thing to computer then copies whole thing to new card. Then expand it to your cards size.
Back then if you just copied using file explorer it would give error on start up but wp7 on an hd2 is WAYYY different not sure how much wp8 checks sd cards like that.
@reeg420 probably has the right idea here. It *might* work to just copy the filesystem contents, but if you want to be really sure you should copy at a lower level. Note that this will wipe the new card completely! I make no promises of this working in the case of an encrypted (BitLocker'd) card. Here's one way you could do it, if you have access to a Linux/OS X system:
* Insert the first SD card and figure out what device it maps to (I'm going to assume /dev/sdb for this tutorial).
* If the SD mounted automatically, unmount (eject, or 'umount' command) it.
* In a terminal, figure out where you'll want to place the temp file (this step can be skipped if you can mount both cards at a time, but that's rare). It'll be the size of the first card (32GB). It could be something like /tmp/sdclone or ~/sdclone or /dev/sdc if you're doing a direct copy without a temp file.
* Use the dd command ('man dd' if you want to learn more about it). For example:
Code:
dd if=/dev/sdb of=/tmp/sdclone bs=16m
* Once the dd command finishes (assuming it finished without errors), pull out the first sd card and put in the second (assuming you didn't direct-copy).
* Again, unmount the sd card if it auto-mounts. Then dd the temp file back onto the sd card (just switch the paths of the 'of' and 'if' parameters).
* Once the copy finishes successfully (you may want to try re-mounting the card to make sure it worked!) you can delete the temp file.
Of course, this will just give you a 64GB microSD card with a single 32GB partition and 32GB of unusable space. At that point, you can extend the partition into the remaining space. There are various ways to do this - on Linux you might use the 'parted' command or one of its graphical front-ends (gparted/qtparted) - but the easiest is probably to put the card in a Windows machine (or reboot into Windows if you're dual-booting) and use the Disk Management console ('diskmgmt.msc', if you want to use Search or Run).
A card cloned in this way *should* work just fine in your phone, but I haven't tested this.