Archive for the 'PHP' Category

Goodbye Fedora, Hello Slackware

Sunday, 28th May, 2006

So I got XDebug working a couple of weekends ago. After much fun trying to install KCacheGrind on Fedora and setting up X forwarding to my Windows box I finally saw the fruits of my labour.

KCacheGrind on Windows via XMing

I was impressed with the Call Graph which shows the flow of execution. This is a framework I spent some time developing in April for a music store. I hope to make more use of this profiling at work some time.

Ironically just as I had got this working my Fedora install starts to play up (after running fine with no X for 18 months beforehand). The filesystem would become read-only after several hours idling. Turns out a part of the filesystem was corrupt; I was constantly having to reboot and run fsck to correct these errors. However yesterday fsck took ages to sort things out and more and more files were being lost so I figured it was time to re-install.

Fedora has been my distribution of choice for a couple of years but this is the second time I’ve had to wipe the drive due to disk errors. I think this is largely due to heat issues, my linux box is a shuttle PC and it gets pretty hot compressing off-site backups from this co-located server come 5am! After re-partitioning, formatting and running check disk in Windows, the drive seemed completely healthy (most odd considering on boot it was reporting “S.M.A.R.T bad” errors). When re-formatting in Slackware and checking for bad sectors - none found! Strange albeit good news I guess.

So why Slackware? Well after the messing around required to get KDE up and running on Fedora I wanted to move to a pro-KDE distribution. I’m not a fan of managed distro’s like Gentoo (emerge yuk!). Call me a control freak but too much happens behind the scenes, I like to install the major applications from source so unexpected changes don’t occur when you update system packages. I also prefer the default layout of Apache/PHP/MySQL, upgrades are easier, no waiting on your fav distro to prepare customised packages.

Slackware has thrown me a few curve balls early on though (just getting vim working correctly!). I forgot to install atk, which appears to be a GNOME library (so much for a GNOME free system), and ‘vi’ was symlinked to elvis (which from my brief experience seems horrible). Turns out Slackware is BSD init based not System V, meaning it doesn’t use the rc.1, rc.2 directories like Redhat etc. This was enough to trip me up when trying to install the mysql.server init.d script, easily solved though:

cp support-files/mysql.server /etc/rc.d/rc.mysqld

Umm’ing and arrh’ing

Saturday, 27th May, 2006

We’re moving offices soon at work, in the process we’re having a serious clear out due to the reduced space we’ll have at the new premises. As a result I’ve picked up a couple of unwanted Java books. I never appreciated how similar OO PHP5 code is to Java, infact it looks like a complete rip off! I had also not appreciated how many OO concepts I’d become familiar with…

This of course got me thinking, I might stretch my programming legs and have a look at Java over the summer. I can’t see it being much of a leap from the PHP5 code I’ve been writing in my own time. There’s a few new things in there like inner classes, nested interfaces and threads but with the majority of the concepts I feel I’m already comfortable. Continued squabbles on the PHP internals list only encourage me to do this, who knows, there’s a whole lot more Java jobs out there (which are better paid too!).

This is a turn around from the time I spent over Christmas looking at C# :)

Where now?

Saturday, 1st October, 2005

I feel like I’ve learnt a lot as a developer in the last 12 months; increasingly though I am frustrated with PHP (my primary language that I have to use at work). I’ve spent several months researching other languages as a new home for my personal development efforts (no scope to move from PHP at work). I had my targets set on C#.

Prior to frequenting Channel9 I was quite the anti-MS/open source zealot. However I believe C# is a promising technology; with some interesting developments in the pipeline.

My only gripe is being tied down to Windows, which = £££ and forced upgrade cycles. I have installed mono but trying to use MS Visual Web Developer as an IDE (which is .NET 2.0 friendly) caused for a bit of conflict.

You are currently browsing Greg’s blog (software development and operating systems) archives in the PHP category.

Categories

My Bookshelf

PHP in Action: Modern software practices for PHP Agile Web Development with Rails
xhtml 1.1 compliant   xhtml 1.1 compliant