You should call this after configuring the handle
(eg. adding drives) but before performing any actions.");
- ("wait_ready", (RErr, [], []), -1, [NotInFish],
+ ("wait_ready", (RErr, [], []), -1, [NotInFish; DeprecatedBy "launch"],
[],
"wait until the qemu subprocess launches (no op)",
"\
"\
This function adds a virtual CD-ROM disk image to the guest.
-This is equivalent to the qemu parameter C<-cdrom filename>.
+This is equivalent to the qemu parameter I<-cdrom filename>.
Notes:
"add qemu parameters",
"\
This can be used to add arbitrary qemu command line parameters
-of the form C<-param value>. Actually it's not quite arbitrary - we
+of the form I<-param value>. Actually it's not quite arbitrary - we
prevent you from setting some parameters which would interfere with
parameters that we use.
Arch Linux.
+=item \"centos\"
+
+CentOS.
+
=item \"debian\"
Debian.
=item \"rhel\"
-Red Hat Enterprise Linux and some derivatives.
+Red Hat Enterprise Linux.
+
+=item \"scientificlinux\"
+
+Scientific Linux.
=item \"slackware\"
*)
let daemon_functions = [
- ("mount", (RErr, [Device "device"; String "mountpoint"], []), 1, [],
+ ("mount", (RErr, [Device "device"; String "mountpoint"], []), 1, [DeprecatedBy "mount_options"],
[InitEmpty, Always, TestOutput (
[["part_disk"; "/dev/sda"; "mbr"];
["mkfs"; "ext2"; "/dev/sda1"];
("sfdisk", (RErr, [Device "device";
Int "cyls"; Int "heads"; Int "sectors";
- StringList "lines"], []), 43, [DangerWillRobinson],
+ StringList "lines"], []), 43, [DangerWillRobinson; DeprecatedBy "part_add"],
[],
"create partitions on a block device",
"\
The exact command which runs is C<file -zb path>. Note in
particular that the filename is not prepended to the output
-(the C<-b> option).
+(the I<-b> option).
-This command can also be used on C</dev/> devices
-(and partitions, LV names). You can for example use this
-to determine if a device contains a filesystem, although
-it's usually better to use C<guestfs_vfs_type>.
+The output depends on the output of the underlying L<file(1)>
+command and it can change in future in ways beyond our control.
+In other words, the output is not guaranteed by the ABI.
-If the C<path> does not begin with C</dev/> then
-this command only works for the content of regular files.
-For other file types (directory, symbolic link etc) it
-will just return the string C<directory> etc.");
+See also: L<file(1)>, C<guestfs_vfs_type>, C<guestfs_lstat>,
+C<guestfs_is_file>, C<guestfs_is_blockdev> (etc).");
("command", (RString "output", [StringList "arguments"], []), 50, [ProtocolLimitWarning],
[InitScratchFS, Always, TestOutput (
This command is entirely equivalent to running C<fsck -a -t fstype device>.");
("zero", (RErr, [Device "device"], []), 85, [Progress],
- [InitBasicFS, Always, TestOutput (
+ [InitBasicFS, Always, TestRun (
[["umount"; "/dev/sda1"];
- ["zero"; "/dev/sda1"];
- ["file"; "/dev/sda1"]], "data")],
+ ["zero"; "/dev/sda1"]])],
"write zeroes to the device",
"\
This command writes zeroes over the first few blocks of C<device>.
("sfdisk_N", (RErr, [Device "device"; Int "partnum";
Int "cyls"; Int "heads"; Int "sectors";
- String "line"], []), 99, [DangerWillRobinson],
+ String "line"], []), 99, [DangerWillRobinson; DeprecatedBy "part_add"],
[],
"modify a single partition on a block device",
"\
See also: C<guestfs_part_add>");
- ("sfdisk_l", (RString "partitions", [Device "device"], []), 100, [],
+ ("sfdisk_l", (RString "partitions", [Device "device"], []), 100, [DeprecatedBy "part_list"],
[],
"display the partition table",
"\
"check an ext2/ext3 filesystem",
"\
This runs C<e2fsck -p -f device>, ie. runs the ext2/ext3
-filesystem checker on C<device>, noninteractively (C<-p>),
-even if the filesystem appears to be clean (C<-f>).
+filesystem checker on C<device>, noninteractively (I<-p>),
+even if the filesystem appears to be clean (I<-f>).
This command is only needed because of C<guestfs_resize2fs>
(q.v.). Normally you should use C<guestfs_fsck>.");
get a simple list of names, use C<guestfs_ls>. To get a printable
directory for human consumption, use C<guestfs_ll>.");
- ("sfdiskM", (RErr, [Device "device"; StringList "lines"], []), 139, [DangerWillRobinson],
+ ("sfdiskM", (RErr, [Device "device"; StringList "lines"], []), 139, [DangerWillRobinson; DeprecatedBy "part_add"],
[],
"create partitions on a block device",
"\
"create a hard link",
"\
This command creates a hard link using the C<ln -f> command.
-The C<-f> option removes the link (C<linkname>) if it exists already.");
+The I<-f> option removes the link (C<linkname>) if it exists already.");
("ln_s", (RErr, [String "target"; Pathname "linkname"], []), 166, [],
[InitScratchFS, Always, TestOutputStruct (
"create a symbolic link",
"\
This command creates a symbolic link using the C<ln -sf> command,
-The C<-f> option removes the link (C<linkname>) if it exists already.");
+The I<-f> option removes the link (C<linkname>) if it exists already.");
("readlink", (RString "link", [Pathname "path"], []), 168, [],
[] (* XXX tested above *),
"\
This command resizes an NTFS filesystem, expanding or
shrinking it to the size of the underlying device.
+
+I<Note:> After the resize operation, the filesystem is marked
+as requiring a consistency check (for safety). You have to boot
+into Windows to perform this check and clear this condition.
+Furthermore, ntfsresize refuses to resize filesystems
+which have been marked in this way. So in effect it is
+not possible to call ntfsresize multiple times on a single
+filesystem without booting into Windows between each resize.
+
See also L<ntfsresize(8)>.");
("vgscan", (RErr, [], []), 232, [],
=item C<features>
-This passes the C<-O> parameter to the external mkfs program.
+This passes the I<-O> parameter to the external mkfs program.
For certain filesystem types, this allows extra filesystem
features to be selected. See L<mke2fs(8)> and L<mkfs.ufs(8)>
"resize an ext2, ext3 or ext4 filesystem to the minimum size",
"\
This command is the same as C<guestfs_resize2fs>, but the filesystem
-is resized to its minimum size. This works like the C<-M> option
+is resized to its minimum size. This works like the I<-M> option
to the C<resize2fs> command.
To get the resulting size of the filesystem you should call