The
Ultimate
Business Machine

Technology, business
and innovation.

And, not least, about
the Mac.

Weblog • Archive • Cutedge

by: Bernard Teo








Creative Commons License

Copyright © 2003-2012
Bernard Teo
Some Rights Reserved.

Sun 16 Aug 2009

The brick in the wall

Category : Commentary/BrickInTheWall.txt

Now that wasn't hard, right. That first post after a long long time.

It's like what I read in Zen and the Art of Motorcycle Maintenance, when Robert Pirsig was speaking as the protagonist, Phaedrus, who was teaching a student how to overcome a writer's block.

So he says, instead of writing about the whole street, you concentrate on just one house, say the church, and you think aboout the church and then its wall, and you pick a single brick in that whole wall to think about, and you start writing about that brick. And you notice the words will come, just now maybe a trickle, but now it's pouring forth, and you go with the flow, and that's how you get past that block.

Do it one step at a time.

It all started when I thought it would be nice to be able to update this weblog directly from my iPhone. That brought me from one thing to another - building our SQL frameworks so they'll be able to work on the iPhone, diversions into WebKit, building our Maven (which is a Cocoa MySQL-type tool) as a SQL front-end for the iPhone, etc. Then I got lost. And exhausted. And all the while Snow Leopard was looming. And then it all stopped. Log-jammed. Nothing was moving.

But it was a pretty nice place to be in - inactivity, serenity, bliss. While it lasted.

But I've got going again. Had been for quite a while. But it took this move to a new server to run Snow Leopard to get me writing again.

I still hadn't be able to update the weblog from the iPhone. But I'll come back to work on it after I've got everything - MailServe, DNS Enabler, WebMon, Luca and Maven - working properly on Snow Leopard.

P.S. : Wonder who's still reading all this.

Posted at 3:30PM UTC | permalink

Tue 31 Aug 2004

Ways of Seeing

Category : Commentary/waysOfSeeing.txt

I was thinking, after I made that last post, that maybe we can try to understand how two people can look at the same iMac G5 in two different ways.

Readers of this weblog may know that I have made references to Robert Pirsig's book "Zen and the Art of Motorcycle Maintenance" - and his ideas about the classical-romantic dichotomy - many times.

What Paul Thurrott is doing, when he says that the iMac is derivative and boring, is that he is looking at things from the classical point of view, i.e., in terms of form and function.

So, if you think only in terms of form and function, you will consider that, hey, the PC manufacturers have built PCs with largely similar physical configurations before, and so, where's the excitement?

The classical mind, which can find beauty in abstract symbols and meanings, will also find Windows XP Service Packs exciting. You would, too, if you think about it means - that this is Microsoft at their best, showing resilience and cunning in extricating themselves from close shaves and near disasters, with convoluted patches and counter-patches.

The romantically-inclined person, on the other hand, just wants to run his hands over the smooth, (presumably) white surface of the new iMac and admire the glint from the metallic surfaces. It is shape, fit, colour, and texture that excite us. And how it all feels ... just right.

For example, when I'm writing these words, I'm concentrating on the message. I'm wondering if I, myself, understand what I'm saying. I'm conscious of myself dredging out half-formed ideas, and organising them into a stream that, hopefully, makes sense to another person. But I'm not conscious of the fact that I'm pecking at the keyboard. If I were, I would lose my train of thought.

That's why Mac users understand the joke about the disappearing computer - "where did the computer go?". In our mind, the computer was long gone, and that was what made the Mac great as a thinking tool. What Apple did with the iMac G5 was to make the physical computer gone, too, at least visually, and we enjoy how advances in technology have now made these two images resonate in sync, as they ought to.

So, Paul Thurrott can't see what's so exciting about the new iMac. But Mac users see excitement in precisely the absence of things to see.

The computer ought to disappear, leaving only the screen, because that's the only thing left that ought to be there. The best tool is the tool you're not conscious of using. In that sense, less will always better.

