Waiting for both network IO and inter-thread notifications

People doing lots of network IO in threaded programs have historicallyhad a problem: waiting for both network IO and for IPC from threads atthe same time.

Generally you want to wait for network IO using select() or poll() ; trying to use lots of threads, each doing one blocking IOoperation, is usually catastrophic to your performance. But both ofthese only wait on file descriptors, and inter-thread communication inlibraries is almost always implemented with mutexes, semaphores,queues, and so on,


抗議世貿官商勾結大遊行

11th Dec,2005
抗議世貿官商勾結大遊行
No WTO : Stop Collusion between Government & Business Rally
(維園狀況)(View in Victoria Park)

01(11mb) https://swtop.no-ip.org/1211rally01.wmv
02(12mb) https://swtop.no-ip.org/1211rally02.wmv

Weekly spam summary on December 10th, 2005

Once again I'll lead with Hotmail's spam numbers, because theycontinue to be bad:

  • one email accepted (probably spam).
  • 218 messages rejected because they came from non-Hotmail emailaddresses.
  • 111 messages sent to our spamtraps.
  • 30 messages refused because their sender addresses had already hitour spamtraps.
  • 5 messages refused due to their origin IP address (all for being inthe SBL).

Now, on to the general numbers.

This week we received 17,2


逐步逐步...

感謝billy把raidoblog重生了
我第一件事就把 "逐步逐步"再放出來
其他的遲些再講吧

逐步 逐步
曲詞:潘志雄 (11/10/2005 )

藍天 密雲 隨風 吹散再聚
頭上 鳥聲和唱著
和遠方呼吸聲 共鳴

漫天 夜靜 前行的未停
凝望天邊星宿
如塵埃散落

How not to set up your DNS (part 6)

Today's illustrative example is about the odd things that can happenif you rename a nameserver without making sure that you tell thepeople delegating zones to you.

There are four nameservers for utoronto.ca : ns1, ns2, bay.cs, andns1.tpc.int (following local practice, I'm dropping the .utoronto.ca bit a lot). Three of those four (everything except ns1) are alsosecondaries for all campus subdomains, including the domain jpint.utoronto


今晚「小玩意」

今天晚上, GBA 會參與 芝華士903友情夾gig音樂會 的演出,是一個紀念黃偉文十周年的演唱會,今次的演出曲目是〈小玩意〉,自己唱 Main Melody 不太難,希望今晚演出順利。


20051209網摘 – 英文豆瓣

New Services


Security versus resilience

A while back I wrote this , about an exceptioncreated by the cgi module when crackerssubmitted XML-RPC calls instead of form POSTs. It makes a great examplefor discussing the difference between 'secure systems' and 'resilientsystems'.

Put broadly, security is keeping people out, while resilience iskeeping operating when people attack you. The cgi module example shows that you can haveone without the other. Sometimes this may even be deliberate;an exceptionally paranoid system could shut itself down anytime it saw unexpected


A surprising hazard of running as root all the time

We have some machines that are 'no user-operable parts inside'setups; as part of that, they have no user logins, just root . (Yes,yes, running as root all the time is bad, but on these boxes almostall we'd ever do with a plain login is su to root.)

I'm attuned to all of the regular hazards of this, but today Istumbled over a new one: how long it takes to notice that /var hadaccidentally wound up


死左了

raidoblog ... 死左了
潘志雄...死左了 (下星期希望可以重生啦)