ChipmunkNinja
Ninjas are deadly. Chipmunk Ninjas are just weird.
About this blog
Marc Travels
Marc on Twitter
JustLooking on Twitter

Marc Wandschneider is a professional software developer with well over fifteen years of industry experience (yes, he really is that old). He travels the globe working on interesting projects and gives talks at conferences and trade shows whenever possible.

My Publications:

My book, "Core Web Application Programming with PHP and MySQL" is now available everywhere, including Amazon.com

My "PHP and MySQL LiveLessons" DVD Series has just been published by Prentice-Hall, and can be purchased on Amazon, through Informit, or Safari


ABCHKMPRaRoSTVW
xxxxx-xxxxxxxxx

Popular Articles:


Top Tags:


Recent Comments:

cncool wrote:

GLint zeroOpacity = 0;
[[self openGLContext] setValues:&zeroOpacity forParameter:NSOpenGLCPS...
Posted to: Things I've learned about CoreImage (and Quartz, and OpenGL) in two weeks
Dec 25, 2008 | 00:07:35
Christmas in Beijing
By marcwan

Not having particularly large numbers of Christians, for most of Asia Christmas is not an official holiday. Everybody trundles off to work at 8am in the morning like any other day, banks and government services remain fully operational (if completely unhelpful) and few – if any – people have trees or other decorations in their homes – gifts and the like are rare.

As such, it has been interesting to see how Christmas is becoming a bit of a “thing” here in Beijing, and entirely unlike what one would expect. Nearly every mall, shop, and restaurant has some sort of decoration, ranging from tinsel snowflakes to cutouts of Shèngdàn Lǎorén (Santa Claus), to big signs proclaiming 圣诞节快乐 (Merry Christmas). While old people tend to not care and are usually more than barely aware that the holiday is passing, the younger generations (and therefore the commercial enterprises who depend on their dollars) seem to be quite into the whole thing, with groups of coworkers sharing cakes at the office or going out for meals with little Reindeer antler hats on.

One aspect of it all is that Beijing becomes something of an expat ghost-town for the holidays. Many people leave to go back to their home countries, and those who live here tend to hunker down in their little expat enclaves such as Shunyi or Wangjing. What’s left are the (typically younger) foreigners who either couldn’t leave because of work, or decided simply not to bother. The expat restaurants and bars all begin the annual business “dry season” which usually lasts until the arrival of spring (and, coincidentally enough, actual rain).

Thus, it was with some surprise last night that, as a few of us went out for drinks at Q Bar, home to some of Beijing’s finest mixed drinks, traffic in the city was a complete mess. Any place that had bars and clubs was a complete madhouse, and even big shopping areas were all quite packed. Yet, only those places that catered to the locals were full – expat places such as Sanlitun and the like were still completely deserted.

What was going on was that all the locals were going out and partying. But instead of doing presents or any sort of family thing, it was more along the lines of New Years partying, with countdowns to Christmas tree lightings, party hats and streamers, and otherwise drunken revelry. No arguing here about how the holiday has lost its spiritual meaning and roots here – it never had any in the first place. For the Chinese, it’s just another way to participate in some of the things that Westerners like, but do it in their own unique way, and have a blast at the same time.

Here is a video from the local Chinese YouTube rip off (called YouKu):

In another uniquely Chinese way, many of those restaurants and shops will be sporting those same Christmas decorations until well into the summer. It is not unusual for me to be having Sweet and Sour Pork somewhere in July, with a big bearded Santa watching over me.

[Read Rest of Article]
Comments (0) Add Comment | Tags: christmas xmas china
Oct 21, 2008 | 00:32:04
Travel site updated
By marcwan

Over the years, I’ve been a number of different places, and generally taken far too many photos of them. I’ve kept a log of all these photos (partly to keep my family from worrying about me and partly to help me remember all the places I’ve been and people I’ve met) over that time. This site was first called europe.lanfear.com, then travel.lanfear.com, and now marcwan.com

The last time I updated the site was in mid-2000 to handle more than just the reports from the Europe trip I did in 1999. Since then, a single XML file has been suffering under the weight of about 100 trips and some 200 more sub-trip reports.

So, a few months ago, I started a little side project to rewrite the engine entirely from scratch, moving to PHP and MySQL, and handling some of the scalability issues by moving the image serving to Amazon’s S3 service. The result is a new site that, while superficially similar to the old one, is completely new and improved and more awesomer. By using MySQL’s FULLTEXT indexes, the site now has search capabilities, and I’ve also added support for panorama photos and YouTube-like videos that anybody can view in their browser.

The next time I get some spare time, I’ll go ahead and add in some support for comments, but for now, enjoy the new site, and the 20-odd new trip reports that just been added!

[Read Rest of Article]
Comments (3) Add Comment | Tags: marcwan.com travel blog photos trip reports
Oct 15, 2008 | 02:59:43
My iPhone is dead, long live my iPhone
By marcwan

I bought an 8GB first generation iPhone 10 months ago, and have generally been thrilled with it, especially after it was jail-broken and I installed iCosta on it, which allowed me to enter Simplified Chinese characters for use here in mainland China. I had planned to, sometime after a full year of ownership, write up my experiences with the phone and general thoughts.

The theft of said iPhone in Delhi a week ago pretty much put an end to those plans. I had just taken a night train from Rishikesh in the Himalayas to the Nizamuddin station in Delhi, and was suffering from something not unlike dysentery. As I stood around in a daze at the pre-paid taxi stand trying to get a ride to the airport with my phone casually stuffed into a pocket, I must have been bumped by one of any number of people trying to get me into their taxis to who knows where and had it lifted. When I got to the Delhi airport, it was no longer in said pocket. I am sure it did not fall out of my pocket in the taxi because after I lost my camera that way in Mumbai, I started checking the back seats of cabs diligently!

So, I was without a cell phone for a week, and had some time to reflect on my unexpectedly short period of ownership. I was originally thinking I would wait until mid-late next year before looking at what the current offerings were, since the 3Gs didn’t appear to be that huge of an improvement over the first generation.

In short, my impressions of the iPhone were as follows:

  • It is awesome. I’m maybe not as fan-boy as this guy , but right from the instant I was eating dinner in a Thai restaurant and saw a friend walk in with one of them in her hand, I was sold on the form factor and huge glass screen. I find myself constantly playing with my phone, whether it be to check the weather, re-read my SMSes for the hundredth time, or otherwise just play a quick game of backgammon (note: computers can play a perfect game every time. If you set the difficulty level to “high”, be prepared to be quite depressed). This feeling of awesomeness has never worn off.
  • The glass keyboard is no substitute for a real tactile one. I owned a Treo in the past, and it doesn’t take long to develop fast, error-free typing skills on those. No matter how much practice I get typing on the iPhone, conversely, it’s a minor hassle, more so for Asian languages, where there is no room for error at all in terms of character guessing.
  • The camera is pretty ghetto. I’ve taken some nice photos with the iPhone, but really, will always carry a real camera around with me.
  • There are two missing applications, in my mind: MMS and video recording. I got around MMS by using SwirlyMMS, which has evolved into a truly excellent application over the year. This requires a jail-broken phone, but since I live in China, this was a requirement anyway. There are a couple of video recording applications that cost some money, but I haven’t bothered yet.
  • Apart from the camera, the iPhone is replacing many devices in my electronics stable. I now no longer bother with watches or alarm clocks – the phone does both of these well – and I rarely carry around pen and paper now either. I just take notes in the “Notes” application (well, “备忘录”on mine) whenever necessary.
  • The speaker is a bit quiet on the phone. I missed a huge number of calls and SMSes because I never heard them while the iPhone was in my pocket or bag.
  • The iPhone has completely obsoleted the cool little red iPod nano I have. I feel quite bad for the little guy, because it’s really a wonderful little piece of electronics. The flipside to this is that when you add video to the equation, 8GB is simply not enough. I have maybe 90 minutes of some cartoons, a few episodes of “The Soup”, and some music, and my iPhone is stuffed.
  • The device is generally quite sturdy. I have had a few heart stopping drops flat onto concrete from 3-4’, with no real damage at all. However, the phone got a huge scratch on the glass when I put it into one of those airport security plastic boxes for running through the X-Ray machine.

But really: given how much time I spend with the phone, the impressions are extremely positive. I constantly recommend it to anybody who asks.

After arriving in Beijing, I went out and purchased a new iPhone, this time opting for a 16GB 3G phone. I plugged it into my Mac, and iTunes (after upgrading to a new version grrr) offered to restore all my settings, which I accepted. The loss of my old phone was not a big deal in most regards—I had my contacts, calendars, and such things backed up to my laptop. The Notes application, however, supposedly did not do backups, and I was devastated at the loss of all the notes I had taken during my recent month of yoga in Mumbai. To my absolute joy, all of these notes were waiting for me upon restarting after the restore! My general impressions of this new iPhone:

  • I don’t like the plastic case. It comes across as cheap, and the form factor of the aluminum one was both thinner and had a nicer feel. The new one does feel lighter, for some reason, however, despite only a 2g difference.
  • The 3G data access is wicked. I struggled to use 10MB per month with the old iPhone, whereas I might see myself going to the unlimited plan with the new one.
  • The speaker is much louder, so I miss a lot fewer calls and SMSes now. The downside to this is that I no longer miss the spam messages I get here in China. Fortunately, these are still reasonably few.
  • My new phone, with its built-in Chinese translation and excellent Chinese Pinyin IME input mode, is the perfect worldwide phone. Except that on restarting it, it doesn’t seem to find any cell networks unless it’s in English mode. Go figure.
  • The 2.1 software is nicer than the 1.1.4 I was running before, although probably not significantly. The improvements in locale and translation support are phenomenal, but those using the phone in English probably wouldn’t even notice. Other changes are nice, but really just minor tweaks.

If you’re the owner of a first-generation iPhone and thinking about upgrading to the 3G phones, is it worth it? Absolutely not. If you suddenly lose, destroy, or otherwise find yourself no longer in possession of your first-gen phone, should you upgrade? In a legitimate market scenario, you probably don’t have any choice, but in a place such as here in China, where markets still carry the older phones, the choice is a bit tougher: the older phones sell for a couple hundred dollars less than the 3G phones, and do look nicer. For me the space and newer software with better Chinese support were the key selling points. It might not be enough for others.

[Read Rest of Article]
Comments (0) Add Comment | Tags: iphone stolen 3G impressions review
Aug 25, 2008 | 04:53:48
PHP Programming in Mumbai
By marcwan

And so it came to pass that I was wandering around downtown Mumbai the other day, purchasing a new Canon snapshot camera, since mine had mysteriously gone missing upon my arrival in Mumbai (mysteriously = I left it on the seat of the taxi from the airport to the hostel). In this neighbourhood, near Victoria Terminus (or VT), I just so happened to run into a number of computer book stores. I made a point of popping in and seeing what sort of PHP books they had.

The answer was: not many. This country is mostly a Microsoft shop, with a few Java people here and there.

But in one store, I did manage to find they had a “low price edition” of my book, which I knew had been published. 30-50$ USD for a book in India is outragageously expensive, so publishers print copies of the exact same book on cheap newsprint paper, and sell them for 10-12$ USD (500 Rs or so) instead.

So, I asked the kind guy who runs the store to take a photo of me with my book, and he was more than happy to oblige, in return for an autograph. I’m famous, hahah!

Marc with his book in downtown Mumbai

[Read Rest of Article]
Comments (4) Add Comment | Tags: marc book php web apps mumbai india
Aug 14, 2008 | 22:08:55
Life in Beijing during the Olympics
By marcwan

Well, after a good six weeks of traveling to many different places (Singapore, Hong Kong, New York City, Maine, and finally Seattle), I’m back in Beijing now. I had originally planned to avoid coming here on account of how difficult the visa situation was supposed to be, but after some research, it turned out to be quite trivial to get a full year tourist visa (with the caveat that I have to leave every two months and then come back). But with all the pre-Olympic-hullabaloo, I was still nervous about coming back here during the middle of the games—what would things be like?

The short answer is that it’s a bit more annoying here, but not ultimately not all that different. Security measures that have been in place for years but were never seriously enforced before are suddenly being checked rigorously. I awoke in a panic this morning when I realised that I slept through most of yesterday and didn’t make it to the local gong an ju – public security office – to register. So I ran there this morning and started chatting with them and they were all smiles and then told me to come back later because they couldn’t get to the government website anyway.

Traffic definitely is better than it was before—Banning half the cars from the road is, it seems, an awesome way to improve traffic and air quality. There are dedicated lanes for the Olympics here and there which make the occasional mess of traffic still, but overall, the roads are deserted compared to what they were merely two months ago.

Air has been harder to measure. The first two days after I arrived were very cloudy, humid, and overcast, so it didn’t seem that nice out. A nice round of thunderstorms, yesterday, however, cleared nearly everything up, and today one can see the mountains surrounding the city (which I didn’t notice when I first moved to China until after nearly three weeks of living here!).

Oddly enough, compared to some of the DSL I was experiencing in the USA, the Internet here is stunningly fast and reliable. Sure, some sites are blocked, but that’s what SSH proxies were invented for, and I’ve pretty much got everything I want at my fingertips, with great speeds to boot.

My favourite thing about being back? The food. It’s awesome eating here. Lots of vegetables (even the meat dishes), lots of fruit, and the occasional ice cream here and there to help with the heat and humidity. I’ve already hit up the good Szechuan restaurants, and will keep working on all my regular smaller places before leaving again next week.

One thing I found interesting is that, despite the obvious pride at doing so well at the Olympic games and winning so many gold medals, many Chinese people I talk with are pretty sardonic about the whole thing, recognising that governments can pretty much buy as many gold medals as they’re willing to spend money on…

So, here’s to hoping that by the time I come back from India, China has returned to being the same old crazy and fun place that it’s been to live in. I can’t wait.

[Read Rest of Article]
Comments (0) Add Comment | Tags: beijing china olympics
Jun 03, 2008 | 21:34:13
1080p MKV playback on Mac OS X (VLC)
By marcwan

If you’re like me, you used to think that your Intel Mac was a pretty powerful computer. With all of those super zippy cores and RAMs and caches and all that, everything does seem to go a lot faster on the newer machines. My JustLooking compiles went from nearly 4 minutes on my PowerBook G4 to about 35 seconds on my 2.33GHz laptop.

But then came all those 1080p MKV files, with their unbelievable (basically unwatchable) jerkiness, and you found yourself questioning the new religious order. Is the machine, perhaps, actually a piece of junk? Was it that hard disk upgrade you did? The new RAM you installed? Leopard? Some awful combination thereof?

[Read Rest of Article]
Comments (85) Add Comment | Tags: mac osx vlc mkv 1080p playback problems
May 29, 2008 | 04:26:16
Why PHP Sucks (Hint: It doesn't)
By marcwan

There seem to be these periodic flare-ups in the blogosphere and community site circuit where some poor programming language ends up being skewered thoroughly by roving gangs of self-righteous programmers. One or two articles will suddenly receive wide circulation listing arguments why language X is clearly a horrible choice for any “real programmer”, and then examples to prove this will inevitably be given: "false" equals true, (++*p1)++[--x] is actually a valid expression, or Begin and End are used instead of { and }. The couple of articles defending the language that inevitably appear will receive long streams of comments vilifying the author for being an idiot, or even worse, a hack. The sad realty of all the hullabaloo, however, is that all of this is ultimately pointless, and typically based on some silly assumptions.

[Read Rest of Article]
Comments (6) Add Comment | Tags: php sucks language debate
Apr 28, 2008 | 19:06:28
PHP SimpleDB 0.9.1 - A Parallelizing Client Library for Amazon's SimpleDB Service in PHP5
By marcwan

I am please to announce the release of SimpleDB 0.9.1, yet another SimpleDB client for PHP. It was designed with the following in mind:

  • bulk query and attribute fetching operations
  • bulk upload operations (PutAttributes)
  • fast execution of as many queries as possible
  • proper understandable return values
  • proper and clean exception generation
  • providing command line utilities to view and manipulate SimpleDB Domains, Items, and Attributes.
  • the ability to set domain prefixes for site testing / development

This SimpleDB client requires the following:

  • PHP 5.1.4 or greater (hmac_hash() must be defined)
  • The Curl extension compiled in.

Please consult the README for installation instructions.

You must, of course, be a member of the SimpleDB Beta program to actually be able to use this.

[I’ve rolled out 0.9.2 with a bug fix in it. I’ve actually got a newer version on my hard disk with QueryWithAttributes and sorting support, i just have to finish testing it before uploading]

[Read Rest of Article]
Comments (13) Add Comment | Tags: php simpledb aws amazon software
Apr 13, 2008 | 20:54:21
CoreImage memory leak in Leopard and its effect on JustLooking
By marcwan

It was with no small amount of dismay that I recently noticed JustLooking was leaking tonnes of memory on my Leopard machine here at home. When developing the program, I put enormous amounts of time an energy into ensuring the program behaved well and didn’t leak. And yet, browsing through 75 photos from a trip to Hong Kong ground my 2GB system into the dirt in a hurry.

Upon further investigation, this appears to be a bug in Leopard—my Tiger machine has absolutely no leaking at all. The bug occurs specifically when using CoreImage and NSImage interchangeably. In effect, CoreImage works entirely on video card RAM, and NSImage works entirely in system RAM. The resizing method I use causes the system to copy some of that memory from the VRAM to the system RAM, and that code leaks a tonne at a time.

The good news is that you can fix this by just having CoreImage do the rotation. The bad news is that this is 100% incompatible with the fade effect transitions I use. So, right now, I have the choice between transitions or memory leaks. Or just using Tiger (for which there are a number of other great arguments).

One of things I had been looking at for JustLooking 3.2 was reworking exactly how I use CoreImage, filters, and the system’s loading code. It looks as though this work has just taken on added urgency.

[Read Rest of Article]
Comments (1) Add Comment | Tags: leopard mac os-x memory leak coreimage nsimage justlooking
Mar 28, 2008 | 01:38:42
PHP 6 and other fun things that don't exist
By marcwan

It is with some amusement that I have recently seen a number of PHP 6 books popping up for sale at Amazon and Barnes and Noble. A while back, I spent some time trying to figure out just how far behind the curve I was on PHP 6 since I hadn’t really been paying too much attention. As I started to investigate how things were coming along and when I should expect it to hit the street, I was honestly a bit surprised at how hard news was to come by.

In short, like most major software projects, it’s “a work in progress”. As a project developed by volunteers and people with other full time jobs, there are periods where it sees serious spurts of development, and other periods when there are lulls. It will be released basically when it’s done and properly tested by the community. Who knows when that will be, but I will wager money that it won’t occur at in 2008 at all.

So, with that and all those PHP 6 books in mind, I, as an author myself, have come up with the following list of other books I’d to see published or that I’ll consider starting to write:

[Read Rest of Article]
Comments (0) Add Comment | Tags: php php6 books perl6 duke nuke'em
Mar 25, 2008 | 21:15:58
Chipmunkninja.com Update
By marcwan

My trip back from Montréal to Beijing was considerably less triumphant than I had hoped, as I was struck by a severe plague and ended up spending 9 very miserable days in bed with a high fever and nasty cough. One might think that being confined to bed for a week would be a nice thing, but the stunning boredom that sets in after a while is quite unbearable. You’re too tired to really work hard, focus on TV or movies, or even really read a book, but so sick of sleeping that you crave doing something.

And so, I updated the chipmunkninja.com website. I’ve long hated my initial design with forums and my crappy del.icio.us tagging scheme, so I finally fixed those up and now have a proper tagging system, some fun stats on the right side, and paging, so you don’t have to view every single article on one page now.

It’s still a rather ugly shade of red and contains the finest in 2005 style, but that’s a project another day ….

Bugs, comments, or suggestions, feel free to add a comment or drop me a line. Always glad to hear from readers.

[Read Rest of Article]
Comments (1) Add Comment | Tags: chipmunkninja update website
Mar 08, 2008 | 10:20:21
PHP Québec talks
By marcwan

This year, as part of my annual trip to Canada and the USA, I’ve been asked to give two talks at the annual PHP Québec conference in Montréal. I haven’t been back to that city since 1993 when I graduated from University, and it will be interesting to see how it goes. (Although I suspect that while Beijing basks in nearly 20C (nearly 70F) weather every day and even Seattle and New York were closer to 10C (50F), Montréal is still hanging below freezing most days and has over a metre of snow on the ground).

I will be giving talks on internationalisation (commonly just called i18n) and giving your database servers a break with memcached. If you’re anywhere in the neighbourhood, come on by for some good fun. I’ll be getting back to regular programming content this weekend.

[Read Rest of Article]
Comments (3) Add Comment | Tags: php quebec conference talks i18n memcached Montreal Canada
Jan 08, 2008 | 21:36:33
Announcing TunnelerX 0.9.5 - An SSH Tunnel for your Mac OS X menu bar
By marcwan

TunnelerX is an application for Mac OS X to let you run a single SSH tunnel from your system menu bar, typically to securely re-route HTTP (web browsing) traffic to a remote proxy server. If you have ever had to run one of the following commands in a little Terminal window in the corner of your screen, then this application is for you:

ssh -N -L 8123:localhost:8123 bobo@theclown.com
ssh -N -D 8123:localhost bobo@theclown.com

Changes for 0.9.5:

  • The application is now named TunnelerX instead of Tunneler
  • A few bugs have been fixed related to sleeping and waking up the computer
  • New graphics and icons for the application. It’s a bit less ghetto looking now.

For the 1.0 release (upcoming), I will add Growl notifications for those who wish them. The Growl website is currently down, so I can’t do much yet.

Downloading

[Read Rest of Article]
Comments (11) Add Comment | Tags: mac osx SSH tunnel http proxy socks server tunnelerx
Dec 29, 2007 | 21:53:19
Fifteen years in the making - Nethack Ascension Report
By marcwan

This is a bit of a geeky post, but then this is a geeky computer blog, so … so be it. Regular readers of this blog will know that I’m a fan of Nethack, and have been playing it on and off for over fifteen years (mostly off, but recently I’ve rediscovered it again). Well, finally, after all this time, I can say the following:


Goodbye marcw the Demigod...

You went to your reward with 5941448 points,
The Book of the Dead (worth 10000 zorkmids and 25000 points)
Vorpal Blade (worth 4000 zorkmids and 10000 points)
The Heart of Ahriman (worth 2500 zorkmids and 6250 points)
The Bell of Opening (worth 5000 zorkmids and 12500 points)
The Candelabrum of Invocation (worth 5000 zorkmids and 12500 points)
       8 emeralds (worth 20000 zorkmids),
       2 diamonds (worth 8000 zorkmids),
       2 rubies (worth 7000 zorkmids),
       1 amulet of ESP (worth 150 zorkmids),
       1 amulet of unchanging (worth 150 zorkmids),
and 2497 pieces of gold, after 93897 moves.
You were level 22 with a maximum of 95 hit points when you ascended.

 No  Points     Name                                                   Hp [max]
  1    5941448  marcw-Bar-Hum-Mal-Neu ascended to demigod-hood.        95  [95]
  2    2623722  marcw-Val-Hum-Fem-Neu died on the Plane of Fire.
                Dissolved in molten lava (with the Amulet).           129 [287]
  3    1330849  marcw-Val-Hum-Fem-Neu choked on her food in Gehennom
                on level 33.  Choked on a disenchanter corpse.        248 [248]

Interestingly, I almost always play Valkyries, but decided to try Barbarians for a couple of games. The first game, I made it all the way down to level 24 without finding a single altar (except for a non-aligned one in the mines with a nasty priest next to it) before an Arch-Lich and Titan finished me off. The second game was this one. Most of the rest of the time, I do embarrassing things like choke on things or eat something I shouldn’t have. Need to be more careful, I suppose.

Well, that’s all there is to this post, but it’s exciting news for me. I’m still playing, and now trying other classes (read: dying a lot).

[Read Rest of Article]
Comments (0) Add Comment | Tags: nethack ascension report w00t
Nov 20, 2007 | 21:23:17
Announcing Tunneler 0.9 - An SSH Tunnel for your Mac OS X menu bar
By marcwan

Tunneler is an application for Mac OS X to let you run a single SSH tunnel from your system menu bar, typically to securely re-route HTTP (web browsing) traffic to a remote proxy server. If you have ever had to run one of the following commands in a little Terminal window in the corner of your screen, then this application is for you:

ssh -N -L 8123:localhost:8123 bobo@theclown.com
ssh -N -D 8123:localhost bobo@theclown.com

Downloading

[Read Rest of Article]
Comments (0) Add Comment | Tags: mac osx SSH tunnel http proxy socks server tunnelerx
Jul 15, 2007 | 03:34:39
End of an Era
By marcwan

For the last 17 years or so, I’ve been a huge fan of the various BSD-inspired operating systems, starting with SunOS 4.1.x, and then moving on towards the various free flavours available for the PC, such as Bill Jolitz’s 386bsd, then FreeBSD, NetBSD, and OpenBSD. For a while, even I was a regular contributer to the NetBSD community, and enjoyed playing with them all.

When I started installing and running my own servers for mail and web application purposes about 8 years ago, there was an abortive few-month attempt to use Microsoft Windows Server, but since then it’s all been FreeBSD, with the latest lanfear.com server being FreeBSD 4.9-RELEASE (and with an uptime of 2 years, which would have been nearly 3 had my ISP not hacked and rebooted my machine one day).

To this date, various SYSV-inspired features, such as initd and their directory structure leave me with a bad taste in my mouth. I have repeatedly stuck with types of linux such as SuSE (before it sucked), and Ubuntu, that still gave me /etc/rc and familiar directory structures. Mac OS X still gives me warm tingly feelings to this day.

So, it is with some sadness that I recently decided to move from my own dedicated server to a virtual server hosting solution. I’m simply never in the USA any more, and I don’t want to have to worry about my computer going down. A virtual server comes with a guarantee that all hardware problems are the ISPs, and is a bit cheaper to boot. I usually hover around a 0.00 load average, so serious computing power isn’t a necessity for me.

However, the cheapest package with the best bandwidth means my server will, henceforth, be running Ubuntu Server. It is reasonably familiar to me … I can still add things to /etc/rc.local, and the rest of /etc isn’t too alien, and the apt-get scheme seems to work reasonably well. My needs are less these days, as I slowly admit defeat in the email world and let people like Google do it for me, so as long as I can run web apps and a few other fun things, I’m happy. All of my sites and addresses have already been moved to the new server.

The old FreeBSD 1U Dell server will be shut down by the old ISP on Thursday, and put in a box for a friend to go pick up sometime after that. I’ll miss it.

[Read Rest of Article]
Comments (5) Add Comment | Tags: freebsd linux ubuntu server BSD hosting marc-is-old
Jun 29, 2007 | 20:50:34
Things I've learned about CoreImage (and Quartz, and OpenGL) in two weeks
By marcwan

I recently spent two weeks converting JustLooking, my Mac OS X Image Viewing program, from NSImage to CoreImage and friends. This experience was overall much easier than I expected, and I have learned a bunch of things, some of which might have been handy to have known in advance.

The good news is that it mostly lives up to the hype. The bad news is that it’s not without tricks and traps of its own. Here are some notes and comments.

[Read Rest of Article]
Comments (1) Add Comment | Tags: mac osx cocoa coreimage programming quartz opengl nsimage
Jun 07, 2007 | 19:30:33
Website Design Gone Horribly, Horribly Wrong
By marcwan

There are lots of ways in which a website can be annoying. Favourite methods include: rotating and blinking animated GIFs (or worse, Flash), popup advertising windows, unexpected background music files, or just plain all around atrociously ugly page design. (I’ve been quite guilty of this in the past!)

But until you’ve lived in China, or at least spent some time browsing around websites here on the mainland, there’s probably one way to annoy the living bejeezus out of people that you’ve never thought of.

To demonstrate, simply visit any Chinese website, such as the Bank of China or something else such as Chinaren. Don’t worry if you can’t see the characters, they’re not important for this experiment. (Windows XP users can add them by going to Control Panel /International and installing the Asian Font Pack, while Vista and Mac users will have all these fonts installed already).

Once you have one of these pages up in your browser window, click on a link or two. Click on some more links on those pages. Try to get back to where you came from. Within minutes, you’ll have at least a dozen browser windows littering your desktop, or at best, for those Firefox users with the correct settings, dozens of tabs.

You could be forgiven for thinking that this was specific to a few sites with particularly bad design. And you’d be totally wrong. This is completely endemic here in local website design, and is how the locals think that the “Internets” should work. Indeed, there is almost no concept of forward or back button usage any more, and it is not uncommon to see users with well over twenty browser windows littering their desktop at any given time. While Windows users can at least expect the Task Bar to group similar windows, Mac users just end up using the mouse to move the windows out of the way until needed later, or until they just close the browser application completely.

Ultimately, the problem becomes such that, if you want to fix the site design to not do things this way, you will confuse your user. When they click to go to a new page, and they then subsequently finish visiting it, they will close the browser window and proceed to go looking through their other browser windows until they find the one from whence (they hope) they came.

The only thing I can say? At least blatent ripoffs of other sites on the internet don’t seem to have felt compelled to introduce this behaviour into their clones. For everybody else, it’s going to take a while to change this design.

[Read Rest of Article]
Comments (0) Add Comment | Tags: china website design web application annoying
Apr 20, 2007 | 22:58:33
When MySQL Attacks!!!
By marcwan

The Setup

Imagine, if you will, the following scenario:

  • You design a whole new database schema for your cool new scalable web-application. You’re using MySQL and the InnoDB datbase engine for everything, because your schema is so cool it uses all sorts of foreign keys and transactions and the like.
  • You quickly set up MySQL and get your application going with your new schema on your development staging machine.
  • You get MySQL up and running on your live server, play around with it for a bit to make sure it’s working, and then set up a my.cnf file with all sorts of caching and security goodies in it.
  • You do a backup from your dev machine, restore it to the live server, and ta-daa!!! Your web application is up and running on your live server.

What you might not have noticed, especially if you – like me – have a few thousands rows of data, is that MySQL might have screwed you along the way and not really told you all that clearly.

[Read Rest of Article]
Comments (2) Add Comment | Tags: mysql attacks my.cnf innodb myisam CREATE TABLE php web application programming
Apr 10, 2007 | 02:28:51
Setting up, Configuring, and Using Kannel to send/receive SMS messages
By marcwan

I recently had the oppportunity (necessity) to set up a web application that interacted with many of the users through SMS messages in addition to the more traditional HTML interface. While there are a number of possible software solutions for GSM modems on Windows, on Unix-like platforms the most commonly used one is Kannel. It also has the advantage of being open source and thus very, very free.

However, setting, configuring, and using Kannel tends to be a bit tricky. I’m writing this article (almost a HOWTO) in an attempt to help out anybody who’s undertaking the process themselves and might be able to get some tips and tricks from this. I expect this to not be a terribly popular article, but if I ever need to set this stuff up myself in the future, then I’ll have it written down somewhere at least!

Most of the instructions here will work on any Unix platform, such as Linux, FreeBSD, or Mac OS X. It’s worth noting that I got nearly everything working with OS X, only to be thwarted at the very end because Mac’s no longer have serial ports to use GSM modems. You could, however, easily use some of the more advaned HTTP based SMS services on a Mac server of some sort.

[Read Rest of Article]
Comments (95) Add Comment | Tags: kannel sms text messaging setup installation howto linux unix
<< Previous Page   Next Page >>
Copyright © 2005-2008 Marc Wandschneider All Rights Reserved.