Package javaforce.vm
Class Storage
java.lang.Object
javaforce.vm.Storage
- All Implemented Interfaces:
Serializable
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intintstatic final intstatic final intstatic final intstatic final intstatic final intstatic final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanformat(int fmt) Format local partition or iSCSI target.static booleanformat_supported(int fmt) Get device size.static StringgetDiskUUID(String dev) Returns UUID of a disk device in /dev.getFolderSize(String folder) Gets size of files in folder (not recursive)static StringgetFormatString(int fmt) Get mounted file system free size.Returns gluster brick path.Returns gluster volume path within brick path.getName()getPath()Returns mount path.intgetState()String[]static StringGet mounted file system total size.getUUID()Get libvirt UUID (does NOT match Linux device UUID)booleangluster_volume_create(String[] hosts) booleanstatic String[]list()Returns list of UUID for Storage units registered.static String[]static voidbooleanmount()Mount iSCSI,Gluster,Ceph pools.booleanmounted()booleanregister()static booleansetSystemIQN(String iqn) booleanstart()booleanstop()booleanunmount()Unmount iSCSI, Gluster pools.boolean
-
Field Details
-
type
public int type -
name
-
uuid
-
host
-
target
-
path
-
user
-
TYPE_LOCAL_PART
public static final int TYPE_LOCAL_PART- See Also:
-
TYPE_LOCAL_DISK
public static final int TYPE_LOCAL_DISK- See Also:
-
TYPE_NFS
public static final int TYPE_NFS- See Also:
-
TYPE_ISCSI
public static final int TYPE_ISCSI- See Also:
-
TYPE_GLUSTER
public static final int TYPE_GLUSTER- See Also:
-
TYPE_CEPHFS
public static final int TYPE_CEPHFS- See Also:
-
STATE_OFF
public static final int STATE_OFF- See Also:
-
STATE_ON
public static final int STATE_ON- See Also:
-
STATE_BUILD
public static final int STATE_BUILD- See Also:
-
STATE_ERROR
public static final int STATE_ERROR- See Also:
-
FORMAT_EXT4
public static final int FORMAT_EXT4- See Also:
-
FORMAT_GFS2
public static final int FORMAT_GFS2- See Also:
-
FORMAT_OCFS2
public static final int FORMAT_OCFS2- See Also:
-
FORMAT_XFS
public static final int FORMAT_XFS- See Also:
-
-
Constructor Details
-
Storage
-
Storage
-
-
Method Details
-
list
Returns list of UUID for Storage units registered. -
register
public boolean register() -
unregister
public boolean unregister() -
start
public boolean start() -
stop
public boolean stop() -
getState
public int getState() -
getUUID
Get libvirt UUID (does NOT match Linux device UUID) -
getSystemIQN
-
setSystemIQN
-
getName
-
getStateString
-
getTypeString
-
getStates
-
getDiskUUID
Returns UUID of a disk device in /dev. -
listLocalParts
-
mount
public boolean mount()Mount iSCSI,Gluster,Ceph pools. start() will already mount other types. -
unmount
public boolean unmount()Unmount iSCSI, Gluster pools. stop() will already unmount other types. -
mounted
public boolean mounted() -
getFormatString
-
format
public boolean format(int fmt) Format local partition or iSCSI target. -
getPath
Returns mount path. -
getGlusterBrick
Returns gluster brick path. -
getGlusterVolume
Returns gluster volume path within brick path. -
format_supported
public static boolean format_supported(int fmt) -
getDeviceSize
Get device size. -
getTotalSize
Get mounted file system total size. -
getFreeSize
Get mounted file system free size. -
getFolderSize
Gets size of files in folder (not recursive) -
gluster_volume_create
-
isMountedManually
public boolean isMountedManually() -
main
-