Thirty spokes meet at a nave;
Because of the hole we may use the wheel.
Clay is moulded into a vessel;
Because of the hollow we may use the cup.
Walls are built around a hearth;
Because of the doors we may use the house.
Thus tools come from what exists,
But use from what does not.

From Peter Merel's interpretation of the Tao Te Ching

Posted at 4:58PM UTC | permalink

Wed 12 May 2004

A Weblog as a form of Chautauqua

Category : Commentary/chautauqua.txt

I'm finding that there is a close parallel between the mode of discourse made possible by a weblog, and the mechanism used by Robert Pirsig to link together the events and ideas he described in Zen and the Art of Motorcycle Maintenance.

If you don't mind, look at the discussion on this page that I've found :

"I would like to use the time to talk in some depth about things that seem important. What is in mind is a sort of Chautauqua Ñ that's the only name that I can think of for it Ñ like the traveling tent-show Chautauquas that used to move across America, [...] an old-time series of popular talks intended to edify and entertain, improve the mind and bring culture and enlightenment to the ears and thoughts of the hearer. ( Pirsig, p.17)

From the discussion that I linked to earlier : "The narrator sticks to this expression as well as to the lecture-form, the most defining element of the original Chautauquas, throughout the novel. He uses the term Chautauqua whenever he wants to present notions of a more theoretical kind: motorcycle maintenance, philosophy, technology, 20th century life, etc. These Chautauquas gain importance for the narrator on a very personal level, because the lectures become more specifically linked to the narrator's life. Still, he never abandons pointing out general implications, trying to come to conclusions at the end of the Chautauquas (although sometimes the end of one and the beginning of another are blurred). A wide range of topics is discussed, which seemingly also inspired the narrator to come up with the term chautauqua."

Note : "a wide range of topics is discussed ... these Chautauquas gain importance for the narrator on a very personal level, because the lectures become more specifically linked to the narrator's life ... never abandons pointing out general implications, trying to come to conclusions at the end of the Chautauquas (although sometimes the end of one and the beginning of another are blurred)."

That's what a weblog is like, isn't it. You can use it to lay out an idea that is very difficult to get across at one go. Especially when you're still trying to untangle the strands of your own thoughts. The weblog gives you the time to ruminate about a position that you've taken, find other situations from which you can draw implications that will either strengthen or weaken your convictions, and ultimately move you closer to better knowledge or a greater truth. If that ever happens, it doesn't matter if nobody else reads it because you've rendered a service to yourself.

Posted at 11:48AM UTC | permalink

Tue 13 Jan 2004

Awk!

Category : Technology/awk.txt

On the OS X terminal, if you do a

tail -6 -r /var/log/mail.log

you will get,

Jan 13 17:01:45 localhost postfix/smtpd[28990]: disconnect from Jan 13 17:01:45 localhost postfix/smtpd[28990]: disconnect from localhost[127.0.0.1]

Jan 13 17:00:45 localhost postfix/smtp[28994]: E269A1370E9: to=, relay=mail3.nus.edu.sg[137.132.14.18], delay=1, status=sent (250 137.132.14.18: Message accepted for delivery)

Jan 13 17:00:45 localhost postfix/qmgr[28598]: E269A1370E9: from=, size=1330, nrcpt=1 (queue active)

Jan 13 17:00:45 localhost postfix/cleanup[28992]: E269A1370E9: message-id=

Jan 13 17:00:44 localhost postfix/smtpd[28990]: E269A1370E9: client=localhost[127.0.0.1]

Jan 13 17:00:44 localhost postfix/smtpd[28990]: connect from localhost[127.0.0.1]

which shows the last few entries in the tail-end of the mail log, in reverse order.

But, what if you want to slot these lines into a table, so that it will look more comprehensible? Like below :

