13.07.2015 Views

[MS-VDS]: Virtual Disk Service (VDS) Protocol Specification

[MS-VDS]: Virtual Disk Service (VDS) Protocol Specification

[MS-VDS]: Virtual Disk Service (VDS) Protocol Specification

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

the current volume. This number is always a multiple of the file system cluster size, which isin turn a multiple of the disk sector size.Return Values: The method MUST return zero or a non-error HRESULT (as specified in [<strong>MS</strong>-ERREF]) to indicate success, or return an implementation-specific nonzero error code toindicate failure. For the HRESULT values predefined by the <strong>Virtual</strong> <strong>Disk</strong> <strong>Service</strong> Remote<strong>Protocol</strong>, see section 2.2.3.When the server receives this message, it MUST validate the following parameter:•Verify that pullMaxNumberOfReclaimableBytes is not NULL.The server MUST set values that pullMaxNumberOfReclaimableBytes references with themaximum number of bytes that can be reclaimed from the volume and then return an HRESULTindicating failure or success.3.4.5.2.35.2 IVdsVolumeShrink::Shrink (Opnum 4)The Shrink method shrinks the volume and all plexes, and then returns the released extents. TheShrink method compacts the files toward the beginning of the volume, creating free space at theend of the volume. The Shrink method also truncates the file system, reducing its size, and thentruncates the partition or dynamic volume.HRESULT Shrink([in] ULONGLONG ullDesiredNumberOfReclaimableBytes,[in] ULONGLONG ullMinNumberOfReclaimableBytes,[out] IVdsAsync** ppAsync);ullDesiredNumberOfReclaimableBytes: The desired number of bytes to be reclaimed fromthe volume. The method SHOULD attempt to reclaim the desired number of bytes as specifiedby this parameter. If it is unable to do so, it SHOULD attempt to reclaim a size smaller thanullDesiredNumberOfReclaimableBytes but greater than or equal toullMinNumberOfReclaimableBytes. Additionally ullMinNumberOfReclaimableBytesMUST be at least 1048576 bytes (1 MB). The actual number of bytes reclaimed is always amultiple of the file system cluster size, which is in turn a multiple of the disk sector size.ullMinNumberOfReclaimableBytes: The minimum number of bytes to be reclaimed from thevolume. If the method cannot reclaim at least the minimum number of bytes as specified bythis parameter, the method MUST fail and MUST NOT reclaim any bytes.ppAsync: A pointer to an IVdsAsync interface that, if the operation is successfully completed,receives the IVdsAsync interface to monitor and control this operation. Callers MUST releasethe interface when they are done with it.Return Values: The method MUST return zero or a non-error HRESULT (as specified in [<strong>MS</strong>-ERREF]) to indicate success, or return an implementation-specific nonzero error code toindicate failure. For the HRESULT values predefined by the <strong>Virtual</strong> <strong>Disk</strong> <strong>Service</strong> Remote<strong>Protocol</strong>, see section 2.2.3.When the server receives this message, it MUST validate the following parameter:•Verify that ppAsync is not NULL.•Verify that ullDesiredNumberOfReclaimableBytes is not zero.[<strong>MS</strong>-<strong>VDS</strong>] — v20110610<strong>Virtual</strong> <strong>Disk</strong> <strong>Service</strong> (<strong>VDS</strong>) <strong>Protocol</strong> <strong>Specification</strong>Copyright © 2011 Microsoft Corporation.Release: Friday, June 10, 2011263 / 360

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!