Partition Management without data loss
Create, Delete, Resize, Slide, Hide, and unHide partitions without losing data.
LANDesk comes with a DOS and Linux tool called PWORKCL. It's located in the ManagementSuite\LANDesk\Files directory on the core server. If you create a DOS based imaging task you'll see that it's used to delete and create a single partition on the client. However there are other command line switches that can be passed to this executable to adjust partitions without losing the OS or other data. It works on FAT/FAT32/NTFS partitions and volumes. Volumes are specified by using Hex (0xXXX). Here's a list of those options and what they mean:
Hide/unHide
pworkcl /H hdnum partnum
-/H = Hide and /H- =unHide
- hdnum is the hard drive number 0 to 7
- partnum is the partition/volume number. Typically 1 is the first partition/volume on the drive.
Set Active Partition
pworkcl /A hdnum mbrnum
- hdnum is the hard drive number 0 to 7
- mbrnum is a number 0 to 3
Sliding
pworkcl /S hdnum partnum fsbmb
- hdnum is the hard drive number 0 to 7
- partnum is the partition/volume number. Typically 1 is the first partition/volume on the drive. For a Volume, use the /L and get the id number and then convert that to hex (0xXXX). So if volume on the extended partition is (0280), use 0x0280 as the volume number to change.
- fsbmb is the free space before the partition/volume in MB. -1 slides the partition/volume to the end of the drive.
Resizing
pworkcl /R hdnum partnum [newsizemb]
- hdnum is the hard drive number 0 to 7
- partnum is the partition/volume number. Typically 1 is the first partition/volume on the drive. For a Volume, use the /L and get the id number and then convert that to hex (0xXXX). So if volume on the extended partition is (0280), use 0x0280 as the volume number to change.
- newsizemb is the optional new size the partition/volume should be in MB. If left out the partition/volume will be the largest size possible.
Deleting
pworkcl /D hdnum partnum [volname]
- hdnum is the hard drive number 0 to 7
- partnum is the partition/volume number. Typically 1 is the first partition/volume on the drive. For a Volume, use the /L and get the id number and then convert that to hex (0xXXX). So if volume on the extended partition is (0280), use 0x0280 as the volume number to change.
- volname is the name of the volume. If used it must match the volume name exactly or it will fail
Create
pworkcl /C hdnum newsizemb [volname [/S]] | [/NF]
- hdnum is the hard drive number 0 to 7
- newsizemb is the optional new size the partition/volume should be in MB.
- volname is the volume name assigned to the new partition/volume
- /S is used as an optional task and will preform a read-only surface check.
- /NF is optional and used to not format the drive.
List
pworkcl /L hdnum
- hdnum is the hard drive number 0 to 7. It's found after the partition type (pri/vol)