convert NTFS to XFS without loosing data
- Anmelden oder Registrieren um Kommentare zu schreiben
Hello everybody, I am pretty new to gnu/linux trisquel but I love it. The question is in the title. So thank you in advance for your answers.
Please when creating a post, try to use a simple title and then write the whole idea/problem/proposition (again if necessary) in the post itself. That would help in terms of organization so more people could help you.
As for you problem. As much as I know it is not possible (at least I didn't find a way to do it). The better way to do it, is just to copy the files to another device, then format the first one in XFS (Just as an advice, XFS is not very good with big files, so if it is only for storage maybe you should consider something like EXT4). So if there is enough free space on the device, just use a tool like Gparted ('''sudo apt-get install gparted''') in order to create a new partition (Ext4 or XFS) with the free space available, after that just copy the files (you can use '''rsync''' in the terminal, like that if it stops it will reboot the operation, or just use the well known drag-and-drop solution), after all that remove the NTFS partition and simply add that free space to the XFS partition.
Hope it helps.
PS: I'm pretty sure (99%) that there isn't any direct solution. BUT if I find any I will report it at you.
PSS: Welcome to the Trisquel Community !
It actually is the opposite: XFS' performance rocks with large files (thanks to extents and the ability to adaptively use larger blocks). That is why it is the default filesystem of Trisquel's /home.
I personally always saw the inverse in benchmarks :s... XFS Being better with a large amount of small files than the inverse, but I can be wrong.
A long time has passed since the last time that I used XFS but as far as I know there is the problem of now being shrinkable (an this can be problematic for a lot of people), but this is not the point here.
I will study a little more the subject (I've only seen the Phoronix benchmarks so far and some "specialized" blogs).
http://www.phoronix.com/scan.php?page=article&item=ubuntu_1204_fs&num=1
Hello, sorry for title I didn't know that.
Your solution is the first I thought also but I dont have enough space to do that. I have to borrow an external drive somewhere :-).
Your comment about XFS is disturbing, I have big files like videos minimum 700 MB but also small files like songs 5 MB or pictures. What should I choose ?
I asked about XFS because I saw that Trisquel installs automatically a XFS partition for home.
Thanks again.
Maybe I express myself in the wrong way xD All free file system are good for any use, the real "issue" is a performance one. As an example :
- People with Netbooks or SSD's mostly choose EXT2 (because it isn't a journalised file system and because of that there is less writing in the disk, but no recovery also because of this).
- People with a lot of files (mostly small size) will choose the XFS, because it handles them more quickly. Trisquel selects the XFS for the home partition (mostly) in order to increase speed since rares will be the big files in the Home partition (remember about all the documents, musics, configurations etc..)
- Ext4 will be preferred for the System itself.
Apart of that you will have the Ext2, Ext3, Ext4, XFS, Btrfs etc.. to choose on xD And all with a principal purpose. Many Gnu/Linux "advanced" people will (as an example) create an "opt","home","var","tmp" etc... partition with different sizes and different file-systems because of the different needs.
And, if you watch some benchmarks you will notice that nowadays there is only a little difference between EXT4 and XFS in most cases (with big and small sized files).
It is only my opinion nothing more xD
For my case, when I switched for Trisquel Gnu/Linux (and Parabola Gnu/Linux) I decided to create 3 partitions :
1 - GPT for Grub (4 MB)
2 - Swap Partition (6144 MB)
3 - Ext4 Partition "/" (Rest of the Space)
Mostly because I wanted to use GPT and because I am lazy and don't want to create various partitions xD (even knowing that a separate /home/ partion would be a wonderful idea :D). But When I install Trisquel Gnu/Linux I always choose the EXT4 mostly because I am more familiar with the tools nothing more nothing else. But once again that is only me xD (Even if I agree that XFS is better for a Home Partition tho).
etc...
/home contains large files... and that is why, by default, Trisquels chooses the XFS filesystem for them! In benchmarks, "small" means tens of kB. There are many such files in the system. For instance, in /var, I have 11702 files weighting less than 10kB:
$ sudo find /var -size -10k | wc -l
11702
There are, in the Linux kernel, several filesystems that specifically target SSD devices. They probably are better choices that ext2.
As for ext4, which is a good filesystem, its choice is usually based on its stability (it derives from ext3, itself deriving from ext2, and has been extensively tested) and the availability of many tools for it.
Beside laziness, another reason to prefer less partitions is to avoid the problem of dimensioning them. Done wrong, you quickly end up with a full partition while other partitions are almost empty. When facing this problem, XFS is a pain in the ass since it cannot be shrunk.
Indeed, the laziness problem can be quickly solved with a USB Pen with parted live (or even Trisquel LiveCD) and resize everything. I personally never trusted the idea of having the same /home directory when you have 2 distribution, one being rolling distribution (Parabola Gnu/Linux) and a not-rolling distribution (Trisquel Gnu/Linux), don't know why xD
I never had a SSD so I never looked at this in details (always heard of the ext2 being a solution here and there).
As for EXT4 being stable, I don't really know after an announce like this:
http://www.phoronix.com/scan.php?page=news_item&px=MTIxNDQ
and this
http://www.phoronix.com/scan.php?page=news_item&px=MTIxNTE
As for the ext4 corruption bug, I do not know if it was written in this forum but there was nothing to panic about:
We can, therefore, confidently assume that our data is safe on Ext4 – or at least that it is safer than it would be on other Linux filesystems
Thanks for the information :D I seriously don't see any problems with EXT4 to be honest. The only "if" that I see is when I try to extract a 7GB iso from multiple .rar or .zip files and it takes 11minutes where on the same Operating System, with the same techniques and tools but using an NTFS partition, it takes 3minutes. Other than that I don't see any problem or issue :D
As aliasbody wrote, you can shrink an NTFS filesystem to create free space on the disk where you create a new partition with XFS as a filesystem. As a consequence, if the "fill-rate" of your NTFS is below 50% (a bit more actually because I guess XFS has a larger overhead, i.e., needs to write more meta-data) or if you can remove some files to go below 50%, then your problem can be solved with no additional copy (you will need to defragment the NTFS filesystem so that all data are grouped in the same region of the disk though). Once the data copied to the XFS partition (since GNU/Linux can read NTFS partitions, it is trivial and can even be done with a graphical file browser), you can erase the partition with NTFS and grow the partition with XFS.
By the way, XFS partition cannot be shrunk. This probably the worst drawback of XFS.
Notice that, if you can, it is always safer to copy the (crucial) data elsewhere. Have you thought of DVDs? It will take ages but it is a solution.
I recommend you to manipulate partitions from a Live medium such as a Trisquel Live CD/USB key. In this way the hard disk is not solicited by the system. As aliasbody rote, GParted (included on Trisquel's ISOs) is a user-friendly interface to do such manipulations.
As for file sizes, 5 MB *is* large. By small files, we means files up to tens of kB.
One day Btrfs will be stable enough to be used by default.
- Anmelden oder Registrieren um Kommentare zu schreiben