Categories
Electronics Equipment Raspberry Pi

A case for my Raspberry Pi!

Heres a quick 7 minute video about a case I purchased for the Raspberry Pi that only cost £4 from eBay!

Categories
General

Handy Tidbits: Create lots of files on linux quickly for testing

dd bs=1000000 count=20475 if=/dev/zero | split -b 4095 -a 7 -d – foo.

foo. (filename), 4095 = filesize (in bytes).

Taken from a comment by klode at
http://www.askdavetaylor.com/how_can_i_quickly_create_millions_of_tiny_files_in_linux.html#eb8sC3UpjoMBX0U1.99

Categories
Electronics notes PHP

OSX 10.8.2 localhost directory & MySql / PHPMyAdmin

You know, just because it will bug me again at some point:

If for any reason you don’t want to use the “sites” folder for your web development, you can head to

/Library/WebServer/Documents

and upload code directly into your http://localhost folder.

to install PHPMyAdmin, just plop that PHPMyAdmin folder just downloaded right into the above folder.

To Install MySQL however, follow these steps:

Download the .dmg MySQL installed from MySQL.com

Run the first installed, then the auto-start installer, and finally the Preference Pane add-on.

Run this code in terminal:

sudo cp /etc/php.ini.default /etc/php.ini

and then load /etc/php.ini and replace any instance of

/var/mysql/mysql.sock

with

/tmp/mysql.sock

Start the MySQL server using the preference pane add-on, then run the following in Terminal:

/usr/local/mysql/bin/mysqladmin -u root password PASSWORD

Replacing PASSWORD with a password of your choice.

The last thing to do is head to the PHPMyAdmin directory, and copy the config.sample.inc.php to config.inc.php and edit that file, replacing the

$cfg['blowfish_secret'] = 'RANDOM BLOWFISH CHARACTERS'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */

RANDOM BLOWFISH CHARACTERS part with random characters!

Finally, head to http://localhost/phpmyadmin and your good to go!