[libvirt] Create domain using libvirt-php
Hello...! I want to create a new domain using libvirt-php, and after creating I want to start it. I have seen this to create new domain: libvirt_domain_new($conn, $name, $arch, $memMB, $maxmemMB, $vcpus, $iso_image, $disks, $networks, $flags) So in the above sysntax what should I pass in $iso_image? $disk? $networks and $flag?? Please give me a complete example that can solve my problem. Thanks.. -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
[libvirt] Need Help To Destroy Virtual Machines
Hello...! I am using libvirt-php for controlling my xen virtual machines. For this I have installed libvirt-php along with xampp server. Now I need to create a web based controll panel application which shows me running vms, and some options like Shutdown, Pause, Create, Destroy. My aim is, when I click Destroy button the selected vm should be destroyed. For this I have used the following php-script: ?php $conn=libvirt_connect(xen:///); $name=libvirt_domain_lookup_by_id($conn,4); // Here '4' is the id of my running vm $dest=libvirt_domain_destroy($name); echo $dest; ? When I execute this it shows me following warning: Warning: libvirt_domain_destroy() [function.libvirt-domain-destroy]: operation virDomainDestroy forbidden for read only access in /opt/lampp/htdocs/xampp/xen/test.php on line 5 So, Could you please help me to solve this? ! Thank You ! -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
[libvirt] LIBVIRT-PHP List of domains
Hi.. I am trying to get the names of all the xen domains using libvirt-php. I saw this php script: ?php $conn = libvirt_connect('null', false); $doms = libvirt_list_domains($conn); print_r($doms); ? It gives me error. Could you please tell me how to connect to xen hypervisor? I have also tried: $conn = libvirt_connect('xen:///', false); but it wont work.. -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list