Bug 910115

Summary: RFE: support ntfsresize --bad-sectors option in virt-resize
Product: [Community] Virtualization Tools Reporter: Richard W.M. Jones <rjones>
Component: libguestfsAssignee: Richard W.M. Jones <rjones>
Status: NEW --- QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: eblake
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2025-10-17 00:10:00 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Richard W.M. Jones 2013-02-11 21:08:04 UTC
Description of problem:

If a Windows guest has bad sectors (eg. if it came from a
physical machine) then virt-resize cannot resize it, because
the ntfsresize utility will refuse to run unless the --bad-sectors
option is specified.

We should either detect and add this option automatically (if
that is possible) or we should allow the user to specify this
option.

Version-Release number of selected component (if applicable):

libguestfs 1.21

(Suggested by Eric Blake)

Comment 1 Eric Blake 2013-02-11 21:19:54 UTC
Or even find a way to teach windows that there are no longer any bad sectors in the copy (perhaps by clearing or deleting the hidden $BadClust file), since the destination file is not the same block device as the source that had bad clusters in the first place.

Comment 2 Eric Blake 2013-02-17 23:25:58 UTC
Looks like 'ntfsfix --clear-bad-sectors /dev/...' is the way to modify the file system to force windows to quit treating sectors as bad.

Comment 3 Red Hat Bugzilla 2025-10-17 00:10:00 UTC
This product has been discontinued or is no longer tracked in Red Hat Bugzilla.

Comment 4 Alasdair Kergon 2025-10-17 12:52:13 UTC
Reopening because Virtualization Tools has not been discontinued.