Using rsync over ssh

You can securely synchronize directory structures between two Linux computers by using the following command:

rsync -ave ssh --delete myhost.example.com:Documents/ Documents/

The −−delete option ensures that any files or directories that no longer exist on the source are also removed from the destination.

Tagged with:
 

Reset TYPO3 password

If you forget your typo3 password, you can reset it using the mysql command line tool as follows:


mysql> use typo3;
mysql> update be_users set password='bacb98acf97e0b6112b1d1b650b84971' where username = 'admin';

This resets the admin user password to “joh316″.

Tagged with:
 

Ruby on Rails for RHEL 5

Here is the quick and dirty Ruby on Rails setup for Redhat Enterprise Linux v5.0 with MySQL.

(2009-12-04 Update: This does not work with RHEL 5.4. The mysql ruby gem requires ruby 1.8.6 and RHEL 5.4 only ships with ruby 1.8.5)

Using yum install ruby and mysql. The command below does not list all the required packages, but due to dependencies, the additional packages will be installed (or should be – this is all from memory).
(more…)

Tagged with:
 

For those running Xen on servers with no back-end SAN, the following instructions detail the steps necessary to move an LVM-based virtual machine to a new physical host. There may be more elegant ways to achieve this, but this is what worked for me.

Environment
Ok, so let’s set the scene:

  • vmhost is a RHEL 5 server running several virtual machines using the Xen virtualization technology. Each virtual machine is allocated a 60 GB logical volume within an LVM volume group. One of these virtual machines, “win2k3vm”, needs to be moved to a new server.
  • new-vmhost is almost identical to vmhost, but has updated hardware and more memory. This is the server that “win2k3vm” will be moved to.

(more…)

Tagged with:
 

Install phpMyAdmin

phpMyAdmin is web-based PHP application for managing MySQL databases. It is fairly easy to install and configure.

Download the latest stable version from the phpMyAdmin web site, and extract it to a location of your choice. I prefer to keep the installation outside of the web root and use an apache alias to reference it.
(more…)

Tagged with: