Mediawiki site generating Warning: Invalid argument supplied for foreach() in LocalisationCache.php on line 390

Had to blog about this, as I had a problem with one of my MediaWiki sites that I moved onto a shared hosting provider.

Every page when loaded would generate the error below displayed somewhere on the page. i.e in my case at the top in my header region.

Warning: Invalid argument supplied for foreach() in /path/to/file/includes/cache/LocalisationCache.php on line 390

The fix for this is easy, just run the rebuildLocalisationCache.php script in maintenance folder and if you don’t have access to run it via a shell you can add the following line into your LocalSettings.php file instead;

$wgLocalisationCacheConf[‘manualRecache’] = true;

Check out the page here for more specific details on the script use etc.

Turnigy Brushless 4WD Monster Beatle suffers first failure

I didn’t really post about this, but I gave my 4 year old son a 1/16 scale Turnigy Brushless 4WD Monster Beatle that completely adores. You can check it out over at HobbyKing via the direct link here.

He is allowed to use it when supervised and in a nice open area like a park, since running it on 2S LiPo means it moves pretty quickly. This could of been limited by the use of a more expensive controller, but I opted to get all the bits from the Australian Hobbyking Warehouse to limit postage costs.

Anyways, long and the short of the story is that it suffered it’s first failure. The steering servo looks as though it probably has stripped some gears, although I am not surprised as everyone mentioned this would probably happen. I think the main reason it did as he actually ran the thing into an object by accident.

Not to fear, some spare parts ordered on Sunday.

Still impressed with the Remote Control car itself, as its a lot of fun for the price.

ERROR 2013 (HY000): Lost connection to MySQL server during query

Recently had a problem with a MySQL iDA backup on a Linux platform. I was seeing a failure where we would get the error below (and per subject) included in the CommVault backup error.

ERROR 2013 (HY000): Lost connection to MySQL server during query

Upon further investigation it was determined that the error was being triggered during a MySQL query as performed by the MySQL iDA during backup attempt. When we attempted to do the same query manually against a MySQL connection we’d also get the same error. It was determined from the MySQL iDA logs that the database causing us the problem was called “prod”.

See the example below;

# mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 4
Server version: 5.1.32-community-log MySQL Community Server (GPL)

Type 'help;' or 'h' for help. Type 'c' to clear the buffer.

mysql> use prod
Database changed
mysql> show table status;

ERROR 2013 (HY000): Lost connection to MySQL server during query

As you can see the error was reproducible. Further investigation determined that the database was corrupt in some way, as we could see a large number of errors in the MySQL logs. Fix the corruption on the database and/or exclude it from the backups until resolved by the MySQL DBA.

RasPBX, FreePBX Trunk setup for MyNetFone

As per my previous posts, I use MyNetFone as my SIP provider and I run a Raspberry Pi with RasPBX (which is FreePBX for the Raspberry Pi ready to install/tweak and configure).

Below is a quick run down on how you can configure your SIP Trunk for MyNetFone on this device, which is working for me currently.

General Settings:

Trunk Name: mynetfone
Outbound CallerID: [configure based on your 09nnnn number or your DID if you have one]

Outgoing Settings:

Trunk Name: mynetfone-sip-out
Peer Details: (as below)

Registeration String:

Raspberry Pi and RasPBX

Last week, on a Friday night of all things. Decided I would give RasPBX another go. After spending a bit of time on it had managed to configure my DID, my extension and setup inbound routes.

I configured enough to be able to leave it running until I can configure the other features I was using on my more manual setup. Which includes time based rules and IVR. Will get to those items in the next few days.

Will do another post shortly that shows how I got my SIP provider (MyNetFone) setup via the Trunks.


Raspberry Pi and Asterisk

I’ve had my Raspberry Pi and Asterisk setup running now for nearly 2 months. It hasn’t failed me once in this time.

If you remember back I ended up installing Raspbian and configuring Asterisk manually from command line. This setup suits me, as I want to learn about how it all works, not learn how to use one of the dedicated images that has a fancy web GUI (and learn how to use that). I might end up changing to that type of setup eventually, however what i have now works with all the features I need.

Will be sure to post back as time progresses with this setup.


Realtek RTL2838 DVB-T tuner with TvHeadEnd

I’d really love to get my USB based tuner to work on my Raspberry Pi for use with TvHeadEnd. My tuner as seen via lsusb output is below..

Bus 001 Device 004: ID 0bda:2838 Realtek Semiconductor Corp. RTL2838 DVB-T

Anyone had any luck getting this to work with TvHeadEnd? If so add something in the comments.