473,405 Members | 2,160 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

read a usb flash drive in linux

111 100+
Hi, i'm new to linux, so this may be a really silly question.

But i've got this linux system (Red hat)
and i have a usb stick with some files on it.

i want to basically plug in my usb stick into the linux box, and save the files from the usb stick onto a directory on the linux machine.

The problem is when i plug my usb stick into the linux box, how do i know where it is. i.e. where is that drive

for example in windows, when you plug in a usb memory stick, a new drive is created in the "My Computer" folder. then by clicking on the new drive you would have access to the files on the usb.

thanks in advance
Aug 28 '07 #1
2 5236
Nepomuk
3,112 Expert 2GB
Hi, i'm new to linux, so this may be a really silly question.

But i've got this linux system (Red hat)
and i have a usb stick with some files on it.

i want to basically plug in my usb stick into the linux box, and save the files from the usb stick onto a directory on the linux machine.

The problem is when i plug my usb stick into the linux box, how do i know where it is. i.e. where is that drive

for example in windows, when you plug in a usb memory stick, a new drive is created in the "My Computer" folder. then by clicking on the new drive you would have access to the files on the usb.

thanks in advance
I don't know, if your Red Hat mounts the USB Stick automaticly, but you can check:
Use the console (always a good idea) and type
Expand|Select|Wrap|Line Numbers
  1. mount
  2.  
This will list all mounted devices. If one of them is called "sda", "sda1", "sdb", "sdb1" or similar, it's probably allready mounted and it will tell you, where it is mounted to.

If it isn't mounted, first of all you'll have to find out, which device it is. Use
Expand|Select|Wrap|Line Numbers
  1. ls /etc/sd*
  2.  
to list all "special devices". Your USB Stick will be one of them. Then you'll need a place to mount it to - normaly "/media/sda1" or "/mnt/sda1" (or equivalent). Create such a folder with mkdir directory (you can of course create it anywhere you like)
.

Now you have to be root (or have root priviliges, e.g. with sudo) - use:
Expand|Select|Wrap|Line Numbers
  1. mount /dev/sda1 -t auto /media/sda1
  2.  
(replacing the device and directory with those aplicable.)

Done! You USB Stick should be mounted.
Aug 28 '07 #2
nitinpatel1117
111 100+
Thanks nepomok,

That was great.

the ls /etc/sd* list command didn't work for me, luckily the mount command worked and did the job.
Aug 28 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: news | last post by:
OP wrote: }in order to justify learning another language I'd first need to be }convinced that python could easily do the following:- } }ReadSectors2Bufr(hdx, StartSectr, SectrCnt, Bufr); <-- like...
5
by: will.leighton | last post by:
I am working on concept where I want to deliver web-based content and functionality from a USB Flash drive for users who don't have access to the Internet. The functionality includes personaliztion...
3
by: Mike Joyce | last post by:
I am trying to write a portable script that will find removable media, such as compact flash, sd card, usb, etc. drive and then upload files from the media. I want this to be portable so that I can...
3
by: Putty | last post by:
Is there such a thing as a special version of python that I can run more efficiently from a flash drive? I'll be at college for hours every day with hours of free time for the next few months, but...
3
by: ryancol | last post by:
I have a couple usb 2.0 flash drives. I use them on either windows 2000 or windows XP. When I copy (drag and drop) a file folder to them such as a file folder with like 10 or 20 pictures in it the...
0
Chrisjc
by: Chrisjc | last post by:
<Excerpted from this thread> All of these questions and answers are great. But it comes down to this I have seen this more than enough times to know better... From my experience at home and as...
3
kestrel
by: kestrel | last post by:
Hey, I have an 8 gb flash drive. ive been using it to transfer all of my music from one computer (linux) to another (windows xp, if it really matters). After all my transfers were completed, i stuck...
8
by: Salad | last post by:
I was asked to get my daughter a flash drive. She needs to use it to copy files to it so she can transfer the files at school to her desktop at home. I've never used one but I figure some of...
0
by: Daffydd | last post by:
Hi all, This one's driving me up a wall! We have a small office network, Windows SBS 2003, nothing fancy - recently upgraded from an old Compaq running Novell. Back in the day we used the "F"...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.