X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=generator%2Fgenerator_actions.ml;h=26dc64e41cab4718788cc528c20a0ed044d86d8d;hb=5790f5bfafb12cc2ed9365461bf66e0fdfde7150;hp=c59964ab21641fb129ead20238b88a304c0628ec;hpb=9e7c6a548353bde925c16434711bcc6208038d83;p=libguestfs.git diff --git a/generator/generator_actions.ml b/generator/generator_actions.ml index c59964a..26dc64e 100644 --- a/generator/generator_actions.ml +++ b/generator/generator_actions.ml @@ -928,6 +928,12 @@ which is the filesystem that would be mounted there Non-mounted devices such as swap devices are I returned in this list. +For operating systems like Windows which still use drive +letters, this call will only return an entry for the first +drive \"mounted on\" C. For information about the +mapping of drive letters to partitions, see +C. + Please read L for more details. See also C."); @@ -1467,6 +1473,42 @@ the case then an error is returned. Please read L for more details."); + ("inspect_get_drive_mappings", (RHashtable "drives", [Device "root"], []), -1, [], + [], + "get drive letter mappings", + "\ +This function should only be called with a root device string +as returned by C. + +This call is useful for Windows which uses a primitive system +of assigning drive letters (like \"C:\") to partitions. +This inspection API examines the Windows Registry to find out +how disks/partitions are mapped to drive letters, and returns +a hash table as in the example below: + + C => /dev/vda2 + E => /dev/vdb1 + F => /dev/vdc1 + +Note that keys are drive letters. For Windows, the key is +case insensitive and just contains the drive letter, without +the customary colon separator character. + +In future we may support other operating systems that also used drive +letters, but the keys for those might not be case insensitive +and might be longer than 1 character. For example in OS-9, +hard drives were named C, C

etc. + +For Windows guests, currently only hard drive mappings are +returned. Removable disks (eg. DVD-ROMs) are ignored. + +For guests that do not use drive mappings, or if the drive mappings +could not be determined, this returns an empty hash table. + +Please read L for more details. +See also C, +C."); + ] (* daemon_functions are any functions which cause some action