
Category: Uncategorized
disconnected

These days I am trying to disconnect (from a lot of things, not just from the Net).
(→)
You’re welcome
Today is the 11th Annual System Administrator Appreciation Day. Make some time and go thank your system administrator. It will buy you 364 days of less BOFHiness and non-grumpy support. It will actually show to your system administrator that his unpaid overtime and weekends in the terminal room, are really worth the effort.
Not only is System Administration a thankless job, it is also considered an unneeded burden, a low profile and accordingly paid service. There are even people under the illusion that cloud computing will make system administration obsolete. For them I paraphrase what Bob Lucky wrote in May 1998: System Administration will be in danger of shrinking into a neutron star of infinite weight and importance, but invisible to the known universe. Do you really want to make a handful of us that important for you?
Who do you think is going to administer the Cloud? A system adminisrator. And, again to paraphrase Bob Lucky from the same article, that System Administrator will be extremely well paid, and his or her every demand will be immediately satisfied. That engineer will be the last keeper of the secret of the (cloud) universe: The Root Password.
To those who really do not see it, the Cloud does not make System Administration obsolete. It only changes the way it is practiced. There are Systems built on and into the Cloud that need administration. What the developers of those systems do not see, is themselves becoming the system administrators of the systems (with increasing complexity and dependencies that) they build.
Go and thank your system administrator today. Really do. He does provide you with at least an above the average service. For if he does not, you cannot even begin to do your job, no matter how important (or urgent) you think it is.
You’re welcome.
Cybersyn
Πρωτοδιάβασα για το Cybersyn σε αυτό το blog post του Mike Trick. Πρόκειται για ένα τηλεπικοινωνιακό δίκτυο που έστησε στη Χιλή η Κυβέρνηση του Αλιέντε με μηχανές telex (που βρήκε σε αχρηστία από την προηγούμενη Κυβέρνηση). Project manager του έργου ήταν ο Stafford Beer (ένας πρωτοπόρος της Επιχειρησιακής Έρευνας που πίστευε στο συνδιασμό Cybernetics και managemet). Το έργο έτρεξε από το 1970 έως και το πραξικόπημα του 1973.
Όπως φαίνεται και από το άρθρο του Guardian η μεγαλύτερη επιτυχία του έργου ήρθε στην απεργία του 1972 με 50000 φορτηγατζήδες να κλείνουν δρόμους:
Food and fuel supplies threatened to run out. Then the government realised that Cybersyn offered a way of outflanking the strikers. The telexes could be used to obtain intelligence about where scarcities were worst, and where people were still working who could alleviate them. The control rooms in Santiago were staffed day and night. People slept in them – even government ministers. “The rooms came alive in the most extraordinary way,” says Espejo. “We felt that we were in the centre of the universe.” The strike failed to bring down Allende.
Θυμίζει κάτι αυτό; Το Cybersyn και 200 φορτηγά πάντως τα έβγαλαν πέρα. Στη δικιά μας περίπτωση τα φορτηγά και τα βυτία επιτάσσονται, αλλά ακούω πως δεν είναι εύκολο να ελεγχθεί εάν θα τηρηθεί η επίταξη καθώς δεν υπάρχει ο κατάλληλος μηχανισμός (δεν ξέρω, μπορεί να είναι και λανθασμένη η εντύπωση αυτή).
Μέχρι να εκδοθεί από το MIT Press το “Cybernetic Socialism“, το οποίο και θα περιγράφει την ιστορία του Cybersyn, ίσως θα είναι χρήσιμο να μεταφραστούν από κάποιον τα τμήματα της τεκμηρίωσής του που είναι στα Ισπανικά.
Μπορεί να μάθουμε και κάτι.
Update: Ένα λεπτομερές blog post για το Cybersyn.
GPS info
Χρειάστηκε σήμερα να πάω σε ένα νοσοκομείο που δεν ήξερα που είναι. Είχε ιστοσελίδα και βρήκα τη διεύθυνση. Περιέργως, το nuvi ενώ είχε το δρόμο, δεν είχε τους πρώτους 100 αριθμούς της οδού.
Δε θα ήταν καλή ιδέα εάν νοσοκομεία και λοιπά δημόσια κτίρια (δημαρχεία π.χ.) εκτός από την οδό, είχαν και το GPS location στη σελίδα επικοινωνίας; Οι χάρτες που έχει κάποιος στο GPS παλιώνουν, οι οδοί αλλάζουν ονόματα, κατεύθυνση και αρίθμηση, τα web site δεν ενημερώνονται, αλλά το στίγμα μένει σταθερό.
BeBook Mini: Μετά το πρώτο βιβλίο
Πριν κάτι μήνες αποφάσισα να πάρω ένα eBook reader. Βασισμένος σε ένα άρθρο του Peter Viscarola στο NT Insider και σε αυτό το post του Κώστα, ήμουν ανάμεσα σε κάποιο BeBook ή κάποιο Cybook. Επιπλέον, για eBook reader και λοιπά accessories, δεν ήθελα να ξοδέψω περισσότερα από €300. Κατέληξα στο BeBook Mini (με οθόνη 5″). Reader + 1 κάρτα SD 2G ~ €260. Ακολουθούν σκέψεις για το reader μετά την ολοκλήρωση της ανάγνωσης του πρώτου βιβλίου σε αυτό.
- Μπορείτε να παραβλέψετε το ελληνικό manual.
- Το BeBook έρχεται φορτωμένο με μερικά βιβλία (30 στα Ελληνικά) από το Project Gutenberg και με 8 βιβλία από τον Καστανιώτη.
- ePaper rocks! Έχω μείνει απόλυτα ενθουσιασμένος από την απεικόνιση.
- Είναι ανθεκτικό στις πτώσεις. Μια κυρία στο λεωφορείο το χύπησε κατά λάθος, προσγειώθηκε με την οθόνη και δεν έπαθε τίποτε.
- Δεν είναι για όλα τα PDF ή τουλάχιστον για τα περισσότερα που με ενδιαφέρουν (και που έχουν δίστηλα, σύμβολα και σχήματα). Από την άλλη, εάν το eBook είναι φτιαγμένο για αυτές τις συσκευές, είναι εξαιρετικά ευανάγνωστο και δε χρειάζεται να καταφύγει κανείς σε zoom ή rotation για να μπορέσει να το διαβάσει.
- Εάν επιθυμεί κανείς ένα general purpose PDF reeader, να αγοράσει ένα iPad. Καταλήγω στο συμπέρασμα πως οι ιδανικές διαστάσεις για μια τέτοια συσκευή είναι κοντά σε αυτές του A4 ή του US Letter. Οτιδηποτε άλλο σημαίνει πως ο χρήστης κάνει υποχωρήσεις.
- Το BeBook Mini, συνεργάζεται άψογα με το Adobe Digital Editions. Είναι επίσης ορατό σαν εξωτερικός σκληρός δίσκος.
- Σου δίνει την επιλογή να ανοίγεις PDF είτε με το Acrobat Reader, είτε με το XPDF, αλλά μερικές φορές το να κάνεις switch από το ένα στο άλλο δεν είναι προφανές.
- Αναρωτιέμαι, μια και όλοι όσοι κατασκευάζουν eBook readers τα δίνουν μαζί με κάποια βιβλία από το Gutenberg, εάν κάνουν και δωρεές σε αυτό.
- Το μηχάνημα έχει και MP3 player και δυνατότητα για text-to-speech. Δεν τα έχω δοκιμάσει.
- Με τη μπαταρία να αντέχει 7000 “γυρίσματα” σελίδων, δεν είναι ανάγκη να κουβαλάει κανείς φορτιστή στις διακοπές.
- Διάλογος συναδέλφων στη δουλειά: “Ωραίο είναι. Τρέχει Debian;”, “Όχι ρε, τρέχει Acrobat Reader”. Για να είμαστε δίκαιοι τρέχει Linux 2.6.21.7.
- Είναι εξαιρετικά εύκολο στο χειρισμό του.
Μέχρι να βγει κάποιο tablet που να τρέχει Android και να παρέχει κάποιο συνδρομητικό service στα Google Books (συμπεριλαμβανομένων και αυτών που είναι “κλειστά”, wishful thinking) είναι μια χαρά επιλογή για διάβασμα στο λεωφορείο.
Update #1: Μια χαρά τα λέει ο Steve Bellovin.
Update #2: Introducing Google eBooks: more than 3 million titles from your choice of booksellers & devices http://goo.gl/iEdK1
/* Now reading: Conquest in Cyberspace */
loop
for (i = 0; i < strlen(string); i++) {
:
}
This is a C version of a loop that I recently bumped into while copy-pasting some code. In the above loop strlen(string) is called strlen(string) times instead of just once (unless the length of string changes while in the loop):
int len;
:
len = strlen(string);
for (i = 0; i < len; i++) {
:
}
Unless the compiler detects this and optimizes the loop, this is very bad practice. Yes, most of the compilers do detect this, but this does not mean that the programmer must rely on the compiler's optimizations. What if it does not get optimized in the end?
This is not a rant about wasted CPU cycles. It is mostly a rant about laziness in our thinking.
Greenspun’s Tenth Rule and variations
For those who have not heard Greenspun’s Tenth Rule, it states that:
Any sufficiently complicated C or Fortran program contains an ad hoc, informally-specified, bug-ridden, slow implementation of half of Common Lisp.
By the way, Greenspun‘s rules 1 to 9 do not exist.
Seven months ago, during a discussion about Prolog, I asked Ozan S. Yigit to reformulate Greenspun’s tenth rule for Prolog. Oz replied:
Any sufficiently complicated modern program contains a buggy, informal implementation of prolog that casual observers confuse with lisp.
Just hours earlier I was basically a listener in a discussion that involved NoSQL. While clearly I am not a NoSQL advocate, I am no hater either, but what I heard lead me to the following reformulation of Greenspun’s rule, this time involving the relational model:
Those who blindly adopt #NoSQL will discover a variation of Greenspun’s tenth rule
I am sure that many other variations exist. In fact the Wikipedia page on Greenspun’s Tenth Rule contains a Prolog variation similar to Ozan’s and an Erlang version. So if you know of (or can make up) any other, please post it here (or somewhere).
An alternative to FEATURE(mailertable)
Using FEATURE(mailertable) one can instruct sendmail to route email for certain destination via a specific relay. A mailertable is essentially a static map that instructs sendmail where to route email for certain destinations ignoring DNS MX RRs (or other information). Example:
yahoo.com smtp:[server.example.com] yahoo.com.hk smtp:[server.example.com] yahoo.com.mx smtp:[server.example.com] yahoo.com.br smtp:[server.example.com] yahoo.com.cn smtp:[server.example.com] yahoo.com.sg smtp:[server.example.com]
Why would one want to do that? Your customers may have been hit by a botnet and as a result your outgoing mail server may have sent enormous amount of spam. Since most high-profile mail hubs use some kind of reputation scheme on the IP addresses that contact them, it is quite probable that your outgoing mail server is experiencing delays, or worse denied delivery despite the fact that in the meantime you have done your best to stop the botnet and clear your queues. I know for it has happened to me.
A mailertable is a quick solution to route email through another mail server just for recipient domains that implement such policies. But it is far from perfect for the Postmaster has no way to know all the domains that Yahoo! Mail in the above example hosts in order to construct a mailer table. Luckily, when high-profile mail hubs (like Gmail, Yahoo! Mail and Hotmail) implement good patterns on their DNS MX RRs, a programmatic (instead of a static) solution can be deployed:
LOCAL_CONFIG Kbestmx bestmx -T.TMP LOCAL_RULE_0 R$+ < @ $+ > $* $: $(bestmx $2 $: NOTFOUND $) $| $1 < @ $2 > $3 R$+.hotmail.com. $| $+ < @ $+ > $* $#esmtp $@ [server.example.com] $: $2 < @ $3 > $4 R$+ $| $+ < @ $+ > $* $: $2 < @ $3 > $4
In the above snippet, any email that is directed to a domain that is served by Hotmail’s servers is routed via server.example.com. For the record, our outgoing webmail server achieved a senderscore of 50, and although a filter stopped the plaque, Hotmail silently discarded email originating from it. Using the above solution restored communications for our users.
Using bestmx for discarding outgoing email
The following ruleset discards email that originates from domains for which we are not best MX. It is meant to be applied on outgoing email servers:
LOCAL_CONFIG Kbestmx bestmx -T.TMP LOCAL_RULESETS SLocal_check_mail R$* $: $>canonify $1 # You may (or may not) want to comment the following line R < @ > $#OK R$* < @ $+. > $* $1 < @ $2 > $3 R$* < @ $+ > $* $: $2 # Short circuit certain domains (and host names) Rexample.com $#OK R$* . example.com $#OK R$* $: $(bestmx $1 $: NO $) # If a temporary error occurs, do not block R$*.TMP $#OK Rserver.example.com. $#OK R$* $#discard $: $1
This works for as long as spammers do not use domains for which they do not control the DNS zones. If they do control the DNS zones they can easily add your relays as MX to them. In such cases the above ruleset must be modified to lookup the name servers for domains that server.example.com is best MX and then decide to discard. However the above trick erased thousands of outgoing spams yesterday.
PS: Like I posted on twitter: I rewrote the above filter in ~35 lines of Perl (subroutine filter_sender for MIMEDefang’s mimedefang-filter). The sendmail version is both more compact and readable (at least to me).