© 1983-2012 Novell. See COPYRIGHT file for details.

Data Migration NCPs


Data Migration is the process of migrating (moving) data from a NetWare volume to an online data media such as disk, tape, or CD ROM. Although data is migrated, the NetWare file system continues to perceive data as residing on a NetWare volume. Data Migration offers NetWare users a way of optimizing space on a NetWare volume. For example, by migrating data in files that are least recently used or least frequently accessed, users gain optimum space on NetWare volumes, yet can see and, if necessary, retrieve migrated data with relative quickness.

Because Data Migration (DM) is a real-time process, a user at a workstation can request data migration/demigration for a specified file, and the migration/demigration will occur immediately and transparently to the user. Users can also mark files as ineligible for data migration.

DM is implemented in NetWare 4.0 as the Data Migration NLM (DM NLM) and as various, optional Data Migration Support Module NLMs (Support Modules). Up to 32 Support Modules and their associated devices, whether hard disk, tape, CD ROM, etc. can register with the DM. The Data Migration NCPs allow workstations or NLMs to do the following:


DM File Information 0x2222 90 129

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (13) word (Hi-Lo) 9 SubFuncCode (129) byte 10 Volume long (Lo-Hi) 14 DirectoryEntry long (Lo-Hi) 18 NameSpace long (Lo-Hi)

Reply Format

Offset Content Type (reply header) 8 SupportModuleID long (Lo-Hi) 12 RestoreTime long (Lo-Hi) 16 DMInfoEntries long (Lo-Hi) xx+ DMINFO structure

CompletionCode

	0	0x00	Successful
	126	0x7E	Invalid Length
	152	0x98	Invalid Volume
	168	0xA8	Access Denied

Remarks

This NCP is used to get information about DM files.

The following Request Format parameters are defined:

The Volume field is the NetWare volume for which information is requested.

The DirectoryEntry field is the directory entry for which information is requested.

The NameSpace field is the name space of the file(s) for which information is requested.

The following Reply Format parameters are defined:

The SupportModuleID field is the Support Module containing the migrated data.

The RestoreTime field is the estimated time in seconds that the support module believes that it will take to demigrate the file.

The DMInfoEntries field is the number of valid DMINFO entries.

The DMINFO field is the structure used to pass information about the DM data streams for the information calls.

	typedef struct
	{
		LONG DataSize;
	} DMINFO;

DM Support Module Information 0x2222 90 132

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (9) word (Hi-Lo) 9 SubFuncCode (132) byte 10 InfoLevel long (Lo-Hi) 14 SupportModuleID long (Lo-Hi)

Reply Format (infoLevel = 0)

Offset Content Type (reply header) 8 IOFlag long (Lo-Hi) 12 SMInfoSize long (Lo-Hi) 16 AvailableSpace long (Lo-Hi) 20 UsedSpace long (Lo-Hi) 24+ SModuleName byte xx+ SMInfo byte

Reply Format (InfoLevel = 1)

Offset Content Type (reply header) 8 NumberOfSMs long (Lo-Hi) 12+ SMIDs[] long (Lo-Hi)

Reply Format (InfoLevel = 2)

Offset Content Type (reply header) 8 NameLen byte 9+ Name byte[]

CompletionCode

	0	0x00	Successful
	126	0x7E	Invalid Length
	168	0xA8	Invalid Support Module ID
	255	0xFF	Failure or Invalid Info Level

Remarks

This NCP is used to get information about DM NLM support modules or a list of all loaded Support Module ID's.

The request format includes the following two parameters:

The InfoLevel field indicates the type of information to retrieve. This NCP supports 3 levels of info that can be returned. They are described below.

The SupportModuleID field is the ID number of the Support Module.

The following information is returned in the reply format parameters at Info Level 0:

The following information is returned in the reply format parameters at InfoLevel 1:

The following information is returned in the reply format parameters at InfoLevel 2:


DM Support Module Capacity Request 0x2222 90 135

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (1+SMCapacityReq) word (Hi-Lo) 9 SubFuncCode (135) byte 10 CapacityRequest SMCapacityReq

Reply Format

Offset Content Type (reply header) 8 SMBlockSizeInSectors long (Lo-Hi) 12 SMTotalBlocks (-1 means unlimited) long (Lo-Hi) 16 SMUsedBlocks long (Lo-Hi)

CompletionCode

	0	0x00	Successful
	126	0x7E	Invalid Length
	168	0xA8	Invalid Support Module ID

Remarks

This NCP allows you to query the server for the following support module information: block size in sectors, total blocks, and used blocks.

SMCapacityReq structure

	typedef struct
	{
		LONG SupModID;
		LONG Vol;
		LONG TargetDirectoryBase;
	} SMCapacityReq;

Get/Set Default Read-Write Support Module ID 0x2222 90 134

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (9) word (Hi-Lo) 9 SubFuncCode (134) byte 10 Get/SetFlag long (Lo-Hi) 14 SupportModuleID long (Lo-Hi)

Reply Format

Offset Content Type (reply header) 8 SupportModuleID long (Lo-Hi)

CompletionCode

	0	0x00	Successful
	126	0x7E	Invalid Length
	236	0xEC	Invalid Support Module ID
	251	0xFB	No Such Property or Invalid Get/Set Flag

