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.

If I change my home from ext3 to ext4 when installing will my data be lost?

share|improve this question
add comment

4 Answers

up vote 2 down vote accepted

Yes. And you should be able to see that because the format box will automatically be checked. If you want to enable the two main features of ext4 that can be added without reformatting, run sudo tune2fs -O extents,uninit_bg /dev/sda1 and then sudo e2fsck -f /dev/sda1.

share|improve this answer
add comment

Where do you want to change it? As far as I can imagine, if you install new version of ubuntu, any selection about a new file system means destroying the previous. Since you mentioned "my home" (I am not sure you mean that /home is mounted as a separated filesystem), if I were you, I would simply skip using that fs, and later, you only need to edit /etc/fstab to mount your "old" /home. Note: if you choose ext4 fs there (but /home was ext3) this means some kind of "conversion" from ext3 to ext4 then (ext3 can be mounted az ext4, but if you do this even only at once, you can't "revert" it easily ...).

share|improve this answer
add comment

if you want your old ext3 partition to become ext4 you can easily convert it after you are done upgrading:

tune2fs -O extents,uninit_bg,dir_index /dev/sdb1

where /dev/sdb1 your 'home' partition, which has to be unmouned sudo umount /dev/sdb1 prior running the command. beware though that, as LGB mentioned, reverse conversion is not so trivial.

share|improve this answer
    
Ah, you're right, I forgot to mention in my answer that just mounting an ext3 as ext4 does not enable all fancy new functionality of ext4, some tune2fs can be useful to enable those too ... –  LGB Feb 14 '11 at 6:42
add comment

Not much to add as the how to has been said already. However consider this:

Before changing the filesystem on a preexisting partition it is strongly recommended to backup your data.

In the likely case that you already made your backup you may run the tools mentioned by psusi, or else you may find it less time consuming to simply restore your data in a brand new /home.

share|improve this answer
add comment

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.