LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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-01-2006, 03:28 PM   #1
generalachoo
Member
 
Registered: Jul 2006
Posts: 56

Rep: Reputation: 15
USB key transfer


How do I transfer files to a USB key in the linux console!! I have no GUI. I am using Ubuntu server edition.

Thanks!
 
Old 11-01-2006, 04:02 PM   #2
Chromezero
Member
 
Registered: Nov 2004
Location: Arizona
Distribution: Slackware, RHEL, others
Posts: 470

Rep: Reputation: 40
Well, generally, you need to mount the USB drive first. Then copy the files over, as you would normally. So it would be something like...
Code:
mount /dev/sda1 /media/usb
cp files.files /media/usb/destination_folder
Keep in mind, you also need to have an entry in your /etc/fstab....
 
Old 11-01-2006, 06:21 PM   #3
generalachoo
Member
 
Registered: Jul 2006
Posts: 56

Original Poster
Rep: Reputation: 15
Hmm

So if i wanted to transfer the folder

/home/john/ on the computer to the usb stick what would be the syntax? I do not get the .files thing.

Thanks a lot!
 
Old 11-01-2006, 07:10 PM   #4
Chromezero
Member
 
Registered: Nov 2004
Location: Arizona
Distribution: Slackware, RHEL, others
Posts: 470

Rep: Reputation: 40
Well if it's a directory, you would want to use "cp -r" like this.
Code:
cp -r /home/john/ /media/usb/
The -r means "recursive", telling it to copy everything in the directory. For the most part, doing things on a USB thumb drive are no different than doing them on your hard drive. For more information about the "cp" command, check out the man.
Code:
man cp
 
Old 11-01-2006, 11:49 PM   #5
generalachoo
Member
 
Registered: Jul 2006
Posts: 56

Original Poster
Rep: Reputation: 15
Thank you very much for your help. I got it to work. I like the line about thinking about it like your hdd.

Sorry if my questions seemed silly.
 
Old 11-02-2006, 09:43 AM   #6
Chromezero
Member
 
Registered: Nov 2004
Location: Arizona
Distribution: Slackware, RHEL, others
Posts: 470

Rep: Reputation: 40
There's nothing wrong with asking questions. How else are you going to learn? Glad to hear it's working.
 
  


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
usb stalling during file transfer azjulian Fedora 2 07-28-2006 11:31 AM
Install on USB to transfer to another HD cosmo289 Mandriva 6 06-21-2006 08:46 PM
USB Blocking PC on transfer MBH Linux - Hardware 2 05-27-2006 03:00 PM
USB LexarMedia 32MB Data-Key + KDE 3.2=USB/HD Access problems that_guy Slackware 0 02-03-2005 08:27 AM
How to get the USB 2.0 transfer to/from the external hdd? baronlynx Linux - Newbie 4 01-19-2004 03:44 PM

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

All times are GMT -5. The time now is 12:47 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
Open Source Consulting | Domain Registration