2012年4月17日 星期二

libvirt-php in CentOS 5.X

# wget http://libvirt.org/sources/php/libvirt-php-0.4.5.tar.gz

# tar zxvf libvirt-php-0.4.5.tar.gz

# cd libvirt-php-0.4.5

# yum install libvirt-devel php-devel

# ./configure

# make

# make install

# ls -al /usr/lib64/php/modules/

# chmod 755 /usr/lib64/php/modules/libvirt-php.so

# cat /etc/php.d/libvirt-php.ini
; libvirt-php module
extension=libvirt-php.so

# php -m | grep libvirt
libvirt

# service httpd restart