Introduction About Site Map

XML
RSS 2 Feed RSS 2 Feed
Navigation

Main Page | Blog Index

Archive for January, 2012

When KDE Eats up the Swap

Hieroglyph at Dendara

ON my most powerful desktop I only have 2 gigabytes of RAM. Usually it’s fine for everything to be run simultaneously, but under certain circumstances it’s possible for the swap file to kick in and typically start to be accommodated with active processes, notably KDE applications that exist in view all the time. So I got some scripts together to clean up the swap file and move those processes back to RAM, which makes them quicker (no need for disk I/O).

I have identified processes that typically enter the swap file first and can be restarted uncleanly without loss of data. So I got a script called clean-kde.sh , in which I put:

killall plasma-desktop krunner kmix
kxkb klauncher klipper && plasma-desktop &&
krunner && kmix && klipper && kxkb
&& ~/getswap-sorted.sh

That last one helps show me what other applications have data that still sits in the swap file.

getswap-sorted.sh just has

./getswap.sh | sort -n -k 5

This, in turn, is just a script I found elsewhere. getswap.sh goes as follows

#!/bin/bash
# Get current swap usage for all running processes
# Erik Ljungstrom 27/05/2011
SUM=0
OVERALL=0
for DIR in `find /proc/ -maxdepth 1 -type d | egrep "^/proc/[0-9]"` ; do
PID=`echo $DIR | cut -d / -f 3`
PROGNAME=`ps -p $PID -o comm --no-headers`
for SWAP in `grep Swap $DIR/smaps 2>/dev/null| awk '{ print $2 }'`
do
let SUM=$SUM+$SWAP
done
echo "PID=$PID - Swap used: $SUM - ($PROGNAME )"
let OVERALL=$OVERALL+$SUM
SUM=0

done
echo "Overall swap used: $OVERALL"

That’s about it. The list of swap hoarders helps guide manual restarting of applications that got stuck in the swap file. It’s often worth doing this, even it it takes a couple of minutes. The desktop can stay snappy for months (without a restart of KDE or Linux).

Visual Identity

Background design

Visual identity is associated with one’s mental abstraction of a concept, a person, a place, and so on. Universities use that a lot to get across their reputation, be it with a logo, a name, or some imagery of a famous site or scientist (maybe a poet). But visual identity can also aid orientation — for we all judge something that we see based on prior sights of the same (or similar) thing. This blog has had pretty much the same theme which I tailored back in 2004. Techrights has had pretty much the same design since its inception in 2006. This has little to do with convenience and more to do with how people remember those sites. Too frequent an alternation of a site’s theme (as most sites tend to do) lead to a certain disconnect and a plurality which does not help. Some things need not vary too often.

Corporate Accountability

Factory

IN THIS weird age when corporations are assumed to have the rights of individuals (e.g. privacy) while evading the liabilities and burdens of individuals (e.g. tax, which they can evade using loopholes) it makes one wonder what became of so-called democracy and capitalism. This was not the vision people had after they had laid the foundations for what they considered to be a humane system. Nowadays, our society is based upon ever-increasing debt and a debt that our descendants are expected to pay back. It’s a society where corporations (and their owners) gain vast amounts of money at the expense of real people and when things go awry, corporations will get bailed out and in some cases left alone when they hurt people (e.g. BP in the gulf). There is a massive looting — “piracy” one might say — going on all the time. All the power and welth gets passed to corporations, which now control the political systems too.

If we wish to cautiously proceed with the idea that corporations are like people, then we must subject them to the same standards and restrictions we apply to individuals. Otherwise, civilisation as we know it will sooner or later collapse.

Running and Bodybuilding Don’t Mix

Running track

