Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Environment: I have a bunch of partitions across several drives. A precise, a wheezy, an arch, a windows 7 -install and multiple partitions with stuff.

What? So how can I hide the linux-world partitions from windows7? Especially if it complicates the task when there are encrypted volumes.

Why? Because everytime someone from my family starts windows and browses through "My Computer", clicking on one of the drives that it cant read, they are asked to format that partition. If someone did that to my stuff partitions, I'd go full insane.

share|improve this question
I wouldn't give them administrative priviledges. – Eric Carvalho May 16 '13 at 1:34

I'm guessing you are using GPT instead of the msdos partition table. It seems that for some time parted followed Microsoft's lead and used their GPT partition type code when creating partitions, and Ubuntu has not yet updated to a version that no longer does that. This causes Windows to assign the partition a drive letter, and when you try to open it, and it doesn't recognize the filesystem, it offers to format it. You need to change the partition type code to get Windows to ignore it.

sudo apt-get install gdisk
sudo gdisk /dev/sda

Use the gdisk command to change the type of the partition ( 1 in this example ) to the Linux type ( 8300 ).

share|improve this answer
Screenshots? Step by step? – Seth May 16 '13 at 2:57
@psusi it shouldn't have drive letters by default if it's ext4, should it? – Thomas Ward May 16 '13 at 3:08
@TheLordofTime, iirc, Windows automatically assigns it a drive letter based on the partition table type code, so either creating the partition with a non windows type code it won't get a drive letter, otherwise, you have to manually remove it. – psusi May 16 '13 at 3:18
@Seth, I haven't run Windows in a few years, so no can do. – psusi May 16 '13 at 3:18
@psusi then allow me to use a case-in-point: I have a dual-boot setup with Ubuntu 12.04 64bit as primary, and Windows 7 64bit OS as secondary. Windows 7 does not see the ext4 partition as readable, and doesn't assign a letter, because it sees the ext4 partitions as "Unknown" type, and doesn't assign a drive letter because it can't recognize the partition as readable (standard MS-DOS partition table format). (a professional partition editor, in windows, though, can see the Linux ext4 as ext4 but it still can't read/write to it) – Thomas Ward May 16 '13 at 3:22

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.