I'm using an external HDD which is my old laptop's HD with 2.5 SATA enclosure. I tried to delete a partition in Windows and stopped it unknowingly. When I reinsert it, my OS including Ubuntu freezes and sets some duplicate partition link in the launcher. Windows too failed the test.

Here's the screen of disks utility: enter image description here

The drive is 320GB HD which is taken during the freeze. I unplugged it and plugged it and here the output screen of the command dmesg:

dmesg output screen

As you can see the value 6** keeps incrementing. I know that the drive is corrupted. But, how can I flash it. I already took a backup of everything in this drive. Is there any way to format fully and get the drive back?

UPDATE: When I inserted my disk the system freezes as I cannot use it further until I unplug the drive and it creates some duplicate copies of the two partitions I had in the disk(68 and 55GB). And even one partition I named as Misc is also shown below:

enter image description here


Start by disabling automount with:

gsettings set org.gnome.desktop.media-handling automount false 

You can re-enable it when you finish changing false to true.

Option 1 - Gparted

Install gparted with sudo apt-get install gparted or use Software Center.

Then in gparted select the correct disk and choose "Create partition table" from the Device menu. You'll have a fresh partition table. Then create partitions as needed.

Option 2 - Disks

If gparted doesn't see the disk but "Disks" does, in the latter click the cog button and choose "Format".

Option 3 - Fdisk

If even that fails, try fdisk from the command line:

  1. Identify the disk with sudo fdisk -l. Let us say your disk is /dev/sdb
  2. Type sudo fdisk /dev/sdb change the disk name appropriately
  3. Choose the w option - Write partition table
| improve this answer | |
  • I tried that already, the disk is not shown in the disk selection. – Gowtham Gopalakrishnan Nov 8 '14 at 2:32
  • See modified answer. – To Do Nov 8 '14 at 9:29
  • I tried to do that, but it freezes the entire Operating System and cannot proceed further. Are there any other ways like formatting through CLI? – Gowtham Gopalakrishnan Nov 8 '14 at 12:49
  • I added the cli manner of writing partition tables. – To Do Nov 8 '14 at 17:20
  • 1
    You can disable automount with gsettings set org.gnome.desktop.media-handling automount false or gsettings set org.gnome.desktop.media-handling automount-open false – To Do Nov 9 '14 at 8:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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