LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-06-2010, 02:52 PM   #1
ravedog
Member
 
Registered: Jun 2009
Distribution: Ubuntu, Sabayon
Posts: 38

Rep: Reputation: 0
usb cloning


Hey guys!

Is there a good way from the shell to copy/clone a usb stick that have several partitions?

Thanks in advance guys!

/R
 
Old 05-06-2010, 03:17 PM   #2
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Rep: Reputation: 112Reputation: 112
I would not recommend it as different USB manufacturers have different geometries on the USB devices so cloning, based on hdd geometry can be hazardous.

Files copying should be a lot safer.
 
Old 05-06-2010, 03:46 PM   #3
ravedog
Member
 
Registered: Jun 2009
Distribution: Ubuntu, Sabayon
Posts: 38

Original Poster
Rep: Reputation: 0
Hi!

Ok, I absolutely see your point in that. However this is a major mayhem to copy file for file on this stick as its intended to be distributed to many people in my team and has several partitions (partitions in various flavours so manual partitioning is needed as well on that sucker in that case) so i'm more than willing to either buy same usb keys if that is needed or try on the ones we got.

Thanks for replying m8!

/R
 
Old 05-06-2010, 03:51 PM   #4
custangro
Senior Member
 
Registered: Nov 2006
Location: California
Distribution: Fedora , CentOS , RHEL
Posts: 1,977
Blog Entries: 1

Rep: Reputation: 209Reputation: 209Reputation: 209
Quote:
Originally Posted by ravedog View Post
Hi!

Ok, I absolutely see your point in that. However this is a major mayhem to copy file for file on this stick as its intended to be distributed to many people in my team and has several partitions (partitions in various flavours so manual partitioning is needed as well on that sucker in that case) so i'm more than willing to either buy same usb keys if that is needed or try on the ones we got.

Thanks for replying m8!

/R
You can use DD or rsync...

DD is a block for block copy and an RSYNC is more like a "streamlined" cp command (it does more than just copy but that's the "spirit" of it anyway)...

SO depending on what you want to do...

plug in both of your USB sticks and show me the output of

Code:
df -h
AND

Code:
fdisk -l
Note for the fdisk command you have to be root (or use sudo)

-C
 
Old 05-06-2010, 04:19 PM   #5
ravedog
Member
 
Registered: Jun 2009
Distribution: Ubuntu, Sabayon
Posts: 38

Original Poster
Rep: Reputation: 0
Hi!

I will do that asap when i get back home. I didn't think that dd would take for example /dev/sde and get all partitions (raw), I always thought you needed to specify the exact partition and but that use it on partition after partition (which wouldn't help me).

br,

R

Last edited by ravedog; 05-06-2010 at 04:22 PM. Reason: type-os n stuff :)
 
Old 05-06-2010, 04:47 PM   #6
custangro
Senior Member
 
Registered: Nov 2006
Location: California
Distribution: Fedora , CentOS , RHEL
Posts: 1,977
Blog Entries: 1

Rep: Reputation: 209Reputation: 209Reputation: 209
Quote:
Originally Posted by ravedog View Post
Hi!

I will do that asap when i get back home. I didn't think that dd would take for example /dev/sde and get all partitions (raw), I always thought you needed to specify the exact partition and but that use it on partition after partition (which wouldn't help me).

br,

R
Yes you can do the entire disk or per partition...its flexible like that

-C
 
  


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
Cloning USB drives using C++ greenberet Programming 3 02-24-2010 05:11 AM
Cloning USB stick question Packrat1947 Linux - Newbie 7 12-05-2009 07:11 AM
Cloning HD using USB fraidycat Linux - General 8 02-22-2007 03:35 PM
cloning cpvjagadeesh Linux - Software 1 04-11-2005 06:09 AM
cloning with DD and NC scoob8000 Linux - Software 3 11-12-2004 12:34 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:34 PM.

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