Libvirt Functions
PHP Manual

libvirt_storagepool_lookup_by_name

(php-libvirt 0.4)

libvirt_storagepool_lookup_by_nameLookup storagepool resource by name

Description

array libvirt_storagepool_lookup_by_name ( resource $connection , string $storagepool name )

This function returns the storagepool resource for the given name.

Parameters

connection

Connection resource of hypervisor.

storagepool name

Name of a storagepool

Return Values

Storagepool resource identiefier. FALSE on failure

Examples

Example #1 libvirt_storagepool_lookup_by_name() example

Return storagepool resource identifier

<?php

    $conn
=libvirt_connect($uri,true);
    
$pool=libvirt_storagepool_lookup_by_name($conn'default');

    
var_dump($pool);
?>

The above example will output something similar to:

resource(3) of type (Libvirt storagepool)

See Also


Libvirt Functions
PHP Manual