In the macOS Terminal, my mouse scroll wheel would magically start scrolling the command line history instead of the window buffer scroll bar on the right to show window history. This happened when an SSH session was disconnected or timed out. The fix is to run the reset command.
If you want to preserve quoting to pass shell arguments to a called command, use the four characters “$@” (including the double quotes) instead of the two characters $*
When using Perl’s exec() call, the best way to invoke it is as follows:
1
exec("$dir/myprog.sh",@ARGV);
This syntax does some important things: – passes a scalar value as the first argument which exec interprets as PROGRAM – passes an array as the second argument which exec will use as the arguments to pass into PROGRAM Note […]
Tungsten Clustering provides high availability, disaster recovery, and a host of other benefits for MySQL / MariaDB / Percona Server databases. In this blog post we will explore some of the shell aliases I use every day to administer various Tungsten Clusters.
There are times when the hackers slam my servers and the load gets too high. I use a very simple bash script as a cron job to monitor the load and take action when it gets too high. The script will stop httpd, sleep for a configurable period of time (currently 3 minutes), then start […]
The Readline library has a bell-style variable that controls what happens when Readline wants to ring the terminal bell. If set to ‘none’, Readline never rings the bell. If set to ‘visible’, Readline uses a visible bell if one is available. If set to ‘audible’ (the default), Readline attempts to ring the terminal’s bell. Edit […]