LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 04-28-2006, 08:57 PM   #1
PipeDreams
Member
 
Registered: Dec 2005
Distribution: Mandriva 2006 x64
Posts: 161

Rep: Reputation: 30
Removable Media Problem


A strange thing has happened to my usb stick and my digicam memory card.

I had used both on only win xp until recently.

First thing was my digicam lost half of its storage space on the memcard.Then my usb stick appeared to have only 256MB(its a 512MB stick) when using windows.

When I'm using a linux distro and plug in the stick it appears as 2 removable drives?

One is the stuff I saved using win.(win can see this one also)The other is files I saved to the stick while using linux.

Is there a way I can format the stick and mostly my digicam memory card so the cam sees the rest of the memcard again?

Thanks
 
Old 04-28-2006, 09:12 PM   #2
IBall
Senior Member
 
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 62
One problem I had with mine some time ago was the .trash directory. I had deleted the files, but of course they went into the trash. Open up a terminal, cd to the USB stick (probably /media/usb) and run "du -sh *" and see what is taking up all the room. Also, try "df -h" to make sure that Linux sees the full size.

Make sure that you always umount the drive before removing it. Either run "umount /media/usb", assuming that is your usb drive, or right click on the icon and select Unmount. Not unmounting can lead to strange problems sometimes.

I hope this helps (but I may be wrong )
--Ian
 
Old 04-29-2006, 07:57 AM   #3
PipeDreams
Member
 
Registered: Dec 2005
Distribution: Mandriva 2006 x64
Posts: 161

Original Poster
Rep: Reputation: 30
[root@localhost jeff]# cd /dev/usb
[root@localhost usb]# du -sh
0 .
[root@localhost usb]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/hdc5 20G 4.5G 14G 25% /
/dev/hdc1 20G 18G 1.7G 92% /mnt/windows
/dev/sda1 50M 11M 40M 21% /mnt/removable
/dev/sda2 73M 266K 73M 1% /mnt/removable1

Hmmm what is "du -sh" supposed to say?

sda1 and sda2 are in fact one 512MB usb stick.I think something is wrong with it.

You were right about the trash.Thats when my cams memcard lost space is when I used Mandriva to read the pics and then I deleted them from the card(or so I thought).

Is there any saving the card or the usb drive?I'm not sure what to try?

Thanks for the help
 
Old 04-29-2006, 09:33 PM   #4
IBall
Senior Member
 
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 62
Does this drive have multiple partitions??? That is what it looks like, seeing as it is being recognised as sda1 and sda2. But surely you would have known if you partitioned your usb stick

"du -sh *" s to find out the individual disk usage of each file. That was just trying to find out if there is a hidden file taking up space.

Is it possible to use fdisk to partition a USB stick? Maybe someone who knows can reply before you stuff anything up on my say-so If so, you will be able to re-partition it.

I hope this helps
--Ian
 
Old 04-30-2006, 10:50 PM   #5
PipeDreams
Member
 
Registered: Dec 2005
Distribution: Mandriva 2006 x64
Posts: 161

Original Poster
Rep: Reputation: 30
Quote:
Does this drive have multiple partitions???
Thats what I suspect also.and no I havent partitioned them.Never really even thought about the xd card and the usb stick as having a file system.

Somehow from using them with different OS's has created a linux filesystem on a separate partition.I think this was created when I deleted(or moved to trash) pics and files.

I think xp wont admit to seeing the partition same way it does with hd partitions.

I will mess with the usb stick first and try some partitioning tools on it.

If I have any luck I'll post back.

Thanks for the help.
 
Old 05-01-2006, 01:03 AM   #6
IBall
Senior Member
 
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 62
USB drives usually have a FAT filing system, so they can be read by Windows and Linux and whatever else. So Linux can see both, but windows can see only one? Try using cfdisk to check out the partition table, "cfdisk /dev/sda" as root. It is possible that Mandriva may have created a new ext2 or ext3 partition out of the free space when it automounted it, but I have no idea why it would do that.

--Ian
 
Old 05-01-2006, 09:49 PM   #7
PipeDreams
Member
 
Registered: Dec 2005
Distribution: Mandriva 2006 x64
Posts: 161

Original Poster
Rep: Reputation: 30
cfdisk reports 2 primary partitions.sda1 is a "Fat16" and flagged boot.sda2 is "W95 Fat32".

I'll boot win and see which partition it is seeing and delete the other.

Will I have to resize the remaining partition?



Thanks
 
Old 05-03-2006, 09:47 PM   #8
IBall
Senior Member
 
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 62
Probably.

It may be easier to delete both, and then create a new FAT32 partition, that is the full size of the disk.

It would be interesting to know how you have ended up with two partitions though. I use my USB drive all the time between Linux and Windows, and I have never seen anything like this...

--Ian
 
Old 08-09-2007, 02:17 AM   #9
fiya kagalwala
LQ Newbie
 
Registered: Aug 2007
Posts: 1

Rep: Reputation: 0
how to maintain mailserver

how to install,configure and maitain mailserver
 
Old 08-09-2007, 05:46 AM   #10
IBall
Senior Member
 
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 62
Quote:
Originally Posted by fiya kagalwala
how to install,configure and maitain mailserver
Wouldn't this be better in a thread all of its own? Also, have you googled, read howtos etc. What distro and what mail server application?

--Ian
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with auto-mounting of removable media ggeeoo Linux - Hardware 2 01-27-2006 05:16 PM
mounting removable media matthewa Linux - Hardware 2 11-12-2005 09:44 PM
How to mount a removable media using C skie_knite007 Programming 1 10-02-2005 12:49 AM
Mounting removable media george_mercury Linux - General 1 07-28-2004 11:14 AM
Problem with accessing removable media kcreagh Linux - Newbie 1 08-04-2003 09:54 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 08:30 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