Tim\'s picture      Blogging Ottinger (tim)

2008-April-15

Today’s Top Ten Command Line Tools

Filed under: Linux, Programming

This is all the rage lately, so I’m doing it too:

[0]tottinge@clicky:~$ history|awk '{a[$2]++} END{for(i in a){printf \"%5d\t%s\n\",a[i],i}}'|sort -rn|head
  119   sudo
   53   ls
   34   hpodder
   30   cd
   19   vi
   18   ping
   16   exit
   13   df
   12   apt-cache
   10   ./savepower.sh

Sudo is almost always for “sudo ifdown ath0; sudo ifup ath0=ath0-whatever”. I am mobile, and often switching wireless networks between home, airports, panera bread, church, taco john, goldentree at hotels, and other people’s offices.

savepower.sh is a script I made to put my laptop in low-power mode. I mostly took the advice from my copy of powertop. It seems to extend my laptop battery quite a bit, and it looks something like this:

#!/bin/bash  -x
SERVERS_TO_STOP=\"cupsys mysql bluetooth apache2 bittorrent mono-xsp tomcat5\"
for server in ${SERVERS_TO_STOP}
do
    sudo invoke-rc.d ${server} stop
done
sudo bash -c \"echo 5 > /proc/sys/vm/laptop_mode\"
sudo bash -c \"echo 1 > /sys/module/snd_ac97_codec/parameters/power_save\"
sudo bash -c \"echo 1500 > /proc/sys/vm/dirty_writeback_centisecs\"
sudo bash -c \"echo disabled >  /proc/acpi/ibm/bluetooth\"

Comments »

The URI to TrackBack this entry is: http://tottinge.blogsome.com/2008/04/15/todays-top-ten-command-line-tools/trackback/

No comments yet.

RSS feed for comments on this post.

Leave a comment

Line and paragraph breaks automatic, e-mail address never displayed, HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>



Anti-spam measure: please retype the above text into the box provided.

Get free blog up and running in minutes with Blogsome | Theme designs available here