Show Full Path in Shell (bash)

Tuesday, July 8th, 2008

Lets say you have to navigate to a long directory like /var/www/vhosts/mydomain.tld/httpdocs/myfolder/ etc

even if you give the command “cd /var/www/vhosts/mydomain.tld/httpdocs/myfolder/” at your shell window you will see only your username and the last folder , something like “root /myfolder#” in order you view the full path without having to use the pwd command every time, (more…)

Connections check shell script

Monday, June 4th, 2007

This is a very simple script to run and check how many connections each service (Apache,MySQL,SMTP (qmail)) has.

You only have to fill this: {mysq_ladmin_pass} with your mysql administrator password.

#!/bin/sh

pass={mysq_ladmin_pass}

echo “Apache Connections (port 80):” `netstat -an |grep :80 |wc -l`
echo “MySQL Connections (port 3306):” `mysqladmin -uadmin -p”$pass” processlist |wc -l`
echo “SMTP Connections (port 25):” `netstat -an |grep :25 |wc -l`

Common SSH Commands – Linux Shell Commands

Tuesday, May 29th, 2007

We’ve put together some of the more frequently used SSH commands or linux shell commands, and organized them by name so you can easily find a command, their description and how to use it. This guide will continue to be updated and should not be considered a complete list of SSH commands or linux shell commands, but commands, we found, often used. If you would like to add to this guide, please email us and let us know.

(more…)