Cook Me.

This is on my list of things to cook. Soon. Posting it here so I have *no* excuse. Instructions from a friend:

Visi: you should make the roast squash!
Visi: chop them in half, scrap out the seeds, score it with a grid, rub butter in, coat in salt and pepper and roast
Visi: put a lil bit of curry powder on near the end
Kirrus: temperature?
Visi: 180 I guess
Visi: whatever temperature you want!
Visi: takes a while but when you can shove a fork through it it’s done
Visi: *easily

Go (wéiqí, igo, baduk, cờ vây) opening

I’ve been playing Go a bit of late, and a friend was taught this about openings, during a review of a game on KGS. Posting it here mainly so I remember for the future! 🙂

Teofrostus [2k]: when you're playing go, there's a nice checklist that you should go through during the opening 
Teofrostus [2k]: it goes something like this
Teofrostus [2k]: 1) Do I have any weak groups?
Teofrostus [2k]: 2) Does my opponent?
Teofrostus [2k]: 3) Are there any unapproached corners? [opponent corners before allied corners]
Teofrostus [2k]: 4) Are there any "big points" left?
Teofrostus [2k]: and you should respond to these in this order

Also worth noting:
Teofrostus [2k]:it's something that you should follow until you're like 3d

Quote of the Day

But in truth it had not exactly been gold, or even the promise of gold, but more like the fantasy of gold, the fairy dream that the gold is there, at the end of the rainbow, and will continue to be there for ever provided, naturally, that you don’t go and look.

This is known as Finance.

– Terry Pratchett

MySQL Linux CLI command execution

As another aid to my memory, you can run mysql commands on the command line like this:

mysql -u user -p[password] database -e "SELECT * FROM orders;".


You can also send the mysql client commands on stdin:

echo "SELECT * FROM orders" | mysql -u user -p[password] database


Or read them in with a file redirection

mysql -u user -p[password] database < /home/kirrus/orders.sql

That last one is really handy for reading MySQL dumps back into MySQL.

MySQL GRANT syntax oddity, show views

So that I don’t forget: Despite what the documentation says, being unclear (links always have an underscore over there, so it’s hard to tell difference between a linked underscore linked item, and one merely space-separated), you should grant ‘SHOW VIEW’, not ‘SHOW_VIEW’. Additionally, ‘SHOW VIEW’ really needs SELECT permissions as well.

bind refuses to restart, debian squeeze

After an upgrade, I’ve noticed a few times that bind has refused to restart or reload, saying:

Stopping domain name service: namedrndc: connect failed: connection refused

This seems to be a permissions bug in debian, quite a long lasting one. In order to cheat-fix it quickly, I do the following:

chown bind:root /etc/bind/rndc.key
chmod 660
/etc/init.d/bind9 restart

That seems to fix it well enough. I think it’s a problem in that bind starts as one user, but runs as another. It may be that 440 are all the perms that are necessary. The debian bug report is here:

Magento Session Files

Magento (the popular open-source online shop system) likes to store its PHP session files in ~/public_html/var/session/

Most debian servers don’t have that in their cron job that deletes old session files.

So, you probably want to set it to store it’s session files in the default location (/var/lib/php5) or alter your cron job (/etc/cron.d/php5)