How to add a disk to LVM

Suppose the Disk is /dev/sdb, the second scsi disk, fdisk /dev/sdb create as many partitions as you need using command n Label them with command t as 8e for making it Linux LVM Write and Exit with the command w. Format the partitions you require using mkfs command mkfs -t ext3 -c /dev/sdb1 LVM commands […]

Test if memcache is installed in php from bash line

php -i | grep -i memcache Short and sweet sample output : memcache memcache support => enabled memcache.allow_failover => 1 => 1 memcache.chunk_size => 8192 => 8192 memcache.default_port => 11211 => 11211 memcache.default_timeout_ms => 1000 => 1000 memcache.hash_function => crc32 => crc32 memcache.hash_strategy => standard => standard memcache.max_failover_attempts => 20 => 20 memcached memcached support […]

Using Expect to automate an scp filetransfer

Sometimes you know passwords but are not ion a position to use shared keys. Solution is using expect to pass the password from a script read or a comman line parameter. ** NOTE Passwords in command lines are a really bad idea since you can see them in the history / ps -ef so best […]

SVN checkout fails to authenticate

When running: svn checkout https://mysvn.mydomain.com:8443/svn/Linux/trunk/scripts/ –username *** –password ‘****’ I got : WARNING: gnome-keyring:: couldn’t connect to: /tmp/keyring-fTq763/pkcs11: No such file or directory Password for ‘default’ GNOME keyring: ***** svn: OPTIONS of ‘https://mysvn.mydomain.com:8443/svn/Linux/trunk/scripts’: authorization failed: Could not authenticate to server: rejected Basic challenge (mysvn.mydomain.com:8443) Problem could be damaged keyring or wrong keyring password. To fix […]

SSH through HTTP proxy

This article explains how to connect to a ssh server located on the internet from a local network protected by a firewall through a HTTPS proxy. Requirement are : Your firewall has to allow HTTPS connections through a proxy You need to have root access to the server where ssh is listening Configure the ssh […]