Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Am trying to format a drive with Disk Utility and everytime i try to format this pen drive i get 'Daemon Is Inhibited' error. How can it be solved since the pen drive works on other PCs with no problem.

UPDATE
The device is not mounted.
The device is one of those usb pen drives with U3 support.
It is a Sandisk 8GB Pen drive with Fat32 Partition.

share|improve this question
    
Is the drive mounted perchance? The daemon might be blocked from modifying the file system if the drive is mounted –  crasic May 20 '11 at 1:24
    
Updated to include any relevant questions. Thanks crasic –  Luis Alvarado May 20 '11 at 1:37
    
have you come across this thread? Maybe sudo killall udisks or some of the other suggestions will work? ubuntuforums.org/showthread.php?t=1604563&page=2 –  fossfreedom May 28 '11 at 15:45
1  
You might be interested at How do I get rid of “U3 System” on my USB drive? –  Lekensteyn May 28 '11 at 15:50
    
Thank you Lekensteyn. Nice post. –  Luis Alvarado May 28 '11 at 19:22

1 Answer 1

up vote 1 down vote accepted

First, per my comment make sure that the drive isn't mounted (in case it was automounted on plugin).

Ubuntu typically automounts in /media so you can check if anything is mounted in that directory either through nautilus (or any other FS browser) or with ls /media. unmount by running the command sudo umount /media/mount-point-name. You can also check to see if the drive is mounted by opening nautilus and looking at the panel to the left. enter image description here As you can see the drive "Recovery" is currently mounted, clicking on the eject symbol would unmount the drive. A third way to check would be to run the command df -h which lists mounted filesystems (the -h just displays the drive size in human readable form), if the drive is mounted somewhere other than /media or nautilus refuses to unmount you can use the information there to find where it is mounted. As shown in this screen shot, df tells me that the drive /dev/sda7 which is a 4.6GB filesystem is mounted at /media/Recovery

enter image description here

Ok, Now moving on. The "standard" filesystem for linux/unix (excluding OSX) is ext2. However, reading it on other platforms is a little problematic (requires extra drivers for OSX and windows). Ext3 and Ext4 support is even worse. Typically, drives that are required to be shared between different systems are formated in FAT32, the "defacto" universal filesystem. Disk Utility should be able to format Fat32 (make sure that is the filesystem you pick when prompted), but if the above steps fail to fix Disk Utility there are plenty of ways around it.

Personally I prefer to use gparted which is a fairly powerful partitioning utility (actually a GUI wrapper around parted). Install gparted by running sudo apt-get install gparted or by using ubuntu software center. Run gparted either through the terminal (sudo gparted - sudo because we need root privileges to modify filesystems) or a shortcut is typically under System->Administration->Gparted in the Ubuntu (non-unity) task bar.

enter image description here

With Gparted open, in the top right select the drive that corresponds to your USB drive. If there are any filesystems on the drive (for me /dev/sda is the only drive and it has 5 partitions they will be listed in the area below. Delete all the partitions on the USB drive (right click on each one and select delete). What will be remaining is a "unallocated" partition the size of your drive, right click on it and select new.

enter image description here

In the popup box make the partition the full size of the drive and make sure to select FAT32 under filesystem. After closing the dialog, click the checkmark in the top right to write the changes to disk (NOTE: MAKE SURE YOU ARE MODIFYING THE RIGHT DRIVE, CHANGING THE PARTITION TABLE AND FORMATING OF YOUR MAIN DRIVE BY ACCIDENT COULD BE DISASTROUS)

EDIT: If fat32 is not an available option for gparted/DiskUtility make sure that that the package dosfstools is installed.

share|improve this answer

Your Answer

 
discard

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.