Archive for May, 2005

25
May
05

Hacking with gtk themes

I was bored of my gtk bright theme, so i was searching for a new theme, a dark theme. But i didn’t find a perfect theme. So i created my own one :P
Is based/inspired on darkcoffe2 and Chatsubo using the ClearLooks gtk-engine (yes, i love the animated progress bar :P)

The theme is ClearLooks-DarkBlue-0.5 and of course a screenshot

DarkBlue

The theme is not perfect (yet) so any comment is welcome. If you like, or not, it drop me a comment :)

In other hand, ikke made an script with ideas from recursos.sh so only for plain text. is a nice script :)

I never did one before so i learned a lot about gtkrc file. Was a hard find all colors and values so i will include a lil description of some values :

Continue reading ‘Hacking with gtk themes’

19
May
05

Trying a new kernel

The Linux viirtual memory (vm) system is not good (is not a secret) so in Linuc/ppc it sucks…
In my ibook g4 800Mhz 365Mb i had ever the RAM about 65-75% used and the swap about 80-90% so dholm suggest me to try ck-sources nad here we go:

ACCEPT_KEYWORDS=”x86 ~x86″ emerge ck-sources

2 days using it without problems :)

clarisse ~ # Recursos.sh mem swap
62 % used
18 % used

The Ram used is very similar, so it don’t full completly in compilations and swap is very-low used.
nice :)

16
May
05

www-servers herd

I‘m now part of the www-servers herd.
My first commit and updated www-servers/cherokee ebuild. You can now specify ssl, gnutls, ipv6, pic and static USE flags. and it is updated to the last version (relased 2 minutes ago ;) in ~x86.

enjoy

In other hand, thansk for the comments about the system report script nice ideas, ipaudit is very nice, so i need a one way system (clients –> server) and i need more info not only BW.

PS: Congs to Ciaran the unofficial dev-hb is so great :)

11
May
05

BandWidth bash function

Added to the recursos.sh script a function for the bandwidth. You need to define $DEV and then run the function the first time to create the neccesary file, then you can run it every 5 minutes for example :)

ibw () {
DEV=eth0
if [ -f /tmp/bw-$DEV.tmp ]; then
set — $(cat /tmp/bw-$DEV.tmp)
OLDSEC=$1
OLDRX=$(($2*8/1024))
OLDTX=$(($3*8/1024))
set — $(ifconfig $DEV | gawk ‘/RX bytes/{print $2,$6}’ | sed ’s/bytes://g’)
NEWRX=$(($1*8/1024))
NEWTX=$(($2*8/1024))
NEWSEC=$(date +%s)

RX=$((($NEWRX-$OLDRX)/($NEWSEC-$OLDSEC)))
TX=$((($NEWTX-$OLDTX)/($NEWSEC-$OLDSEC)))
echo $RX $TX

echo $NEWSEC > /tmp/bw-$DEV.tmp
echo $1 >> /tmp/bw-$DEV.tmp
echo $2 >> /tmp/bw-$DEV.tmp

else
## Create file with first timstamp
set — $(ifconfig $DEV | gawk ‘/RX bytes/{print $2,$6}’ | sed ’s/bytes://g’)
date +%s > /tmp/bw-$DEV.tmp
echo $1 >> /tmp/bw-$DEV.tmp
echo $2 >> /tmp/bw-$DEV.tmp
fi

}

04
May
05

system info report script

A bash script to report system info, yes, another one. So i need to do it only using bash and standard shell tools. My script generate “raw” info (without format) and a cute html report :)

The idea is to use it in the embedded systems the i use in my job. The script is used to send “raw” info to a monitoring app and to create a html report to be viewed in a java app so no css, js or html4 can be used. Any suggestion or modification is welcome :) The next step is implement bandwidth stats.
What kinf of inof report? cpu, disks, mem, tasks, net, etc…
how it work? very easy

# sh recursos.sh cpu
# 3.3

“3.3″ is 3.3% of cpu used

So for a cute html format:

# sh recursos.sh title general system net disks > info.html

and the example is here.
So only need to read the scritp to know all functions that you can use :)
Improves and suggestion are welcome.

UPDATED: version 1.0.9 :)

So download it and enjoy:

  • recursos.sh 1.0
  • In other hand the pics from my birthday in asmterdam have so many fans lately :P




    del.icio.us

    Flickr Photos

    Jose Alberto Suarez Lopez





    More Photos