Easily Image any Hard Disk

I suppose we can start out the new month with a informative post today. At work some friends were setting up some Windows XP machines and wanted to image the disk so that the process for setting up all eight machines went faster. Having no access to disk imaging software at the moment I suggested that they just use `dd` in Linux to do the image. None of them had really heard of this program, so I explained to them how to use it.

A easy way for anyone to do this is to grab a boot-able Linux CD, we used TRK, and grab a external USB hard disk.

Boot from the CD, and choose the first boot option. Mount your USB disk somewhere easily accessible. We did ours as such:


mount /dev/sdb1 /mnt0

then we created an image of the first computer (the one we are currently on, and has Windows XP installed on it already and configured):


dd bs=16384 if=/dev/sda of=/mnt0/image.img

Once the process is complete power off the machine and take the USB hard drive and CD to the next, boot from the CD and mount the hard disk. Issue the command:


dd bs=16384 if=/mnt0/image.img of=/dev/sda

As you can see, `if=` is the Input File for dd, and `of=` is the Output File. `bs=` is the block size to copy between the disks, you can increase this if you wish to see better performance in faster machines.

By |May 1st, 2009|Categories: How To|Tags: , , |0 Comments

Installing Joomla! Permissions

I am writing this to help others that have *NIX permission problems using Joomla! on some web hosting providers.

The scenario:

1) You have an account on a shared server.
2) You can FTP to the server, but files you upload are created with your ftp login name as the file owner.
3) The server runs Apache under a different username, like; www-user or apache.
4) If you have shell access to the server, there is no difference, files are created with your login name as the owner.

Now the problem, you install Joomla! by FTP’ing all the files to the server, run the install program, install Joomla!… All is good? Most of the time, no. WHY!?

Permissions! Thats why.

After your install, you are pretty happy, then you start uploading modules, and components. WRONG. You now have to chmod directories and files. Some automated tasks of Joomla!, some Components, Modules and large programs like Forums and such don’t work correctly, or throw permission problems at you.

There is a way to get around it all though, and it’s not very hard either. The tools you need are free, and available from sites that create Joomla! Tools and the like.

First, we need to get all the files running as a single user, and the best user to do that is the user the Apache process is running as. This is that account; www-user or apache.

How do we do this? Simple, use web based tools. They run as apache, therefore, everything they create, will be created with the apache user as the file owner. No more permissions problems.

Now that I have you intrested, lets get to work.

Please note that I will write this as I’m going through a new Joomla! Installation.

There is a tool called; JoomlaStart Automatic Installer , this is a simple PHP file that you upload using FTP, and use your browser to view this PHP page. It will download the Joomla! CMS .zip file to your webhost, and extract it for you, all under the apache user name.

When you run the JoomlaStart Installer, choose to Install the Files Directly.

When thats done, it will start the Joomla! Installer for you. Complete the installation. When you are done with the install, get the component JoomlaXplorer , it is a complete file management system in Joomla! (You guessed it, running as the apache user.)

You can use the JoomlaXplorer software to upload files, extract zip files, and rename, move, copy and all that good stuff around your webspace. You no longer have to use FTP.

Of course, doing this will limit your FTP access to these files, because they are now running as the apache user.

I create a folder using my FTP client, to upload very large files to, then use JoomlaXplorer to copy them to another location, changing the owner of the file. Then I use FTP to delete the file I origionally uploaded. Done.

By |January 24th, 2008|Categories: General|Tags: , , , |2 Comments