When trying to compile PHP I noticed the libmcrypt package is no longer provided with EL6 / CentOS 6, checking whether to enable multibyte string support… no checking whether to enable multibyte regex support… yes checking whether to check multibyte regex backtrack… yes checking for external libmbfl… no checking for
Continue readingAuthor: Scott Mcintyre
Create new panel on second monitor
If you need to add a second panel/task window on your second (or more in my case) monitors using ubuntu/debian/mint linux here are two ways to achieve it. First you should right click on the current panel and click “New panel” then all you have to do is move the
Continue readingResizing ext4 partition centos 5
On CentOS 5 the e4fsprogs RPM provides a separate binary (/sbin/resize4fs) for resizing ext4 partitions. # rpm -qf /sbin/resize2fs e2fsprogs-1.39-23.el5_5.1 # rpm -qf /sbin/resize4fs e4fsprogs-1.41.9-3.el5 As I found out today when resizing an LVM partition on one of our mongodb snapshot systems. # lvextend -L+50G /dev/mapper/mongo Extending logical volume mongo
Continue readingnginx rewrite PHP with no extension
I recently had to troubleshoot an issue while migrating from cherokee to nginx. This was a PHP application which had a shared set of common scripts , these where accessed by domain/common/file which in turn was translated into /vhosts/shared/common and this then included the necessary files. After doing the rewrite
Continue readingError: unsupported locale setting
While installing and configuring trac on my development VM it wouldn’t load over HTTP (500 error). Stracing the process returned the issue, Error: unsupported locale setting So it looks like it doesn’t have the locale installed (In my case EN_GB) this is easily fixed by running, sudo dpkg-reconfigure locales Then
Continue readingpython load betfair data to mysql
The script below will import the betfair data from data.betfair.com into a mySQL table. First create the table, CREATE TABLE history ( sports_id int(11) DEFAULT NULL, event_id int(11) DEFAULT NULL, country varchar(10) DEFAULT NULL, scheduled_off varchar(30) DEFAULT NULL, actual_off varchar(30) DEFAULT NULL, full_description varchar(150) DEFAULT NULL, odds double DEFAULT NULL,
Continue readingpython attheraces.com data scraping
I have been working on scraping the data from attheraces.com for a project I am working on which combines this and betfair data for some statistical analysis. In case this is useful to anyone here is the regex I have written, meetings = re.findall(“<h5 id=\”fastfixhead(\d+)\”.*\”>(\w+)<\/a><\/h5>”, info) for meeting in meetings:
Continue readingDell Studio 15555 Windows Key
While trying to reinstall one of my windows laptops (A Dell 1555 Studio) to Windows 7 I had alittle trouble locating the windows activation/product key. After alittle fiddling I managed to locate this well hidden under the battery. So if you are looking for this on your dell laptop try
Continue readingMax processes 1024 limits.conf
We where having an issue with replica sets on our MongoDB databases changing primaries. The logs shows it was hitting resource limits creating new processes. [initandlisten] pthread_create failed: errno:11 Resource temporarily unavailable [initandlisten] can’t create new thread, closing connection There is a bug fix in the init.d available per https://jira.mongodb.org/browse/SERVER-6443
Continue readingLinux convert AIFF to mp3
You can convert AIFF files to MP3 using ffmpeg on linux. This works with many other inputs and not just AIFF but in the instance I was testing I needed to convert AIFF. First you need ffmpeg and libmp3lame which on Ubuntu and Linux Mint can be done with sudo
Continue reading