LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 11-05-2011, 12:06 PM   #1
EnemyNL
LQ Newbie
 
Registered: Sep 2011
Posts: 4

Rep: Reputation: Disabled
1 on 1 copy of a sd card, different sizes?


So im having a bit of a problem here, situation is this:

I have a sd card that contains two partition. The sd card hold linux along with some tools.

Now i need to make a lot of copies of this sd card, so i created a image file from the source sd card.

Writing back this file to a sd card of the exact same size works fine, however i have a few different types of sd card, all with different sizes (it only differs a few kb's). When i try to copy the source image to a sd card of a different size i get a error that the destination is to small to contain the image.

How can i copy the sd card, including the partition setup and all the files to the other sd cards that vary in size a bit?

Any help would be appreciated.

Thanks in advance!
 
Old 11-05-2011, 02:03 PM   #2
jefro
Moderator
 
Registered: Mar 2008
Posts: 17,937

Rep: Reputation: 2676Reputation: 2676Reputation: 2676Reputation: 2676Reputation: 2676Reputation: 2676Reputation: 2676Reputation: 2676Reputation: 2676Reputation: 2676Reputation: 2676
An sd card is a hard drive. In your case some part of it knows the geometry. Consider other tool like cat, tar or cpio or such to copy off based on file by file maybe.

Might even try clonezilla or partimage or such.

I used to make a qemu virtual machine out of dd images to then work with into other formats. It sometimes is easier to run them like that. You have the ability to make a hdb image that can match the format of the card in some cases.

Last edited by jefro; 11-05-2011 at 02:05 PM.
 
Old 11-05-2011, 02:46 PM   #3
Elv13
Member
 
Registered: Apr 2006
Location: Montreal,Quebec
Distribution: Gentoo
Posts: 825

Rep: Reputation: 129Reputation: 129
Just use "cp -a" or use a tar with "-p" to create the image (if you really -need- an image). Sometime, good old copy is just more flexible than ghost images. This is one of these time.
 
Old 11-05-2011, 03:41 PM   #4
EnemyNL
LQ Newbie
 
Registered: Sep 2011
Posts: 4

Original Poster
Rep: Reputation: Disabled
but will that also copy the partition layout of the sd card and the mbr and such? i don't think it will or should i copy the unmounted /dev/sdb somewhere and then copy that back to the other sd card?

Last edited by EnemyNL; 11-05-2011 at 03:45 PM.
 
Old 11-06-2011, 01:38 AM   #5
Elv13
Member
 
Registered: Apr 2006
Location: Montreal,Quebec
Distribution: Gentoo
Posts: 825

Rep: Reputation: 129Reputation: 129
No, it wont copy the FS, after all, you don't want it to copy the FS, it is the cause of your problem. Do a script that call parted, mkfs and cp. It's just 3-4 lines.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to copy packet to another network card? farkeu Linux - Networking 5 08-20-2009 04:47 AM
standard SDHC card sizes? ta0kira Linux - Hardware 0 04-04-2009 12:21 PM
define different physical sizes on Multiple Monitors of different sizes MasterC Linux - Desktop 2 03-18-2008 04:24 PM
Why do pictures from SD card copy to disk funny?? glenn69 Linux - General 3 12-09-2007 05:40 PM
Exact Copy of Compact Flash Card Onyx^ Linux - Software 1 09-01-2004 04:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:24 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration