Summary:
Unmounts a device that was previously mounted using the new_mount
call.
Request specification:
Name |
Min/Max |
Type |
Description |
|
|
|
|
|
|
|
|
|
|
Server ID. |
|
|
|
|
|
Returns:
OK/Error
Description:
On Linux, the
umount
call is used to deactivate an existing mount point (i.e. to detach the specified filesystem from the file hierarchy), to change the mount point status from "permanent" to "temporary", or to remove the mount point from the system completely.
To deactivate the mount point, include the point
parameter containing the directory name, the eid
parameter containing the Server ID, and the active
parameter containing the true
value (see code examples below).
To change the status of the mount point from "permanent" to "temporary", include the point
parameter containing the directory name, the eid
parameter containing the Server ID, and the permanent
parameter containing the true
value (see code examples below). Please note that temporary mounts can only exist in the "active" state, therefore you cannot make a mount point temporary if it is not currently active.
To remove the mount point, include the point
parameter containing the directory name, the eid
parameter containing the Server ID, the point
parameter containing the directory name, and the permanent
parameter containing the true
value (see code examples below).
On Windows, the
umount
call removes the drive that has been associated with a physical storage device on the Hardware Node or an EFD image. When unmounting an EFD image, the image file will not be physically deleted and can be re-mounted later. To permanently delete the image file, use the delete_drive
call. The following parameters are used:
point
-- the drive letter (e.g. E:
) associated with the device or the image file.
eid
-- Server ID.
Example 1:
Deactivating the existing mount point.
<packet version="4.0.0" id="2">
<target>vzadevm</target>
<data>
<vzadevm>
<umount>
<device>/dev/sda2</device>
<point>/mydrive</point>
<active>true</active>
<eid>107d1f60-841e-8c43-8152-3c368ef3c366</eid>
</umount>
</vzadevm>
</data>
</packet>
Example 2:
Making the mount point temporary.
<packet version="4.0.0" id="2">
<target>vzadevm</target>
<data>
<vzadevm>
<umount>
<permanent>1</permanent>
<point>/mydrive</point>
<eid>107d1f60-841e-8c43-8152-3c368ef3c366</eid>
</umount>
</vzadevm>
</data>
</packet>
Example 3:
Removing the mount point.
<packet version="4.0.0" id="2">
<target>vzadevm</target>
<data>
<vzadevm>
<umount>
<permanent>true</permanent>
<point>/mydrive</point>
<eid>107d1f60-841e-8c43-8152-3c368ef3c366</eid>
<active>1</active>
</umount>
</vzadevm>
</data>
</packet>
Example 4:
Unmounting a device that was previously mounted inside a Container (the device can be a physical drive or an EFD image).
<packet version="4.0.0" id="2">
<target>vzadevm</target>
<data>
<vzadevm>
<umount>
<point>K:</point>
<eid>b85f10fc-e42b-4e1c-a18b-85c6a25501b8</eid>
</umount>
</vzadevm>
</data>
</packet>