LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Exfat Partitions created in Linux not readable in Windows or Mac OS X (https://www.linuxquestions.org/questions/linux-software-2/exfat-partitions-created-in-linux-not-readable-in-windows-or-mac-os-x-4175575119/)

DaneM 03-17-2016 02:52 AM

Exfat Partitions created in Linux not readable in Windows or Mac OS X
 
This issue has been solved. Solution in post #8.

I've been having an ongoing problem with making external media that I format to exfat readable on other operating systems. Here's what I've been doing. (Linux Mint 17.3)

-Install exfat-fuse and exfat-utils
-Create GPT label in GParted
-Create empty partition using GParted--however, GParted doesn't recognize the ability to format to exfat; so....
-Create exfat partition using the command:
Code:

mkfs.exfat -n <volume label> /dev/sdXY
X = drive letter
Y = partition number

With other partition types, this general method works like a charm: partitions aligned copecetically, filesystem created and readable without issue. However, when I try to do this with exfat, I consistently find that neither Windows nor Mac OS X computers are able to even detect that the device is formatted.

Is this a known bug? Am I doing it wrong? Please advise.

Thanks. :-)

jefro 03-17-2016 07:57 PM

Does diskpart or admin disk tool offer clues?


Generally exfat on windows is for external drives, I get the feeling that it may not like the gpt part and assumes it is an internal drive.

How did you get exfat support and is all programs and OS current?

DaneM 03-18-2016 01:31 AM

I don't currently have access to the malfunctioning devices, so it will take some further testing (when I have time) to generate some clues. The GPT label is a good lead to follow. I'll test it with an MSDOS label and see what I come up with. (Are those still the only two widely-compatible label types?)

Some further searching on Google indicates that some exfat partitions have problems being recognized in certain version of Mac OS and Windows, but I have yet to determine what the deciding factor is (size? GPT? something else?). Some suggestions indicate that large volumes (larger than what one can expect from a flash drive) might be the culprit...or not..?

I got exfat support in Linux Mint by installing the exfat-fuse and exfat-utils packages. Since it's using FUSE to mount the volumes, I assume that there isn't yet a proper kernel driver for exfat.

I've installed all updates for Mint 17.3 (Cinnamon), so I think it's as current as one can reasonably expect it to be.

Thanks for the probing questions! That gives me something to go on. I'll report back if/when I can come up with a definitive explanation for this anomalous activity.

DaneM 03-18-2016 06:45 PM

Update
 
I just formatted another drive as exfat: 650GB SATA II via a USB 2.0 adapter. (Yeah, some of my hardware is old...) I used the same procedure as before, but made an MSDOS label, instead of GPT. I plugged it into a Mac, and it asked me if I wanted to "initialize" (label, partition, format) it. I said yes, and chose the exfat option. Oddly enough, the default label type was GUID (A.K.A. GPT). It read/wrote to the GPT exfat drive just fine after formatting it thusly, but not when Linux had been used to format it.

This seems to rule out GPT as the culprit. Still looking into other possibilities.

jefro 03-18-2016 06:58 PM

I think you have to add in support for exfat in windows xp. What MS version of windows do you have?
Windows 7 and above with current updates should read exfat. GPT would work if you don't boot from it or install to it.

BW-userx 03-19-2016 07:30 AM

Quote:

Originally Posted by DaneM (Post 5517938)
I just formatted another drive as exfat: 650GB SATA II via a USB 2.0 adapter. (Yeah, some of my hardware is old...) I used the same procedure as before, but made an MSDOS label, instead of GPT. I plugged it into a Mac, and it asked me if I wanted to "initialize" (label, partition, format) it. I said yes, and chose the exfat option. Oddly enough, the default label type was GUID (A.K.A. GPT). It read/wrote to the GPT exfat drive just fine after formatting it thusly, but not when Linux had been used to format it.

This seems to rule out GPT as the culprit. Still looking into other possibilities.

I briefly did the same type of thing once, a while back. While installing my system I picked gpt instead of msdos then created my partitions to install Linux, and that failed. So I just went back and changed it to msdos partitions then created them marking them swap, ext4 respectfully. then my system installed without error. This was with me using cfdisk. Now I read your problem and it suggest to me, that it is a software thing in how it marks the disk partition type, and noting to do with the OS. In other words the way that the software marks the partitions are not compatible with the OS in how they read it for what ever the reason.

that is my thoughts on this. What to do about it? Write the programmer and let him know, perhaps even pose it as a question to him/her as to why it is not being recognized by other OS's that have the capabilities to read gpt and exfat but when using their software to make this it does not work, and ask them why. if for any other reason to do this - Just for peace of mind.

that is just my off the top of my head without thinking about it too hard option that is perfectly ready to be discarded by the reader at a moments notice, or not.

DaneM 03-20-2016 02:44 AM

Thanks for the replies!

I've tried reading these filesystems on Windows 7 and Mac OS X El Capitan, so far. I'll see if I can track down the developer of mkfs.exfat. Perhaps it's a known bug, or needs reporting...

Edit 1: I just sent an email to the packagers of the Ubuntu .deb, in hopes of finding out who to check with about known bugs, or whom to report bugs to. I also just found this, which I haven't yet had a chance to try:

https://www.reddit.com/r/osx/comment...linux_and_gpt/

Quote:

i solved it myself, you have to add the following line:
set 1 msftdata on

parted -a optimal /dev/sdX
mktable gpt
mkpart exFAT 0% -1
set 1 msftdata on
align-check opt 1
quit
parted /dev/sdX print

mkfs.exfat -n exFAT /dev/sdX1
Edit 2: The method suggested, above, doesn't work.

DaneM 03-30-2016 05:38 AM

SOLVED!

I just did the following, and it's readable/writable without errors on a Windows 10 native installation, as well as a Windows 10 VirtualBox guest (Linux host), and an Intel Mac. Apparently, Mac OS X expects a GPT partition table, so it's important to set it up that way for cross-platform readability. In the instructions, below, /dev/sde is the device I wish to partition, and /dev/sde1 will be formatted exfat.

As root:
Code:

dd if=/dev/zero of=/dev/sde bs=1M count=50      # wipe /dev/sde
partprobe /dev/sde                              # update partition information with OS; should be no partitions at this point
sudo gdisk /dev/sde                              # run utility for making GPT partitions

Create a new GPT table, then create a new partition that uses all the space. For type, input 0x0700 (basic Microsoft data). Don't forget to use "w" to write the new info.

Still as root:
Code:

partprobe /dev/sde                  # read partition table, again
mkexfatfs -n <label> /dev/sde1      # format /dev/sde1 as exfat, using user-specified label



All times are GMT -5. The time now is 06:56 AM.