Remarks

This NCP is used get or set the default Read-Write Support Module ID.

The Get\SetFlag field in the Request Format is defined as follows:

If Get/SetFlag = 0, this NCP gets the default Read-Write Support Module ID. If Get/SetFlag = 1, this NCP sets the default Read-Write Support Module ID.

The SupportModuleID field in the Request Format is defined as follows:

On a set call, if the default Read-Write Support Module ID equals a null, then the Read-Write Support Module ID will be cleared.

On a Get call, if the return default Read Write Support Module ID equals a null, then no default Read-Write Support Module ID has been set.

The SupportModuleID parameter in the Reply Format is the ID of the support module.


Migrator Status Info 0x2222 90 131

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (1) word (Hi-Lo) 9 SubFuncCode (131) byte

Reply Format

Offset Content Type (reply header) 8 DMPresentFlag long (Lo-Hi) 12 DMmajorVersion long (Lo-Hi) 16 DMminorVersion long (Lo-Hi)

CompletionCode

	0	0x00	Successful
	126	0x7E	Invalid Length

Remarks

This NCP is used to get information about the migrator.

The following Reply Format parameters are defined:

The DMPresentFlag field can be set to -1 or 0. If the flag is equal to -1, then the DM NLM has been loaded and is running. If the flag is equal to 0, then the DM NLM is not loaded.

The DMmajorVersion field is the major version number of the migrator.

The DMminorVersion field is the minor version number of the migrator.


Move File Data From DM 0x2222 90 133

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (13) word (Hi-Lo) 9 SubFuncCode (133) byte 10 Volume long (Lo-Hi) 14 DirectoryEntry long (Lo-Hi) 18 NameSpace long (Lo-Hi)

Reply Format

Offset Content Type (reply header)

CompletionCode

	0	0x00	Successful
	120	0x78	Service Unavailable on this Volume
	126	0x7E	Invalid Length
	152	0x98	Disk Map Error (Invalid Volume)
	156	0x9C	Invalid Directory Entry
	168	0xA8	Access Denied

In NetWare 4.10, an Invalid Name Space will abend the server.

Remarks

This NCP is used to move a file back to the NetWare Volume. The following Request Format fields are defined:

The Volume field is the NetWare volume to be demigrated.

The DirectoryEntry field is the directory entry to be demigrated.

The NameSpace field is the name space associated with the information to be demigrated.


Move File Data To DM 0x2222 90 128

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (21) word (Hi-Lo) 9 SubFuncCode (128) byte 10 Volume long (Lo-Hi) 14 DirectoryEntry long (Lo-Hi) 18 NameSpace long (Lo-Hi) 22 SupportModuleID long (Lo-Hi) 26 Flags long (Lo-Hi)

Reply Format

Offset Content Type (reply header)

CompletionCode

	0	0x00	Successful
	126	0x7E	Invalid Length
	152	0x98	Disk Map Error
	156	0x9C	Invalid Path
	168	0xA8	Invalid Support Module ID

Remarks

This NCP is used to move a file's data to some online long term storage media but leave the file visible on a NetWare volume.

The following Request Format fields are defined:

The Volume field is the NetWare volume to be migrated.

The DirectoryEntry field is the directory entry to be migrated.

The NameSpace field is the name space associated with the information to be migrated.

This SupportModuleID field should contain the assigned ID number of the support module to migrate data to, or it should contain the default support module value:

#define UseDefaultRdWrSupportModule 0x64646d6d

The Flags field is set to either 1 or 0 depending on the type of media information is migrated to.


RTDM Request 0x2222 90 136

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (6) word (Hi-Lo) 9 SubFuncCode (136) byte 10 Verb long (Lo-Hi) 14 VerbData byte

Reply Format

Offset Content Type (reply header)

CompletionCode

	0	0x00	Successful

Remarks


Volume DM Status 0x2222 90 130

v2.xv3.xv4.xv5.x



Request Format

Offset Content Type (request header) 6 FunctionCode (90) byte 7 SubFuncStrucLen (9) word (Hi-Lo) 9 SubFuncCode (130) byte 10 Volume long (Lo-Hi) 14 SupportModuleID long (Lo-Hi)

Reply Format

Offset Content Type (reply header) 8 NumOfFilesMigrated long (Lo-Hi) 12 TtlMigratedSize long (Lo-Hi) 16 SpacedUsed long (Lo-Hi) 20 LimboUsed long (Lo-Hi) 24 SpaceMigrated long (Lo-Hi) 28 FileLimbo long (Lo-Hi)

CompletionCode

	0	0x00	Successful
	120	0x78	Service Unavailable on this Volume
	126	0x7E	Invalid Length
	152	0x98	Disk Map Error

Remarks

This NCP is used to get information about DM NLM on a specified volume.

The following Request Format parameters are defined:

The Volume field is the NetWare volume for which status information is requested.

This SupportModuleID field is the ID number of the support module for which status information is requested.

The following Reply Format fields are defined:

The NumOfFileMigrated filed is the number of files from the selected volume that have been migrated.

The TtlMigratedSize field is the total size needed to recover all the data on this selected volume.