Category Archives: Uncategorized - Page 2

XFS on Centos 6 32bit – not compatible with life

XFS will not operate on Centos 6 32bit, you must use the 64bit version.

eom

Crontab

yum install vixie-cron crontabs
/sbin/chkconfig crond on
/sbin/service crond start

sFlow XenServer

Download iso

http://sourceforge.net/projects/host-sflow/files/REL-1_22/

HERE!

mount and install.

service hsflowd start
service sflowovsd start

chkconfig hsflowd on
chkconfig sflowovsd on

edit conf file

nano /etc/hsflowd.conf

agent = xenbr0

DNSSD = off
polling = 20
sampling = 512

collector {
ip = 10.1.1.x
udpport = 6343
}

service hsflowd restart

gluster path stale usage path

http://joejulian.name/blog/glusterfs-path-or-a-prefix-of-it-is-already-part-of-a-volume/

hp sim xenserver agents..

ls -ld /

does it return

drwx—— 24 root root 4096 Feb 5 16:41 /

then execute this!

chmod 755 /

Free up space on NFS share

tune2fs -r 0 /dev/xvde1

reset reserved blocks to zero!

php-wkhtmltox

wkhtmltox is a great piece of kit to convert webpages to PDF format.

It is – however – an absolute Pita to install, as there are minimal resources on the net for installing this onto a Linux Server.

The first step is to download both the static library

libwxhtmltox

and the wkhtmltox static binary

wkhtmltopdf

Both of these can be downloaded from the Google Code repository found HERE Download the correct files for your server (i386 or amd64).

The will be packed in the unusal bunzip2 format, to exact type

bunzip2 #filename#

Then tar the file out with

tar xvf #filename#

copy the wkhtmltox directory to /usr/local/include
copy the lib/libwkhtmltox.so to /usr/local/lib/

unpack wkhtmltopdf and copy to a dir which is symlinked so you can use the CLI version from anywhere in your shell.

To add the PHP-extension requires a little more trickery.

Firstly download the source from HERE

unpack and run these commands


phpize
./configure
make test
make install

If the make test fails, it usually will mean that php was unable to load the library, so you need to add the following .

Go to

/etc/ld.so.conf.d/

and edit (or create if it doesn’t exist)

usr-local-lib.conf

add the following path

/usr/local/lib

then in your php.ini file add

extension=phpwkhtmltox.so

restart your web server, and check your phpinfo() to make sure the phpwkhtmltox extension has been loaded.

If you are installing on 32bit Centos 5.x you may have a very hard time trying to figure out why the phpize/configure fails. It usually means that you don’t have fontconfig installed, or it is an older version.

If you want to produce PDF’s from a site that is SSL enabled, you will fail… miserably… WKHTML 0.11 breaks UNLESS openssl-devel package has been installed… I lost 4 years of my life and now have a head full of grey hair. Hopefully this little tid bit of information helps some other poor soul.

You may also find that the rendered PDF’s have garbled boxes, you will need these fonts installed – on Centos

yum install urw-fonts