1 (edited by fleischwolf 2018-05-28 19:51:10)

Topic: Gparted can't read NTFS Partition

Hi,

I've created a bootable USB Stick to repartition my Windows Drive. But GParted can't read it:

Unable to read the contents of this file system!
Because of this some operations may be unavailable.

The cause might be a missing software package.
The following list of software packages is required for ntfs file system support: ntfsprogs / ntfs-3g.

But how do I add this to my USB Drive?

2

Re: Gparted can't read NTFS Partition

You can use GParted live in a USB stick. It contains all software pieces for the supported filesystems.

*** It is highly recommended to backup any important files before doing resize/move operations. ***

3

Re: Gparted can't read NTFS Partition

I did just that. Still the message comes up.

4

Re: Gparted can't read NTFS Partition

Do you used the latest Live version?
Ntfs support is included in the GParted live (unless you use any other bootable Linux stick with just GParted installed).
If you use the GParted live, then the error must be elsewhere.
You have to fully shutdown the operating system (not just hibernate or sleep) before booting GParted.

If this persists, try to run the command
chkdsk /f
from the windows command line prompt (the black dos window). I think you have to reply Yes to the question about scheduling the check for the next reboot, and allow the computer to reboot.

*** It is highly recommended to backup any important files before doing resize/move operations. ***

5 (edited by fleischwolf 2018-05-29 18:45:31)

Re: Gparted can't read NTFS Partition

I have the pmagic_2018_04_30 ISO.

I did chkdsk and now it recognises the partiton, but when I try to reformat it there is another error message when I apply the changes:

GParted 0.31.0 --enable-libparted-dmraid --enable-online-resize

Libparted 3.2.94-7188

Shrink /dev/sda4 from 681.89 GiB to 421.41 GiB  00:20:05    ( ERROR )
        
calibrate /dev/sda4  00:00:04    ( SUCCESS )
        
path: /dev/sda4 (partition)
start: 1697792
end: 1431719935
size: 1430022144 (681.89 GiB)
check file system on /dev/sda4 for errors and (if possible) fix them  00:00:37    ( SUCCESS )
        
ntfsresize -i -f -v '/dev/sda4'  00:00:37    ( SUCCESS )
        
ntfsresize v2017.3.23 (libntfs-3g)
Device name : /dev/sda4
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 732171334144 bytes (732172 MB)
Current device size: 732171337728 bytes (732172 MB)
Checking for bad sectors ...
Checking filesystem consistency ...
100.00 percent completed
Accounting clusters ...
Space in use : 446917 MB (61.0%)
Collecting resizing constraints ...
Estimating smallest shrunken size supported ...
File feature Last used at By inode
Multi-Record : 732172 MB 631241
$MFTMirr : 1 MB 1
Compressed : 701829 MB 637853
Sparse : 548563 MB 47325
Ordinary : 732172 MB 529073
You might resize at 446916767744 bytes or 446917 MB (freeing 285255 MB).
Please make a test run using both the -n and -s options before real resizing!
shrink file system  00:19:24    ( ERROR )
        
run simulation  00:19:24    ( ERROR )
        
ntfsresize --force --force -s 452481515520 --no-action '/dev/sda4'  00:19:24    ( ERROR )
        
ntfsresize v2017.3.23 (libntfs-3g)
Device name : /dev/sda4
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 732171334144 bytes (732172 MB)
Current device size: 732171337728 bytes (732172 MB)
New volume size : 452481511936 bytes (452482 MB)
Checking filesystem consistency ...
100.00 percent completed
Accounting clusters ...
Space in use : 446917 MB (61.0%)
Collecting resizing constraints ...
Needed relocations : 55959403 (229210 MB)
Schedule chkdsk for NTFS consistency check at Windows boot time ...
Resetting $LogFile ... (this might take a while)
Relocating needed data ...
100.00 percent completed
allocated extent inode 15
allocated extent inode 15
allocated extent inode 15
allocated extent inode 15
Updating $BadClust file ...
Updating $Bitmap file ...
ERROR(5): Could not open inode 285562 through the library: Input/output error
========================================

Create Primary Partition #1 (ntfs, 260.48 GiB) on /dev/sda
========================================

6

Re: Gparted can't read NTFS Partition

ERROR(5): Could not open inode 285562 through the library: Input/output error

Input/output error means probably that there was a hardware error related to the disk operations. It can be a bad cluster, a controller error or even a loose cable or a connector problem.
You can check connections. Furthermore you can check the dmesg output {as root) for any hardware-related error.

The "sudo smartctl -a /dev/sda "  output  is another source of info on the general hard drive health. Very often, a dying hard drive behaves strangely for some time before stopping. The GParted livecd includes the GSMartControl application, I don't know if it is included in the pmagic.

*** It is highly recommended to backup any important files before doing resize/move operations. ***