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

I installed Ubuntu 12.10, and I don't know why, I have an ext2 partition.

  • How can I convert this ext2 file system to an ext4?
  • Will I lose all my data?
share|improve this question
up vote 6 down vote accepted

Follow the instructions detailed in this post: Convert ext2/3 to ext4

share|improve this answer
Will I lose all my data? How do I know if my boot partition is SEPARATE? Should I do the Step 3 or not? – Lucio Nov 2 '12 at 19:21
You won't lose you're data, unless you do something incorrectly. If you're worried about data loss, you should always back it up somewhere else first. You can use mount to show what partitions are mounted where. You can also run sudo parted list to print a list of partitions. – dobey Nov 2 '12 at 20:14
The command sudo parted list doesn't work, but sudo parted -l does. – Lucio Jan 13 '13 at 22:23
Note that this only enables some of the features of ext4. Some can not be enabled without reformatting. – psusi Aug 26 '13 at 2:21

The short version for the impatient:

dev=/dev/sdXn # <-- Adjust this


umount $dev && tune2fs -O extents,uninit_bg,dir_index,has_journal $dev && e2fsck -v -pf $dev

If you cannot unmount because it's your system partition, then of course you will need to first boot from another system like a Live CD.

And no, you will not lose data. Unless something very weird happens, in which case you will have to reach to your backup. (You do have backups, of course. Right?)

share|improve this answer
  • Reformat the drive
  • Yes

As an alternative, you can enable some of the features of ext4 by running the following command, and rebooting:

sudo tune2fs -O has_journal,uninit_bg,extents /dev/sda1
share|improve this answer
The partition may not be /dev/sda1 ... ? – Clive van Hilten Nov 2 '12 at 18:39
@user30275, obviously.... – psusi Nov 2 '12 at 18:56
to psusi - in which case you should have pointed this out to the OP – Clive van Hilten Nov 3 '12 at 9:29

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.