Running is not easy for someone my weight, but there are ways to be both strong and lightweight. When I was a teenager I used to practice at the athletic tracks and ensure that I could combine the best of both worlds — to to speak — by keeping both the upper body and lower body in good shape. The whole situation is tricky for many reasons because with an upper body too strong there is a lot more left for the legs to carry and with excessive leg exercise the upper body cannot tap into the building blocks of the body so well, not to mention the effects of exhaustion from endurance/cardio-vascular exercise (it prevents one from reaching peak performance in weight-lifting). I never managed to find good balance between those two things and there is probably no such thing as “balance” there because by improving in one area, one gets worse at the other, not just by neglect.

What I generally found was, people who claim to be good at sports are usually good at just one division or type of sport. It is not possible to be very good at everything, not all at once anyway.

Reviving This Blog

LIFE after 30 and a life after a doctorate degree is a tad mysterious. No longer is there the feeling of growing more mature and getting in better shape. No longer is there an aspiration to advance intellectually or academically (full professorship can be take many years to earn compared to a doctorate), so what it all comes down to is what good men (and women) sometimes refer to as “settling down”, reassuring themselves that whatever has been achieved can be looked backed at with foresight involving future generations.

Last week I decided to blog a little more about philosophy and a plethora of topics other than my job and my hobby (notably Techrights). The reason is, a lot can be said which was already implied before (e.g. the need to abolish software patents), but unless one diversifies the areas of one’s focus, it will get repetitive and dull. In the coming month I shall try to revive this blog, which used to attract a lot more readers back in 2005-2007 when I wrote in it on a daily basis. In a way, this is a sort of new year’s resolution.

What’s the Point of LinkedIn?

Old chain

LIKE most people on that site, I joined LinkedIn several years ago after a friend had invited me. For many years I did nothing with the account, but in more recent years the site grew rapidly in terms of popularity and is now a status symbol by some people’s imagination. It’s a bit like Facebook for professionals. But what really is that point of it all? It’s all rather superficial and the process of connecting to peers and friends (or ex-colleagues) is very time-consuming. When one considers what can be gained from having one’s name in a database associated with many other names, then the reality of the matter becomes clearer. Have we come to a point in the lifecycle of the Internet where we score people’s popularity based on the hours they dedicate to clicking to modify some proprietary database of some private company? Frankly, I stopped spending time in LinkedIn and my profile there is very much outdated (last updated properly in 2006). Can there finally be consensus on the irrelevance of public profiles that are merely the entry in someone else’s Web site? It’s just a MySpace for adults and the function is tracking other people’s careers is often overstated as crucial. It’s more like gossip or stalking.

Digital Work in the Broadband Age

Forgotten shed

AS SOMEONE who has worked from home since 2006 I can gladly say that motor vehicles are possible to avoid for those who wish to and whose work is location-independent. Spare office space too can be discarded. Both removals would be beneficial to the environment and reduce the impact of overpopulation.

I used to drive around a lot as a teenager, but when jobs become more sedentary and possible to carry out over broadband, what really is the point of driving to another office — an office like one that can be set up at home? This question is troubling sometimes, especially because of answers that are commonly given

To some people, the idea of going to work is the idea of escaping the confinements of a home, “going out” so to speak. To others it is about separation/buffer between home and work — the illusion of having two places to lodge in. Where interaction with colleagues is not necessary (or bossing over one’s shoulder) the idea of lacking the motivation to work whilst at home might only imply utter disdain for one’s work. Just changing location — putting peer pressure and supervision aside — does not provide any more or any less motivation. One can make one’s workspace more pleasant.

The reality is, many people do not work from home because the boss does not permit this. In that case, the boss needs to reassess the old myth that work should not be done remotely, i.e. not from home. People do not need physical access to paper files, for example. Everything changes, except old habits.

Retrieval statistics: 18 queries taking a total of 0.135 seconds • Please report low bandwidth using the feedback form
Original styles created by Ian Main (all acknowledgements) • PHP scripts and styles later modified by Roy Schestowitz • Help yourself to a GPL'd copy
|— Proudly powered by W o r d P r e s s — based on a heavily-hacked version 1.2.1 (Mingus) installation —|