較早前在本blog寫了一篇有關Levi’s 廣告攣與直的網誌,港台的Eric看後,便找了我上了他和梁兆輝主持的節目「自己人」做嘉賓,講一下gay marketing這題目。
噢,想來我真的和港台有緣,今次已經是第二次被不同的DJ邀請,看來DJ們都經
Here's a mistake I've made more than once:
tail -f active-log | grep big-filter | grep -v one-thing
(Here the big-filter is something that selects only a small amountof actual interesting logfile output, and then you want to throw awaya small bit more. For example, my most recent version of this wasmonitoring the exim log on our new mail system for failures and otheranomalies, and then wanting to throw away one particular known failure.)
Looking up reverse DNS to determine the hostname of an IP address thatyou are talking to is one of those almost simple things that softwarekeeps getting wrong .So here is how you do it, in two variants.
First, if you use DNS and have an (almost) empty /etc/hosts or justdon't care about looking up something in it, is the simple version:
gethostbyaddr() the IP address. If it fails, you are done. Otherwiseyou have the claimed hostname . (
Once upon a time, I was at home and really needed to see somethingthat was displayed on my screen at work. This being Unix, there was noconvenient remote desktop add-on that would have let me mirror my workdisplay to home, but this being Unix, there are ways around that.
(Also, I was connecting over a slow dialup PPP connection , so a live remote desktop thing would havebeen difficult anyways.)
My first attempt was simple; ssh in to the work machine and do
I get it every so often: a new system that consumes my attention, mythoughts, and my interest. I find myself thinking about it all the timeand then working on it all the time; it doesn't matter that I'm not atwork, I want to work on it anyways so I do. And I'm impatient to seewhat I've built go into production, to actually get used, to give me feedback .
The current new system enthusiasm is for our new mail
A while back, I thought that a comment spammer had broken my simplescheme to prevent people from fetching the 'addcomments' page once and then using their zombie farm to submit spam, soI decided to switch to a more secure system for this. Since the weaknessin my scheme was spammers being able to replace my hidden informationabout the IP address that originally fetched the 'add comments' pagewith their own, the obvious fix was to sign the IP address using HMAC .
(It turned out that the