The problem is to figure out how to break the words into columns, knowing that you cannot predict the width of each column (another person's host name may not be localhost - it is RoadsteadServer on my "real" server), or even how many words each line would have.

The key to solving this is a Unix command that goes by the rather unlovely name of "awk" (for A. V. Aho, P. J. Weinberger, and B. W. Kernighan, the original authors).

The solution (at least that's my solution; I'm sure it could be done better) looks like this :

tail -20 -r /var/log/mail.log | awk '{gsub(/\[.....\]/,""); printf "%s*%s*%s*%s*%s*%s\n", $1,$2,$3,$4,substr($5,1,length($5)-1),substr($0, index($0, $6), 255)}'

It looks quite ugly.

But that is seeing life from what Robert Pirsig would call a romantic point of view.

In actual fact, it works beautifully. For a person pre-disposed to looking at life from the classical point of view, everything here can be explained. The solution is beautiful because of its power and its economy. There is no waste. And it does produce the right output for piping into the table you see above. It works everytime, all the time.

Quoting "Zen and the Art of Motorcycle Maintenance" :

"The classic mode proceeds by reason and by laws. Although surface ugliness is often found in the classic mode of understanding it is not inherent in it. There is a classic esthetic which romantics often miss because of its subtlety. The classic style is straightforward, unadorned, unemotional, economical and carefully proportioned. Its purpose is not to inspire emotionally, but to bring order out of chaos and make the unknown known. It is not an esthetically free and natural style. It is esthetically restrained. Everything is under control. Its value is measured in terms of the skill with which this control is maintained.

"To a romantic this classic mode often appears dull, awkward and ugly, like mechanical maintenance itself. Everything is in terms of pieces and parts and components and relationships. Nothing is figured out until it's run through the computer a dozen times. Everything's got to be measured and proved. Oppressive. Heavy. Endlessly grey. The death force.

"Within the classic mode, however, the romantic has some appearances of his own. Frivolous, irrational, erratic, untrustworthy, interested primarily in pleasure-seeking. Shallow. Of no substance. Often a parasite who cannot or will not carry his own weight. A real drag on society. By now these battle lines should sound a little familiar."

The point I am getting at is that this is also the battle line in the perennial Mac vs PC debates. "Frivolous, irrational, erratic, untrustworthy, interested primarily in pleasure-seeking" - that's the IT manager's view of the Mac user. It's so difficult to explain the reason for the conflict because the underlying issues are so subtle.

But the reson why some of us love using the Mac is that we don't come to work thinking, "What do we want to be today (like, where do you want to go today)? Let's see, do we want to be an artist or a scientist, today? What about tomorrow?" We work out of both sides of our brain, and we want to move effortlessly from one mode to the next, depending on what the solution should take. Is it any wonder why we insist that our computational machines ought to work the same way? Cultists and zealots, indeed.

Posted at 1:44PM UTC | permalink

Fri 02 Jan 2004

Talked Too Soon

Category : Commentary/talkedtoosoon.txt

I found a bug that prevented SMTP-AUTH from working properly on the server. It took all of four hours to trace it to an extra character in a config file. How did it get there? Fortunately, I had a working installation I could compare against, after I've exhausted all the tests by logic. It was so hard to find. (But it's now fixed in Postfix Enabler 1.0.6.)

Reminds me of the place in "Zen and the Art of Motorcycle Maintenance" where Robert Pirsig wrote :

"The real purpose of scientific method is to make sure Nature hasn't misled you into thinking you know something you don't actually know. There's not a mechanic or scientist or technician alive who hasn't suffered from that one so much that he's not instinctively on guard. That's the main reason why so much scientific and mechanical information sounds so dull and so cautious. If you get careless or go romanticizing scientific information, giving it a flourish here and there, Nature will soon make a complete fool out of you. It does it often enough anyway even when you don't give it opportunities. One must be extremely careful and rigidly logical when dealing with Nature: one logical slip and an entire scientific edifice comes tumbling down. One false deduction about the machine and you can get hung up indefinitely."

