Commonly used linux commands
Here’s a list of useful linux commands for anyone running a website on a LAMP box.
df – report file system disk space usage (ex: df -h)
chmod – change permissions to make files/directories read/write/executable (ex: chmod +777 dir)
chown – change ownership of a file (ex: chown file.txt me)
whomai – determine what user you logged in as/running under.
which – determine the location of an executable (ex: which convert)
cd – change your current directory, where tilde ~ is your home directory. (ex: cd ~/)
ls – list files in current directory (ex: ls -la)
cp – copy files (ex: cp * directory)
mv – move/rename files (ex: mv * directory)
Those are some of the shell commands. Here are some other misc commands I commonly use:
crontab – edit my cron jobs (ex: crontab -e)
php – run php on the command line (ex: php -f filename)
sudo – super user do (ex: sudo command)
wget – web get (ex: wget http://www.google.com )
uptime – server uptime
ps – list processes ( ex: ps -aux )
Other commands to retrieve information about hardware:
cat /proc/cpuinfo
cat /proc/meminfo
dmesg
Those are some of the basic commands needed to run a website on a Linux Apache Myql Php box.
I’ll post about dealing with and running Apache and Mysql next time I have to install apache.
Running MySQL and Apache requires a different set of skills. I’ll post about simple MySQL administration/client uses and commands in my next post.
An excellent blog article on how to setup CutyCap
Check this article out if you want to know how to setup CutyCap on Ubuntu Linux,
http://mattaustin.me.uk/2009/01/thummer-website-thumbnail-generator-cutycapt-django/
It’s the best one around and saved me hours if not days of work trying to figure out why certain headers/libraries didn’t exist.