Help answer threads with 0 replies.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 12-31-2006, 03:03 PM   #1
LQ Newbie
Registered: Dec 2006
Location: Springfield, MO
Distribution: Linux Mint 2.1
Posts: 6

Rep: Reputation: 0
Post fat32 partition contains data in linux not in windows

Laptop with 80 GB HDD, 1 GB RAM, etc.
Was shipped running XP as on NTFS partition
I backed up all my data (approx 40 GB worth) and did the following:

Booted to Linux Mint 2.1 (Bea) Live CD
ran sudo gparted
resized the NTFS partition to approx 20 GB
setup an approximately 40 GB FAT32 partition for my data (to share between OS's)
Installed Linux Mint

Started figuring out how to setup a partition to share data between XP and Linux. Found out FAT32 is best to use and set it up.

here is results of fdisk-l

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 1 6 48163+ de Dell Utility
/dev/sda2 * 7 2826 22651650 7 HPFS/NTFS
/dev/sda3 2827 7838 40258890 b W95 FAT32
/dev/sda4 7839 9729 15189457+ 5 Extended
/dev/sda5 * 7839 9648 14538793+ 83 Linux
/dev/sda6 9649 9729 650601 82 Linux swap / Solaris

After fighting with /etc/fstab and mounting (and remounting) the drive, I made it possible to write data to the FAT32 partition.

It is setup as /osshare

Here is my /etc/fstab file
# /etc/fstab: static file system information.
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc defaults 0 0
# /dev/sda5
UUID=f5da5218-986c-4c82-81d7-e0fe0226c02f / ext3 defaults,errors=remount-ro 0 1

# /dev/sda6
UUID=49cf3fe5-e106-49dc-a90a-9d41f842db43 none swap sw 0 0
/dev/scd0 /media/cdrom0 udf,iso9660 user,noauto 0 0

# /dev/sda3
/dev/sda3 /osshare vfat iocharset=utf8,umask=000 0 0


I then copied all of my data back to the drive, under Linux. (This happens much faster in Linux than windows for some reason - using USB 2.0 external disk)

When I reboot and go back into Windows XP, the disk exists, shows up as my D: drive and is sized correctly.

Here is the PROBLEM:
In Windows XP, the drive is empty. The size is correct, but the drive is void of any data.
Just to be sure, I reboot and go back into Linux. Drive exists, data intact.

I am afraid to start writing data inside XP, as I don't know what will happen.
I still have my all my data backed up and could start over, but let's just say getting the FAT32 partition to mount properly wasn't any fun. I've been working with PCs for over 10 years and this has been a bugger. Some parts of Linux are nice; others are insanely and unnecessarily difficult.

In the end:

Why is this happening and how can I fix it?

Last edited by tdemers; 12-31-2006 at 03:05 PM.
Old 12-31-2006, 03:15 PM   #2
Senior Member
Registered: Jan 2006
Location: Charleston, SC, USA
Distribution: Debian, Gentoo, Ubuntu, RHEL
Posts: 1,148
Blog Entries: 1

Rep: Reputation: 48
I'm no expert, but that sounds more like a windows problem than a linux issue. Not that we're going to hold it against you :-) , but you might have better luck with this question on a Windows board, where everyone is used to diagnosing Windows problems.

Here's a weird sneaky suspicion - does that FAT32 drive read properly without the external usb drive plugged in? Perhaps it copied so much faster in linux because it was only symlinking the files instead of actually copying the data. Then, when you open the partition in Windows, which can't handle such symlinks, it appears empty? It's a long shot, but maybe worth a try.
Old 12-31-2006, 03:26 PM   #3
LQ 5k Club
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,397
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
I would hazard a guess that the FAT partion is not actually mounted, and you are really storing your data in the linux filesystem at the mountpoint you intended to use. As root, run mount. It will display all of the currently mounted partitions and their respective mountpoints. If that doesn't rveal anything that leads to a fix, post the results of the mount command here, and someone may be able to point out a solution.
When figuring out a tricky partition mounting issue, I prefer to run mount/umount from the command line until I have iterated upon the correct/desired settings, and then translate the results to a compatible fstab entry. This removes the need to reboot to test each new setting.

