It’s actually a tip from Lincoln, who emailed me last month:
Another idea is to replace bash (~4M/instance) with pdksh (~1M/instance). It doesn’t sound like much, but if you’re like me and you’re have a half-dozen or more concurrent ssh sessions, plus you’re su’ed on a couple of them, etc… it can be a significant help.
Indeed. Bash, which is the default interactive shell on most (if not all) Linux distributions, has pretty much become THE user interface of the command line users. When I first used it in mid-90’s (on SunOS/Solaris), it was a great relief from the plain vanilla bourne shell, and was much better than the default shell back then, korn shell, IMHO. It was love at first sight.
However over the years she has just gone fatter, heavier and was getting more and more CPU intensive to start. It did not really bother me though, as my main computer has also grown in grunt… Not until are trying to run it on a small low end box!
pdksh seems to be quite a good replacement. It uses relatively less resource, has simple tab completion, has history (what else do you need from an interactive shell?) and has bourne shell style syntax (if csh/tcsh is not your thing).
If you are really extreme and thinking tab completion and command line history are for n00bs, also give dash a try. Here’s a memory usage comparison:
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND root 8658 0.0 2.8 3788 1848 pts/0 S 20:42 0:00 bash root 8732 0.2 0.7 1604 464 pts/0 S 20:44 0:00 dash root 8733 0.0 0.8 2844 552 pts/0 S 20:44 0:00 pdksh
For me, I’ll stick with bash for now. You know, user interface is the thing that once you got used to, it’s hard to unattach yourself from (i.e. too old to learn new things). Good luck young padawans for picking up new light weight shells!
Related Posts:
- 5 Reasons Why You Want a Low End Box - May 26, 2021
- Dead Pool January 2012 - February 2, 2012
- exit(0); - January 19, 2012
Half a dozen concurrent ssh sessions? Try screen :P One session, you can split horizontally/vertically, multiple “tabs”, it’s great.