Page 1 of 1

[ntfs] <unknown> label is assigned after recovering

Posted: Wed Feb 24, 2010 10:45 am
by robertchen
Version: fsarchiver 0.6.6
Issue: Use fsarchiver to savefs then restfs a windows NTFS partition. Before restoring, the partition is not labeled (partition with empty label will be show "Local Disk" in Windows). After recovering, the partition is labeled "<unknown>". This is strange.

Earlier verisions (my experience: 0.5.8 to 0.6.2) of fsarchiver have no this problem.

Re: [ntfs] <unknown> label is assigned after recovering

Posted: Wed Feb 24, 2010 2:52 pm
by admin
New fsarchiver versions (>= 0.6.4) are using libblkid to read labels from ntfs filesystems. It replaces some code which was in fs_ntfs.c before, and then it's less maintenance.

I suspect that libblkid returns "<unknown>" for empty disk labels during the savefs. And then fsarchiver literally saves this string as a label. You can check that by running "blkid" on a system which has an ntfs partition with no label.

But is that a real problem ?

Re: [ntfs] <unknown> label is assigned after recovering

Posted: Thu Feb 25, 2010 2:55 am
by robertchen
Is it because the default label string becomes "<unknown>" in newer versions ?

In get_devinfo () in devinfo.c (v0.6.6), we have the following modification:

Code: Select all

    snprintf(outdev->label, sizeof(outdev->label), "");
    snprintf(outdev->uuid, sizeof(outdev->uuid), "");
    snprintf(outdev->fsname, sizeof(outdev->fsname), "");
    //snprintf(outdev->label, sizeof(outdev->label), "<unknown>");
    //snprintf(outdev->uuid, sizeof(outdev->uuid), "<unknown>");
    //snprintf(outdev->fsname, sizeof(outdev->fsname), "<unknown>");
I've used the modified version to savefs then restfs, it works fine for my NTFS partition.

Re: [ntfs] <unknown> label is assigned after recovering

Posted: Thu Feb 25, 2010 12:22 pm
by admin
You are right, it must be due to that modification. Thanks

Re: [ntfs] <unknown> label is assigned after recovering

Posted: Thu Sep 02, 2010 5:07 pm
by Dukers
FSArchiver 0.6.10 still put "<unknown>" into non labeled NTFS partitions after restfs.

Re: [ntfs] <unknown> label is assigned after recovering

Posted: Fri Jun 15, 2012 2:17 am
by Dukers
admin, this bug is still preset in fsarchvier 0.6.15. Can't the change posted by robertchen be applied?

Ah, BTW, is that workaround for blkid < 1.41 necessary these days? libblkid 1.41 shipped four years ago and the first util-linux release containing it (2.15), more than three years ago.