Skip to main content

Ralsina.Me — Roberto Alsina's website

Posts about sysadmin (old posts, page 7)

This is why Linux is not ready for the desktop

If you delete the emp­ty di­rec­to­ry /var/lib/xk­b, then en­able the KDE key­board lay­out switcher, the up­-ar­row key works like print­-screen.

At least on my box it does. It took me a month to fig­ure it out.

Good News: Linux gives life to old hardware. Bad News: Maybe in some cases it shouldn't.

I was in one of my cus­tomer's dat­a­cen­ters the oth­er day, and while I do most work re­mote­ly, I had to take this op­por­tu­ni­ty to take some snap­shots of their proxy serv­er.

This post is just a bit of fun. This is not sup­posed to be their server, it was just a stop­gap mea­sure be­cause of mul­ti­ple hard­ware fail­ures. This is a large, well man­aged com­pa­ny, and this ir­reg­u­lar sit­u­a­tion will be fixed soon. And any­way, it is work­ing just fine.

As you know, Lin­ux can do that kind of job easy with­out much hard­ware re­quire­ments. Af­ter al­l, it has to han­dle at most about 3Mbps of data, and this box has 2GB of ram, so there's plen­ty of room for a speedy cache.

So, let's go for some good news/bad news.

Good news: It's a true-blue IBM Server! Bad news: It's a IBM Netfin­i­ty 5000 (mod­el 3Ry)!

2110.0.Imagen011

Here is some tech in­fo from IBM about it.

Good news: It has 2 CPUs! Bad news: They are two 450Mhz Pen­tium II CPUs.

Good News: it has hot-swap­pable SC­SI disc­s! Bad news: you have no discs for that con­troller, so we will use this 8GB IDE (PATA) disk!

2108.0.Imagen013

And will leave it just sit­ting there by the CD unit, be­sides the huge gap­ing hole in the front where the SC­SI discs would be.

Bad News: it has a ten­dence to over­heat­ing! Good News: You have a place to keep your coffe war­m!

2109.0.Imagen014

New qmail plugin idea: overload

It should not hap­pen but it does: Your qmail serv­er is over­load­ed. Maybe you are un­der a DOS at­tack, or there is a rea­son why you are get­ting 10x your usu­al amount of mail.

But then you start see­ing how your "not pre­pro­cessed" queue starts grow­ing, and grow­ing...

This can al­so mean things like cla­mav or spa­mas­sas­s­in, which need to check the mail be­fore it gets queued are not keep­ing up with the mail flow, or maybe some IO per­for­ma­ce is­sue.

But what can you do righ now to fix it?

Well, you can dis­able spa­mas­sas­s­in, or, in ex­treme cas­es, shut­down SMTP so the sys­tem has a chance to catch its breath so to speak.

Of course, clos­ing SMTP means your own users can't send email ei­ther, which suck­s.

Now there is a lighter al­ter­na­tive: shut­down SMTP for those who are not your user­s.

Here's the triv­ial code, im­ple­ment­ed as a SPP plug­in, fit to be used in the [mail] sec­tion:

#!/bin/dash

if [ -f /var/qmail/control/overloaded ]
then
      if [ -z "$SMTPAUTHUSER" ]
      then
              echo R451 Temporary Failure: Server overload
              echo overload: $PPID Temporary Failure: Server overload >&2
      fi
fi

And if you are dar­ing and want to make your sys­tem self­-­cor­rect­ing, maybe you should cron some­thing like this:

* * * * * if [ `qmail-qstat  | tail -1 | cut -d: -f2` -gt 100 ];\
then touch /var/qmail/control/overloaded ;\
else rm -f /var/qmail/control/overloaded; fi

I will prob­a­bly code it again in C and make it part of ra/­plu­g­in­s.

Yes, Xandros was horrible. But this ubuntu thing is working out nicely!

As I said be­fore, the bas­tardized Xan­dros [1] sucked. In fac­t, I man­aged to de­stroy it. So I de­cid­ed to switch to an­oth­er dis­tro. Any dis­tro.

En­ter ee­eX­ubun­tu, a eee-­tuned Xubun­tu [2].

Since I pre­fer KDE to XFCE, I start­ed hack­ing at it, and pro­duced, IMVHO, a much nicer thing.

keee.png

As you can see, it takes slight­ly less space than ee­eX­ubun­tu's de­fault, and a whoop­ing 1GB less than the de­fault dis­tro.

How did I do it? First, by de­cid­ing what I want­ed.

  • No Open­Of­fice. Kof­­fice is enough to read doc­s, then there is Google doc­s, and I pro­­duce my texts us­ing do­cu­tils

  • No print­­ing. I have not used a print­­er in 5 years. What are the odds I will use one from the eee?

  • wicd for net­­work con­­fig­u­ra­­tion. It works for wire­­less/wired/en­cryp­t­ed and has no prob­lem what­­so­ev­er re­­con­nec­t­ing af­ter sus­pend.

  • yakuake for ter­mi­­nal. It us­es the least screen-s­­pace pos­si­ble: none if you are not us­ing it.

  • Fire­­fox + Flash (I would use Kon­­queror, if flash9 had not bro­ken it)

  • Kmail + Akre­­ga­­tor for mail and RSS

It works great, boots in 35 sec­onds (and I have not tuned that, yet).

Here's the list of in­stalled pack­ages and here's the list of re­pos I am us­ing

Maybe some­one more en­ter­pris­ing will make a re­al dis­tro out of it.


Contents © 2000-2023 Roberto Alsina