--- rod.
Old 12-31-2006, 03:29 PM   #4
LQ Guru
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 62
My thought if the data was copied it was copied to /osshare directory but maybe the partition was not mounted to the directory at the time. Go into FC and run the command ' /sbin/mount ' to mounted partitions. Or use the command ' cat /proc/partitions '.

Old 12-31-2006, 04:23 PM   #5
LQ Newbie
Registered: Dec 2006
Location: Springfield, MO
Distribution: Linux Mint 2.1
Posts: 6

Original Poster
Rep: Reputation: 0
To answer the above questions:

1. It may be a windows issue, and I'll do what I can on that side.

2. I have the data on my system, and the USB external drive is no longer plugged in. Also, see below

The file system with Linux Mint installed is only 14 GB (with about 10GB free), whereas the FAT32 is about 40GB (with only 1.2 GB free). So, I'm pretty sure the data actually was copied over. Since about 20 GB of that was music, and I can play songs, so the data is live and legit.

I was having trouble getting the drive to mount, but have sinced resolved that. So, right now when I look at GParted, the drive pointing to /osshare is mounted. I made the mistake of NOT having it mounted and almost filled the / drive on my first file copy. See above for data volume.

Thank you each for your replies.
I will post more after I've been able to try the stuff listed and whatever else I can find.
Old 12-31-2006, 04:26 PM   #6
Senior Member
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Rep: Reputation: 112Reputation: 112
My theory is type "c" partition type should have been used. Partition type "b" in sda3 is fat32 too but not in LBA mode whereas Type "c" is. One must not forget Linux has no responsibility to make things compatible in Winodws. Fat16 has a maximum address limit of 2Gb but if you ask Linux to create one bigger then it Linux will do it but no MS system can cope with it.

Possible cure

In Linux use cfdisk to alter type "b" to type "c".
Old 12-31-2006, 04:44 PM   #7
Registered: Aug 2002
Posts: 16,156

Rep: Reputation: 1874Reputation: 1874Reputation: 1874Reputation: 1874Reputation: 1874Reputation: 1874Reputation: 1874Reputation: 1874Reputation: 1874Reputation: 1874Reputation: 1874
How did you create the filesystem? XP has a 32GB limitation so you would of had to format it in linux. As already stated check to see if sda3 is being mounted. If not your data is being written to sda5 instead. I also agree with saikee.
Old 12-31-2006, 04:58 PM   #8
LQ Newbie
Registered: Dec 2006
Location: Springfield, MO
Distribution: Linux Mint 2.1
Posts: 6

Original Poster
Rep: Reputation: 0

I used cfdisk to change the partition type to "c". That seemed to fix it.

In the interest of full disclosure, I also rebooted XP. I am wondering if the changes I made before would have been effective without that. One more reason to not like XP... reboot, reboot...

I created the filesystem in Linux, using GParted. I discovered the XP FAT32 limitation when trying to format a different drive recently. Thankfully, I don't have any files over 4GB, which is another limitation of FAT32...
sda3 is being mounted. All is working... for the moment.

Thanks!! I can access my data.
Now it's off to more problems. I'm sure I'll be posting again.


fat32, mount, partition, share

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
Data Transfer From Redhat Linux Partition to Fat32 Partition saraturtle Linux - General 20 04-04-2007 05:20 PM
Shared Linux/Windows partition WITHOUT FAT32 damiendusha Linux - Software 2 11-26-2006 04:36 PM
Windows Messed Up My FAT32 Data Partition--Using FC4 to Access Fails Trip in VA Fedora 6 10-29-2005 08:48 PM
Windows/Linux Fat32 Share partition problem Halsafar Linux - General 1 09-23-2005 07:17 PM
Linux partition over written with Fat32 data! hi-clier Linux - Newbie 2 11-21-2004 07:35 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:58 PM.

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