Compiling subversion 1.7.1 from source with SSL


If you need to install Subversion 1.7.1 to a server with SSL support, here’s a quick routine to get that done.

Download the latest version
cd /usr/local/src
wget http://apache.mirror.aussiehq.net.au/subversion/subversion-1.7.1.tar.gz
tar -zxvf subversion-1.7.1.tar.gz
cd subversion-1.7.1

Use the in-built script to download the required dependencies, and configure neon for SSL
./get-deps.sh
cd /neon/
./configure --with-ssl
make
make install
cd ..

Download and install the required sqlite3.c
wget http://www.sqlite.org/sqlite-amalgamation-3.7.0.1.tar.gz
tar xvzf sqlite-amalgamation-3.7.0.1.tar.gz
mkdir /sqlite-amalgamation/
cp sqlite-3.7.0.1/sqlite3.c /usr/local/src/subversion-1.7.1/sqlite-amalgamation/

Configure & make Subversion
./configure --with-neon=/usr/lib64/
make
make install

if you’ve used default install locations, add to path
export PATH=$PATH:/usr/local/bin

How to configure a MySQL cronjob backup without exposing your password

Create a .my.cnf file in the home directory, (note the leading ‘.’ this hides the file)
nano ~/.my.cnf

Add the following section to your file:
[mysqldump]
user = mysqluser
password = yourpassword

change the file permission to 600 to secure the cnf file.
chmod 600 ~/.my.cnf

configure your cronjob as normal, note that you do not need to pass the -p switch as crond will read in your .my.cnf
crontab -e
0 30 * * * mysqldump databasename -u mysqluser > pathtofile.sql

thats it nice and simple

Further crontab syntax info can be found here

Find the 10 largest files

Useful command, if you ever need to, and if you admin Linux you might have to more often than you want to, find the 10 largest files on disk!

$find / -type f -exec du {} \; 2>/dev/null | sort -n | tail -n 10 | xargs -n 1 du -h 2>/dev/null

and thats it!