create_fs
Create a file system, mount it, and register it (mount at boot)
### This function is deprecated. Please use fs_create.
Refuses existing directory as mount point (security)
Arguments
$1 | Mount point |
$2 | device path |
$3 | Optional. FS type (if empty, default FS type for this OS) |
$4 | Optional. Mount point directory owner[:group] |
Returns
0 if no error, 1 on errorDisplays
Info msgcreate_lv_fs
Create a logical volume and a filesystem on it
### This function is deprecated. Please use fs_create_lv_fs ### Warning: Note that superseding function has argument 4 and 5 swapped (size and FS type).
Combines create_lv and fs_create
Arguments
$1 | Mount point (directory) |
$2 | Logical volume name |
$3 | Volume group name |
$4 | File system type (optional. if empty, defaults to default FS type for this OS) |
$5 | Size (Default: megabytes, optional suffixes: [kmgt]. Special value: 'all' takes the whole free size in the VG. |
$6 | Optional. Directory owner[:group] |
Returns
0: OK, !=0: ErrorDisplays
Info msgfs_create
Create a file system, mount it, and register it (mount at boot)
Refuses existing directory as mount point (security)
Arguments
$1 | Mount point |
$2 | device path |
$3 | Optional. FS type (if empty, default FS type for this OS) |
$4 | Optional. Mount point directory owner[:group] |
Returns
0 if no error, 1 on errorDisplays
Info msgfs_create_lv_fs
Create a logical volume and a filesystem on it
Combines create_lv and fs_create
Arguments
$1 | Mount point (directory) |
$2 | Logical volume name |
$3 | Volume group name |
$4 | Size (Default: megabytes, optional suffixes: [kmgt]. Special value: 'all' takes the whole free size in the VG. |
$5 | Optional. File system type. Defaults to default FS type for this environment |
$6 | Optional. Directory owner[:group] |
Returns
0: OK, !=0: ErrorDisplays
Info msgfs_default_type
Returns default FS type for current environment
Arguments
None
Returns
Always 0Displays
Typefs_device
Gets the device of the filesystem containing a given path
Arguments
$1 | Path (must correspond to an existing element) |
Returns
Always 0Displays
The normalized device of the filesystem containing the elementfs_extend
Extend a file system to a given size
Arguments
$1 | A path contained in the file system to extend |
$2 | The new size in Mbytes, or the size to add if prefixed with a '+' |
Returns
Always 0Displays
Info msgfs_is_mount_point
Checks if a directory is a file system mount point
A filesystem must be mounted on the directory for it to be recognized as a mount point.
Arguments
$1 | Directory to check |
Returns
0 if true, !=0 if falseDisplays
nothingfs_mount_point
Gets the mount point of the filesystem containing a given path
Arguments
$1 | Path (must correspond to an existing element) |
Returns
Always 0Displays
The mount directory of the filesystem containing the elementfs_size
Get the size of the filesystem containing a given path
Note: This function is to be used for a mounted filesystem. In order to get the size of a file system contained in a given device (mounted or not), use disk_fs_size.
Arguments
$1 | Path (must correspond to an existing element) |
Returns
Always 0Displays
FS size in Mbytesget_fs_device
Gets the device of the filesystem containing a given path
### This function is deprecated. Please use fs_device.
Arguments
$1 | Path (must correspond to an existing element) |
Returns
Always 0Displays
The normalized device of the filesystem containing the elementget_fs_mnt
Gets the mount point of the filesystem containing a given path
### This function is deprecated. Please use fs_mount_point.
Arguments
$1 | Path (must correspond to an existing element) |
Returns
Always 0Displays
The mount directory of the filesystem containing the elementget_fs_size
Get the size of the filesystem containing a given path
### This function is deprecated. Please use fs_size.
Arguments
$1 | Path (must correspond to an existing element) |
Returns
Always 0Displays
FS size in Mbyteshas_dedicated_fs
Checks if a directory is a file system mount point
### This function is deprecated. Please use fs_is_mount_point.
Arguments
$1 | Directory to check |
Returns
0 if true, !=0 if falseDisplays
nothingset_fs_space
Extend a file system to a given size
### This function is deprecated. Please use fs_extend.
Arguments
$1 | A path contained in the file system to extend |
$2 | The new size in Mbytes, or the size to add if prefixed with a '+' |