(I found a link where you can read most of the book on-line. I love this book. I think I've had at least two of them that I've given away for others to read. I'll have to buy another because I think I'll want to read it again.)

So, it's New Year's day and I'm fixing a stupid bug. My wife thinks it's not worth it. I felt sorry for the kid, who was waiting to go to the park. Fortunately I had enough daylight left to make good on the promise.

Posted at 5:34AM UTC | permalink

Sat 10 May 2003

A pianist doesn't spend time peeking inside the piano

Category : Commentary/nevillebrody.txt

I like this quote from Neville Brody at the Apple site, "I liken working on the Mac to jazz. To play jazz properly, you have to become highly skilled at an instrument. Working with a Mac, you have to learn the technology just as you would learn to play an instrument or learn to paint with a brush. Then you have to forget it and then simply start creating and building. A pianist doesn't spend time peeking inside the piano."

I happen to read his bio at the Apple site.

Just yesterday, I was looking through some old issues of "The Face", and the designer of a lot of the typefaces "The Face" used then was this guy called Neville Brody.

And only a few days ago, I had been writing about how, if you're really serious about using computers well, you wouldn't bother wasting time opening and closing the PC box, pulling out cards and such.

So I'm in the midst of some cross currents.

I remember Arthur Koestler describing, in "The Act of Creation", how the act of creation comes about when you have "an intersection of lines of thought which brings together hitherto unconnected ideas and fuses them into a creative synthesis".

That's an interesting book to read in conjunction with Robert Pirsig ("Zen and the Art of Motorcycle Maintenance") who wrote about how, when a craftsman is focused on the act of creation, he is at one with his creation. Like the archer fused to his target, the bow ceased to exist.

Posted at 1:45PM UTC | permalink

Thu 27 Feb 2003

Zen and the Art of Weblog Maintenance

Category : Commentary/zen.txt

I don't know who reads this weblog. But I'm doing this as much for myself, as for others.

I think more people should try writing weblogs. It shouldn't be self-indulgent but should at least contain things that are worth people's time reading. You'll need discipline to keep to a subject matter. But that will enforce clarity in thinking. If, by writing a weblog one learns to think clearly, that will be its own reward.

Now, it's so hard to chase those ideas before they disappear, the last thing I want is to let technology get in my face. Once I'm done, a quick

rsync -tvr -e ssh /path/to/weblog/docs user@domain:/path/to/weblog

(triggered from BBEdit's menu) is all I need to get this on the weblog.

Looks ugly, but it keeps the weblog on the "real" server synchronised with the copy I have when I'm not on-line.

Reminds me of Zen and the Art of Motorcycle Maintenance. You can find beauty in technology.

Posted at 5:02AM UTC | permalink

Mac@Work
Put your Mac to Work

• Sivasothi.com? Now how would you do something like that?

• Weblogs. Download and start a weblog of your own.

• A Mac Business Toolbox
A survey of the possibilities

• A Business Scenario
How we could use Macs in businesses

• VPN Enabler for Mavericks

• MailServe for Mavericks

• DNS Enabler for Mavericks

• DNS Agent for Mavericks

• WebMon for Mavericks

• Luca for Mavericks

• Liya for Mountain Lion & Mavericks

• Postfix Enabler for Tiger and Panther

• Sendmail Enabler for Jaguar

Services running on this server, a Mac Mini running Mac OS X 10.9.2 Mavericks:

  • Apache 2 Web Server
  • Postfix Mail Server
  • Dovecot IMAP Server
  • Fetchmail
  • SpamBayes Spam Filter
  • Procmail
  • BIND DNS Server
  • DNS Agent
  • WebDAV Server
  • VPN Server
  • PHP-based weblog
  • MySQL database
  • PostgreSQL database

all set up using MailServe, WebMon, DNS Enabler, DNS Agent, VPN Enabler, Liya and our SQL installers, all on Mavericks.