We are committed to providing fast, efficient, and affordable software solutions that set new standards in the software development industry.
  • R-Drive Image Home Page
  • R-Drive Image Technical Documentation

Create a Script Manually


R-Drive Image has a very powerful and versatile script language that enables you to create scripts for all your needs.

A script consists of commands and their parameters. All commands, parameter, and their values are case-sensitive.

Click to expand/collapse Incompatibilities with ver.3.x

General :

The default extension for R-Drive Image script files is .rdi .

Parameter values may be inclosed in single ( ' ) or double ( " ) quotes. if the value does not contain spaces, the quotes may be omitted.

R-Drive Image ignores spaces in the beginning of a line. R-Drive Image treats multiple spaces as one space, except when they are in a parameter value enclosed in quotes.

Examples:

Below are equal lines:

create -a = "c:\archive.rdr"

   create   -a = "c:\archive.rdr"

Below are not equal lines:

create -a = "c:\archive 1.rdr"

create -a = "c:\archive    1.rdr"

Comments:

R-Drive Image treats lines which the first non-space character is ; or the first non-space character is [ and the last one is ] , as comments.

Examples:

; This is a comment line

[This is a comment line]

Multiple lines:

If the last non-space character in a line is \ , R-Drive Image appends the next line to it:

Example:

Lines:

create -a = "c:\archive.rdr" -s = "1:1" \

c = "5"

are equal to the line:

create -a = "c:\archive.rdr" -s="1:1" c=  "5"

Disk size units

Values specifying disk sizes may be in units.

b

bytes

 

Kb

kilobytes

2^10 = 1,024 b

Mb

megabytes

2^20 = 1,024 Kb

Gb

gigabytes

2^30 = 1,024 Mb

If the units are used, enclose the value in quotes.

Default values are Mb (megabytes).

Characters to substitute

If the following characters are to appear in the parameter values, they should be substituted by the following rules:

Character

String to substitute

"

"

'

'

&

&

carriage return

&cr;

new line

&nl;

Note: This is the incompatibility with scripts created for  the earlier versions of R-Drive Image .

URL paths

For remote hosts, R-Drive Image supports URL of two types:

\\[[domain;]username[:password]@]hostname\share\path

smb://[[domain;]username[:password]@]hostname[:<port>].share/path

They can be used instead local paths.

Script commands and parameters:

Command

Its Parameters

Optional/

Mandatory

Description and examples

list

 

Returns a partition list for local drives or an image file. If the drive contains an APFS container, the command will show both the APFS container and its APFS volumes.

-a=<PathOfNewArchiveFile>

Mandatory

Specifies a path (including its file name) to the image file.

Examples:

-a=C:\Images\Test.rdr or -a="C:\Image Files\Test 1.rdr"

-p=<Password>

Mandatory/Not used

Specifies an image password. Mandatory if the image file has been already encrypted. It there is a space in the password, the password should be in quotes.

Examples: -p=Password or -p='My Password'

-t=<TimeSliceNumber>

Optional

Specifies which incremental data will be used to list the partitions in the image. If the TimeSliceNumber is not specified, the first data in the image will be used. -1 specifies the last incremental data in the image.

first : R-Drive Image will use the first incremental data in the image.

last : R-Drive Image will use the last incremental data in the image.

+<n> : R-Drive Image will use the n -th incremental data from the beginning in the image.

-<n> : R-Drive Image will use the n -th incremental data from the end in the image.

Examples: -t="+2" specifies the second incremental data from the beginning in the image will be used to list partitions.

Example:

list -a=C:\Images\Test.rdr -p="mY pasSsworRrd"

This script command returns a list of partitions stored in the C:\Images\Test.rdr image file protected by the password mY pasSsworRrd .

sysdump

 

Creates a system dump that may be necessary to obtain technical support.  An image file can be included into that system dump. In this case, the keys -a , -p , -t from the list command should be used.

-sysdump="<SysDumpFile>"

Mandatory

Specifies the filename for the system dump.

Example:

sysdump -sysdump="MySysDump" -a=C:\Images\Test.rdr -p="mY pasSsworRrd"

This script command creates a file with the system dump, its name is MySysDump . The system dump includes the image file C:\Images\Test.rdr protected by the password mY pasSsworRrd .

register

 

Registers R-Drive Image from the command line.

-reg-user="<UserName>"

Mandatory

Specifies the user name for registration.

-reg-key="<RegistrationKey>"

Mandatory

Specifies the register key for registration.

-reg-company="<UserCompany>"

Optional

Specifies the company for registration.

Example:

register -reg-user="Tester 1" -reg-company=R-TT Testing Team" -reg-key="fafaasertghzfvasfje134"

This script command registers R-Drive Image for the user Tester 1 from the company R-TT Testing Team using the key fafaasertghzfvasfje134 .

Disk descriptors used in the -s and -d commands

Below is the list of disk descriptors R-Drive Image uses to identify hard drives, logical disks, and partitions. It is written in the order of importance, from the most important descriptor to the least important one. If there are several objects with identical disk descriptors, R-Drive Image identifies them using the most important disk descriptor with different values.

hdd_vtype

HDD type.

real : a basic disk

dynamic : a dynamic disk

pure : disk objects like USB pendrives with only one logical disk on it.

Example: hdd_vtype=real

hdd_size

HDD size

Disk size should be specified in bytes, no KB or MB are allowed.

Example: hdd_size=40060403712

hdd_name

HDD name

Example: hdd_name=SAMSUNG&#32;SP0411NTW100-11 (&#32; denotes a space)

hdd_serial

HDD serial number

Example: hdd_serial=S01JJ30X912841

hdd_bus_type

Type of the HDD bus

Can be: none, ata, atapi, scsi, floppy, usb, firewire, ssa, fibre, raid, smart, abios, sata, sata2 .

Example: hdd_bus_type=ata

hdd_port_num

Port number for HDD

Example: hdd_port_num=0

hdd_target_id

Target ID for HDD

Example: hdd_target_id=1

hdd_num

Disk number, coincides with the disk number used in the old notations.

Example: hdd_num=1

part_free_space

Free space mark

1 if this object is a disk free space, 0 if not.

Example: part_free_space=1

part_ofs

Partition offset in bytes.

Partition offset should be specified in bytes, no KB or MB are allowed.

Example: part_ofs=16778264576

part_size

Partition size

Partition size should be specified in bytes, no KB or MB are allowed.

Example: part_size=23279435776

part_fs

Partition file system

Can be: none, ntfs, fat12, fat16, fat32, exfat, ext2fs, ext3fs, ext4fs, ufs1, ufs2, hfs ,hfsplus ,hfsx, iso9660

Example: part_fs=ntfs

part_label

Disk label

Example: part_label=Test_Data

part_mounted

Disk letter of folder

Example: part_mounted=G:\

part_num

Partition number, coincides with the partition number used in the old notations.

Free space is considered as a partition.

Example: part_num=2

part_id

Partition identifier.

Example: part_id=2

vol_id

APFS volume identifier in an APFS container..

Example: vol _id=3

used_id

Partition identifier when free space is omitted.

Example: used _id=2

unused_id

Free space identifier when partitions are omitted.

Example: unused _id=1

A partition may be identified using its descriptors: hdd_size=40060403712+part_num=2+hdd_num=1+hdd_target_id=0+hdd_bus_type=ata+part_label=Part2+part_ofs=16778264576+part_mounted=G:\+hdd_name=SAMSUNG&#32;

SP0411NTW100-11+part_size=23279435776+hdd_port_num=0+hdd_serial=S01JJ30X912831+part_fs=ntfs+hdd_vtype=real

create

 

 

append

 

Differentially appends data to an existing image file. If such file does not exist, it will be created.

-s=<SourceDisk>

Mandatory

Specifies a source object to create the image or append to it. The <SourceDisk> parameter consists of one or several disk descriptors written in the form: descriptor_name1=value[+descriptor_name1=value...]. The disk descriptors are presented in the Disk descriptors section of this table. Old notation is also valid:

Old notation examples:

for hard drive 1: -s=1

for the second partition on hard drive 1 (empty space is treated as a partition): -s=1:2

for the second partition on hard drive 1 skipping empty spaces: -s=1:p2

for the first empty space on hard drive 1 skipping partitions: -s=1:f1

for a logical disk: -s=D:

for several logical disks: -s="D: F:"

-a=<PathOfNewArchiveFile>

Mandatory

Specifies a path (including its file name) to the image file.

Examples:

-a=C:\Images\Test.rdr or -a="C:\Image Files\Test 1.rdr"

-c=<CompressionLevel>

Optional

Specifies compression level (1...11).

Example: -c=3

-u

Optional

Backups useful information only. May be used as a Boolean parameter.

-v=<ArchiveSize>

Optional

Specifies image split size. May be in the float-point format.

Example: -v=650 or -v='4.5 Gb'

-append-inc

Optional

Creates an incremental backup.

-p=<Password>

Mandatory/Not used

Specifies an image password. Mandatory if the append command is used and the image file has been already encrypted. It there is a space in the password, the password should be in quotes.

Examples: -p=Password or -p='My Password'

-r=<Description of archive>

Optional

Specifies an image description. It there is a space in the description, the description should be in quotes.

Examples: -r=Description or -r="Image Description"

-s-xw

Optional

Makes R-Drive Image not to use the Windows snapshot provider.

-s-xr

Optional

Makes R-Drive Image not to use the R-TT snapshot provider.

-s-n

Optional

Notifies system application that a snapshot is being taken.

-s-b0=<AppBeforeBack>

Optional

Specifies an application that will start before the backup operation starts. The application should return a 0 exit code.

Example: -s-b0="C:\commands\start.exe"

-s-b1=<AppAfterBack>

Optional

Specifies an application that will start after the backup operation completes. The application should return a 0 exit code.

Example: -s-b1="C:\commands\end.exe"

-s-s0=<AppBeforeSnapShot>

Optional

Specifies an application that will start before the snapshot is taken. The application should return a 0 exit code.

Example: -s-s0="C:\commands\startsnapshot.exe"

-s-s1=<AppAfterSnapShot>

Optional

Specifies an application that will start after the snapshot is taken. The application should return a 0 exit code.

Example: -s-s1="C:\commands\endsnapshot.exe"

-xe=<AppIfError>

Optional

Specifies a command line that will start an application if R-Drive Image fails to perform the specified action. If there is a space in the command line, the command line should be in quotes.

Examples: -xe=error.exe or -xe="winamp C:\sounds\error.mp3"

-xs=<AppIfSucc>

Optional

Specifies a command line that will start an application if R-Drive Image successfully performs the specified action. If there is a space in the command line, the command line should be in quotes.

Examples: -xs=success.exe or -xs="winamp C:\sounds\success.mp3"

-bs

Optional

Specifies that R-Drive Image will use rotation schemes (backup sets) .

-bs-size="<Quota_in_MB>"

Optional

May be used only if the -bs is set. Specifies the total size in MB on the disk allocated for the backup set. If it is exceeded, the backup set (all its files) will be removed.

Example: -bs-size="20000"

-bs-num-b="<Number_of_backs>"

Optional

May be used only if the -bs is set. Specifies the number of rotation schemes (backup sets) If it is exceeded, the older rotation schemes (backup sets) (all their files) will be removed.

Example: -bs-num-b="10"

-bs-num-f="<Number_of_files>"

Optional

May be used only if the -bs is set. Specifies the number of files in all rotation schemes (backup sets). If it is exceeded, the older rotation schemes (backup sets) (all their files) will be removed.

Example: -bs-num-f="30"

-bs-age="<Days>"

Optional

May be used only if the -bs is set. Specifies the number of days for which R-Drive Image will keep the backup set. Then the backup set will be removed.

Example: -bs-age="14"

-cd-cache

Optional

Used when an image file is written to CD discs. R-Drive Image creates an ISO image of the CD disc and then copies it to the CD disc. Without it R-Drive Image writes data directly to the CD disc.

-cd-speed=<Speed>

Optional

Used when an image file is written to CD discs. Specifies burning speed in KB/sec.

Example: -cd-speed="1200"

-dvd-cache

Optional

Used when an image file is written to DVD discs. R-Drive Image creates an ISO image of the DVD disc and then copies it to the DVD disc. Without it R-Drive Image writes data directly to the DVD disc.

-dvd-speed

Optional

Used when an image file is written to DVD discs. Specifies burning speed in KB/sec.

Example: -dvd-speed="3324"

Example:

create -s="hdd_size=40060403712+part_num=1+hdd_num=2+hdd_target_id=0+hdd_bus_type=ata+part_label=Part1+part_ofs=1048576+part_mounted=F:\+hdd_name=SAMSUNG&#32;SP0411NTW100-11+part_size=16777216000+hdd_port_num=0+hdd_serial=S01JJ30X912831+part_fs=ntfs+hdd_vtype=real,hdd_size=40060403712+part_num=2+hdd_num=2+hdd_target_id=0+hdd_bus_type=ata+part_label=Part2+part_ofs=16778264576+part_mounted=H:\+hdd_name=SAMSUNG&#32;

SP0411NTW100-11+part_size=23279435776+hdd_port_num=0+hdd_serial=S01JJ30X912831+part_fs=ntfs+hdd_vtype=real" -a="I:\Test Image.rdr" -c=3 -u = true -p="My Password" -r="This is a test image" -xe="winamp C:\sounds\error.mp3" -xs="winamp C:\sounds\success.mp3"

This script command creates an image of logical disks F: and H: on the Samsung HDD. The path and filename for this image file is I:\Test Image.rdr , with compression level 3 , and only useful information on this disk will be written to the image. This image is protected with the password " My Password ", and its description is " This is a test image ". If the script action has been performed successfully, the winamp application will play the success.mp3 file, and if an error occurs, it will play the error.mp3 file.

restore

 

Restores data from an image to a specified disk place

copy

 

Copies a disk to a disk.

-s= <SourceDisk>

Mandatory

Specifies a source object to copy. The <SourceDisk> parameter consists of one or several disk descriptors written in the form: descriptor_name1=value[+descriptor_name1=value...]. The disk descriptors are presented in the Disk descriptors section of this table. Old notation is also valid:

Old notation examples:

for hard drive 1: -s=1

for the second partition on hard drive 1 (empty space is treated as a partition): -s=1:2

for the second partition on hard drive 1 skipping empty spaces: -s=1:p2

for the first empty space on hard drive 1 skipping partitions: -s=1:f1

for a logical disk: -s=D:

for several logical disks: -s="D: F:"

-d=<DestinationDisk>

Mandatory

Specifies a destination disk:partition on which the data is to be restored. The <DestinationDisk> parameter consists of one or several disk descriptors written in the form: descriptor_name1=value[+descriptor_name1=value...]. The disk descriptors are presented in the Disk descriptors section of this table. Old notation is also valid:

Old notation examples:

for hard drive 1: -d=1

for the second partition on hard drive 1 (empty space is treated as a partition): -s=1:2

for the second partition on hard drive 1 skipping empty spaces: -s=1:p2

for the first empty space on hard drive 1 skipping partitions: -s=1:f1

for a logical disk: -d=D:

-a=<PathOfArchiveFile>

Mandatory

Applicable to restore only.

Specifies a path (including its file name) to the image file from which data is to be restored. It there is a space in the path, the path should be in quotes.

Examples : -a=C:\Images\Test.rdr or -a="C:\Image Files\Test.rdr"

-k=<"PartitionStatus">

Optional

Specifies a status (primary/active) for a partition to be restored.

Settings:

+p is a primary partition -p is a secondary partition

+a is an active partition -a is a non-active partition

Please note that the combination "-p +a" is invalid. If this parameter is not specified, the data from the image will be used.

Examples:

-k="+p+a" the partition will be primary and active.

-k="+p" the partition will be primary. Information in the image will be used to make the partition either active or non-active.

-ou

Optional

Copy/restore useful information only. May be used as a Boolean parameter.

-t=<TimeSliceNumber>

Optional

Applicable to restore only.

Specifies which incremental data will be used to restore data from the image. If the TimeSliceNumber is not specified, the first data in the image will be used. -1 specifies the last incremental data in the image.

first : R-Drive Image will use the first incremental data in the image.

last : R-Drive Image will use the last incremental data in the image.

+<n> : R-Drive Image will use the n -th incremental data from the beginning in the image.

-<n> : R-Drive Image will use the n -th incremental data from the end in the image.

Examples: -t="+2" specifies the second incremental data from the beginning in the image will be used to restore data.

-lr=<DiskLetter>

Optional

Specifies a disk letter. This parameter is case-insensitive.

Examples: -lr="K" or - lr=K .

-sz=<PartitionSize>

Optional

Specifies a partition size. May be in the float-point format. The following predefined values may be used: min : shrink the partition to the minimum possible size, max : expand the partition to the maximun size.

Example: -sz=512 or -sz='0.5 Gb'

-of=<PartitionOfset>

Optional

Specifies an offset from the beginning of the destination. May be in the float-point format. Default is 0 .

Example: -of=512 or -of='0.5 Gb'

-bs-use="<Parameter>"

Optional

Applicable to restore only.

Specifies the backup set R-Drive Image will use to restore data. Parameter may be:

first : R-Drive Image will use the first backup set.

last : R-Drive Image will use the last backup set.

+<n> : R-Drive Image will use the n -th backup set from the beginning.

-<n> : R-Drive Image will use the n -th backup set from the end.

<date> : R-Drive Image will use the backup set containing the date in its name.

Examples:

-bs-use="+3" : R-Drive Image will use the 3-rd backup set from the beginning.

-bs-use="20080521" : R-Drive Image will use the backup set containing the " 20080521 " string in its name.

-p=<password>

Mandatory / Not used

Applicable to restore only.

Mandatory for password-protected files. Specifies a password for the archive.

Example: -p="my password"

-hdd-mode="<ModeType>"

Optional

Applicable to copy/restore entire hard drives only.

Specifies an HDD copy mode when copying entire hard drives. Parameter may be:

0 : The default method

1 : Raw disk copy

2 : Copy all partitions onto original places

19 : One partition after another

20 : One partition after another (Fixed active partition)

51 : Expand/Shrink partition to whole disk

52 : Expand/Shrink partition to whole disk (Fixed active partition)

Example:

restore -a="I:\Test Image.rdr" -s="hdd_size=40060403712+part_num=1+hdd_num=1+hdd_target_id=0+hdd_bus_type=ata+part_label=Part2

+part_ofs=16778264576+part_mounted=G:\+hdd_name=SAMSUNG&#32;SP0411NTW100-11+part_size=23279435776+hdd_port_num=0+hdd_serial=S01JJ30X912831+part_fs=ntfs+hdd_vtype=real"

-d="hdd_size=40060403712+part_num=2+hdd_num=1+hdd_target_id=0+hdd_bus_type=ata+part_label=Part2+part_ofs=16778264576+part_mounted=G:\+hdd_name=SAMSUNG&#32;SP0411NTW100-11+part_size=23279435776+hdd_port_num=0+hdd_serial=S01JJ30X912831+part_fs=ntfs+hdd_vtype=real"

-p="My Password" -xe="winamp C:\sounds\error.mp3" -xs="winamp C:\sounds\success.mp3"

This script command restores data to the logical disk G: on the Samsung HDD, the source image is stored in the "I:\Test Image.rdr" , the data is taken from the first partition in the image. This image is protected with the password " My Password " . If the script action has been performed successfully, the winamp application will play the success.mp3 file, and if an error occurs, it will play the error.mp3 file.

restorefiles

 

Restores individual files from images to a specified destination

-s=" <SourceDisk>"

Mandatory

Specifies a source object to restore. The <SourceDisk> parameter consists of one or several disk descriptors written in the form: descriptor_name1=value[+descriptor_name1=value...]. The disk descriptors are presented in the Disk descriptors section of this table. Old notation is also valid:

Old notation examples:

for hard drive 1: -s=1

for the second partition on hard drive 1: -s=1:2

for a logical disk: -s=D:

-a="<PathOfArchiveFile>"

Mandatory

Specifies a path (including its file name) to the image file from which data is to be restored. It there is a space in the path, the path should be in quotes.

Examples : -a=C:\Images\Test.rdr or -a="C:\Image Files\Test.rdr"

-filelist="<ListOfFilesToRestore>"

Mandatory

Specifies list of files from the image that should be restored.

Example: -filelist="MyPhoto/*,Photo/Picture 001.jpg,Photo/Picture 003.jpg"

-outdir="<OutputFolder>"

Mandatory

Specifies the folder to which files will be restored.

Example: -outdir="D:\1111"

Example:

restorefiles -s="hdd_size=7509196800+part_num=1+hdd_num=1+hdd_target_id=0+hdd_bus_type=ata+part_label=NTFS-Test+part_ofs=64512+part_mounted=F:\+hdd_name=WDC&#32;WD75DA-00AWA107.21L07

+part_size=3141991936+hdd_port_num=0+hdd_serial=WD-WMA1J1262876+part_fs=ntfs+hdd_vtype=real" 

-a="I:\Test_Image.rdr" -t="+1" -filelist="MyPhoto/*,Photo/Picture 001.jpg,

Photo/Picture 003.jpg,Photo/Picture 005.jpg,Photo/Picture 007.jpg,Photo/Picture 009.jpg,Photo/Picture 010.jpg,Photo/Picture 011.jpg,

Photo/Picture 013.jpg,Photo/Picture 015.jpg,Photo/Picture 016.jpg,Photo/Picture 017.jpg,Photo/Picture 018.jpg,Photo/Picture 019.jpg,Photo/Picture 020.jpg,

Photo/Picture 021.jpg,Photo/Picture 022.jpg,Photo/Picture 023.jpg,

Photo/Picture 024.jpg,Photo/Picture 025.jpg,Photo/Picture 026.jpg,Photo/Picture 027.jpg,Photo/Picture 028.jpg" -outdir="D:\1111"

This script command restores the specified files to the destination path D:\1111 from the source image of the first partition of the hard drive stored in the file I:\Test_Image.rdr .

check

 

Checks consistency of the archive

-a=<PathOfArchiveFile>

Mandatory

Specifies a path (including its file name) to the image which integrity is to be checked. It there is a space in the path, the path should be in quotes.

Examples : -a=C:\Images\Test.rdr or -a="C:\Image Files\Test.rdr"

Example:

check -a="I:\Test Image.rdr"

This script command checks the image file I:\Test Image.rdr for its consistency.

mount

 

Mounts an image file as a read-only virtual disk.

-a=<PathOfNewArchiveFile>

Mandatory

Specifies a path (including its file name) to the image file.

Examples:

-a=C:\Images\Test.rdr or -a="C:\Image Files\Test 1.rdr"

-s= <SourceDisk>

Mandatory

Specifies an object in the image to mount. The <SourceDisk> parameter consists of one or several disk descriptors written in the form: descriptor_name1=value[+descriptor_name1=value...]. The disk descriptors are presented in the Disk descriptors section of this table. Old notation is also valid:

Old notation examples:

for the second partition on hard drive 1: -s=1:2

for a logical disk: -s=D:

-lr=<DiskLetter>

Mandatory

Specifies a disk letter. This parameter is case-insensitive.

Examples: -lr="K" or - lr=K .

-t=<TimeSliceNumber>

Optional

Specifies which incremental data in the image will be used to mount a disk. If the TimeSliceNumber is not specified, the first data in the image will be used. -1 specifies the last incremental data in the image.

first : R-Drive Image will use the first incremental data in the image.

last : R-Drive Image will use the last incremental data in the image.

+<n> : R-Drive Image will use the n -th incremental data from the beginning in the image.

-<n> : R-Drive Image will use the n -th incremental data from the end in the image.

Examples: -t="+2" specifies the second incremental data from the beginning in the image will be used to mount a disk.

-bs-use="<Parameter>"

Optional

Specifies the backup set R-Drive Image will use to mount as a logical disk. Parameter may be:

first : R-Drive Image will use the first backup set.

last : R-Drive Image will use the last backup set.

+<n> : R-Drive Image will use the n -th backup set from the beginning.

-<n> : R-Drive Image will use the n -th backup set from the end.

<date> : R-Drive Image will use the backup set containing the date in its name.

Examples:

-bs-use="+3" : R-Drive Image will use the 3-rd backup set from the beginning.

-bs-use="20080521" : R-Drive Image will use the backup set containing the " 20080521 " string in its name.

Example:

mount -a="I:\Test Image.rdr" -s=1:2 lr=F: -t=-1

This script command mounts the second partition of the first hard drive contained in the image file I:\Test Image.rdr . The virtual logical disk will have the F: letter.

unmount

 

Unmounts a mounted virtual disk.

-lr=<DiskLetter>

Mandatory

Specifies a disk letter. This parameter is case-insensitive.

Examples: -lr="K" or - lr=K .

Example:

unmount lr=F:

This script command unmounts the virtual logical disk F:.

activate

 

Sets a specified partition active.

The required partition should be specified

-s= <SourceDisk>

Mandatory

Specifies the partition on the disk to set active. The <SourceDisk> parameter consists of one or several disk descriptors written in the form: descriptor_name1=value[+descriptor_name1=value...]. The disk descriptors are presented in the Disk descriptors section of this table. Old notation is also valid:

Old notation examples:

for the second partition on hard drive 1: -s=1:2

for a logical disk: -s=D:

Example:

activate -s=1:1

This script command set the first partition of the first hard drive active.

delete

 

Deletes a partition on a drive

The required partition should be specified

-s= <SourceDisk>

Mandatory

Specifies a partition to delete. The <SourceDisk> parameter consists of one or several disk descriptors written in the form: descriptor_name1=value[+descriptor_name1=value...]. The disk descriptors are presented in the Disk descriptors section of this table. Old notation is also valid:

Old notation examples:

for the second partition on hard drive 1: -s=1:2

for a logical disk: -s=D:

Example:

delete -s=F:

This script command deletes the logical disk F:.

clear

 

Deletes all partitions on a drive

-s= <SourceDisk>

Mandatory

Specifies the hard drive where all partitions should be deleted. The <SourceDisk> parameter consists of one or several disk descriptors written in the form: descriptor_name1=value[+descriptor_name1=value...]. The disk descriptors are presented in the Disk descriptors section of this table. Old notation is also valid:

Old notation examples:

for hard drive 1: -s=1

-part-type=<PartitionType>

Optional/Mandatory

Specifies a partition ing scheme type to be created on the hard drive.

<PartitionType> may be:

mbr: R-Drive Image will create the MBR scheme .

gpt: R-Drive Image will create the GPT schemes .

If omitted, the existing partition ing schemes table will be cleared. Mandatory if no partitioning schemes exists on the hard drive.

Example:

clear -s=2

This script command deletes all partitions on the second hard drive.

fixmbr

Optional

Installs a default boot loader on a hard drive

-s= <SourceDisk>

Mandatory

Specifies the hard drive where the boot loader will be installed. Example:

for hard drive 1: -s=1

Example:

fixmbr -s=1

This script command installs the default boot loader to the first hard drive.

mail

Optional

Specifies all mail options globally for the entire script

Example:

mail -ms=mail.example.com -ma=rtt1@example.com -mr=rtt2@example.com -ml=rtt1:password -me -mx -mz=ssl

This script command sends e-mails confirming success or error of the action from rtt1@example.com to rtt2@example.com via the mail.example.com SMTP server using the default (25) port with the rtt1 login and password password. The SSL option is SSL.

Parameters applicable to all commands

These parameters can be used in all commands

-log="<LogOptions>"

Optional

Controls the way R-Drive Image logs its command-line activity. By default, it outputs its activity into WinNT event log if started from Windows scheduler, but can create its own xml-type log files.

LogOptions may be:

#nodefault : disables the default log output into syslog

<filename> : writes the log to the specified file name and path. Example: c:\mylogs\mylog.txt . The " , " character in the file name should be doubled.

<filepath> : writes the log files (a separate one to each session) to the specified folder. Each file name will have the following filename: date_time.rdl . Examples: c:\mydir\, file name: 20081003_215302.rdl .

#syslog : output logs into WinNT event log.

#sysdir : outputs logs into C:\Documents and Settings\All Users\Application Data\R-TT\R-Drive Image\Logs\ .

Example: -log="#nodefault,c:\mylog.txt,c:\mydir\,#sysdir"

This will make R-Drive Image write its logs to the c:\mylog.txt file, and to the c:\mydir\ and C:\Documents and Settings\All Users\Application Data\R-TT\R-Drive Image\Logs\ folders without writing to WinNT event log.

mail options

Optional

Sends e-mail messages if the action fails or succeeds and specifies e-mail parameters. If a personal firewall is installed on your computer, you should allow the r-driveimagecl.exe application to get access to the e-mail server.

-me

Optional

Sends an e-mail message when R-Drive Image fails to perform the specified action. May be used as a Boolean parameter.

-mx

Optional

Sends an e-mail message when R-Drive Image successfully performs the specified action. May be used as a Boolean parameter.

-ms=<SMTPServer[:port]>

Mandatory/Not used

Mandatory if the -me or/and -mx option is used. Specifies an SMTP server and port (optional).

Examples: -ms=mail.example.com or -ms=mail.example.com:25

-ma=<SenderEmail>

Mandatory/Not used

Mandatory if the -me or/and -mx option is used. Specifies a sender's e-mail address.

Example: -ma=rtt1@example.com

-mr=<RecepientEmail>

Mandatory/Not used

Mandatory if the -me or/and -mx option is used. Specifies a recipient's e-mail address or addresses.

Example: -ma=rtt2@example.com

-ml=<Login:Password>

Optional

Specifies a login and password at the SMTP server.

Example: -ml=rtt1:password

-mz=<SSLOptions>

Optional

Specifies the SSL options. Can be auto,no,ssl,tls.

Default is auto

Example: -mz=ssl

-mn=<SenderName>

Optional

Specifies the sender name.

Example: -mn="Jhon Smith"

-mc=<MailSubject>

Optional

Specifies the mail subject..

Example: -mc="Backup Result"

Boolean parameters

Those are parameters that may have Boolean values:

true , 1 , yes , false , 0 , no .

They may be used as keys (example: -u ) or as parameters with values (example: -u=true ).

Entities or Variables.

Entities may be used as variables to create various text strings. They are start with & and end with ; .

Version Entities .

In the examples below, the R-Drive Image version is assumed as 4.1.67

Entity

Description

&rdi.ver;

The R-Drive Image version. Example: "4.1"

&rdi.ver.build;

The R-Drive Image build. Example: "4167"

&rdi.ver.major;

The R-Drive Image major version. Example: "4"

&rdi.ver.minor;

The R-Drive Image minor version. Example: "1"

&rdi.ver.subminor;

The R-Drive Image sub-minor version. Example: "67"

Result Entities

Entity

Description

&rdi.last_result;

Returns the last result of R-Drive Image operation. May be undefined , success , failed .

Time Entities .

In the examples below, the system time is assumed as 11:10:04 AM

Entity

Description

&sys.time;

System time in the locale format. Example: "11:10:04" . Please note that it is impossible to use this entity in file names because it contains an invalid character : .

&sys.time.m;

Minutes

&sys.time.h;

Hours in the 24 h format

&sys.time.h12;

Hours in the 12 h format

&sys.time.h24;

Hours in the 24 h format

&sys.time.s;

Seconds

&sys.time._m;

PM or AM

Date Entities .

In the examples below, the system date is assumed as February 1, 2007, Thursday

Entity

Description

&sys.date;

System date in the locale format. Example: "29/01/07" . Please note that it is not recommended to use this entity in file names because that will create a chunk of folders.

&sys.date.d;

Month day. Example: "01"

&sys.date.m;

Month. Example: "02"

&sys.date.y;

Short year. Example: "07"

&sys.date.yyyy;

Long year. Example: "2007"

&sys.date.m.name;

Month name. Example: "February"

&sys.date.m.nm;

Short month name. Example: "Feb"

&sys.date.wd;

Week day number, starting from Sunday. Example: "5"

&sys.date.wd.name;

Week day name. Example: "Thursday"

&sys.date.wd.nm;

Short week day name. Example: "Th"

Enumeration Entities

Entity

Description

&rdi.enum;

Defines the number of calls to this entity. Starts from 0 .

&rdi.enum.<Num>;

Defines the number of calls to this entity. Starts from 0 . Num specifies the format of the number. Example: &rdi.enum.3; will return 001 for the second calls to this entity.

User-defined entities

You may create your own entities using the set command. Example:

set creat_date = "&sys.date.m.name;-&sys.date.d;-&sys.date.y;"

You may use this entity, for instance, set a command creating files with their date of creation as the file name:

create -a="D:\archive\&creat_date;.rdr" -s="c:"

If the date when the script has been run is February 1, 2007, Thursday, this command will create an image of the logical disk C: and write it to the D:\archive\February-01-07.rdr file.

Please note that the set command defines the entities rather than specifies their value. The actual value of an entity will be determined each time the entity is used. Example:

set creat_time = "&sys.time.h24;-&sys.time.m;-&sys.time.s;"

and the creat_time entity is used in two commands in a script:

create -a="D:\archive\&creat_time;.rdr" -s="c:"

create -a="D:\archive\&creat_time;.rdr" -s="c:"

R-Drive Image will create two different files with different file names, each representing the time of file creation.

The unset command deletes entities. Example:

unset creat_date creat_time

After this command the creat_date and creat_time entities cannot be used and cause R-Drive Image to generate an error if they appear further in the script.

 

The Disk Actions chapter explains basic disk actions.

The Startup Version chapter explains how to perform disk actions using the R-Drive Image Startup Version .

The Technical Information chapter gives technical information on Supported CD and DVD Recorders and List of Hardware Devices Supported in the Startup Mode and another useful technical information.

Follow this link to obtain R-Drive Image Contact Information and Technical Support