Purpose: My website www.koolwal.net which in turns has this blog site that you are reading is being hosted by Bluehost web hosting company. Last week I decided to install the popular source code revision control program called Git on my Bluehost account i.e. on www.koolwal.net. In this blog post we will see how can we install git on Bluehost web hosting accounts and may in general these steps might be true for other web hosting accounts also.


It seems that Bluehost by default does not supports or tells you how to install Git. I also tried posting a query on Bluehost’s forums to see if anybody has done it before but with no luck. So I decided to just go ahead and try this out myself. Also note that you will need to enable the SSH access on your Bluehost account to do this. You can easily enable SSH on your account by sending a request to Bluehost Tech support.

Here are my specs from the Bluehost account:

myuser@koolwal.net [~]# cat /proc/version

Linux version 2.6.28-9.16.intel.BHsmp (kernel@bluehost.com) (gcc version 3.4.6 20060404 (Red Hat 3.4.6-10)) #1 SMP Sat Apr 18 11:41:59 MDT 2009
myuser@koolwal.net [~]#

Basically it is a Red Hat Linux system with 2.6.28 Linux kernel running. So now we have all the information that we need let’s get started…

Step 1: Download git tarball

Log into your Bluehost account and give the following command:

# wget http://kernel.org/pub/software/scm/git/git-

Note: The latest stable release version might have changed since this posting, so you need to substitute in the above command the latest git version that you would like to install or else you can continue with the git version that I ended up installing. You can checkout the latest stable release version of git here.

Step 2: Extract the tarball

Now just extract the tarball installation file in your home directory

# tar -xjvf git-

Step 3: Compile the git program

# cd git-
# make

Now mostly after a while you will get the following error message and your make command will fail:

make[2]: true: Command not found
make[2]: *** [blibdirs] Error 127
make[1]: *** [all] Error 2
make: *** [all] Error 2

It seems that the true command is not installed on the bluehost servers but you type in the command true it seems that it exits:

myuser@koolwal.net [~]# true
myuser@koolwal.net [~]#

This probably means that the git make command is not able to locate the directory in which the true command sits.

Step 4: Fix “true”: Command not found error

The simplest way to fix this error is to create an empty script file called true with just the following line:


Save and exit the file and copy it in your local bin directory after making it executable:

# cd;
# chmod 755 true
# mkdir bin (if the directory does not exits)
# cp true bin/true

and now you can re-issue the make command:

# cd git-
# make clean
# make

and now after a while you should see the the “make” command finishes without any error.

Step 5: Install the git program

Finally you can install the git software by issuing the following command:

# make install

and you should be able to execute the “git” command on your Bluehost account.

Step 6: Test git

Now it is time to test if the “git” program installed successfully or not.

# mkdir test_project
# cd test_project
# git
# git init


Initialized empty Git repository in /home1/myuser/test_project/.git/

Congratulations the above output means that your “git” is working just fine and now you can use it for your project that you have been planning.

Happy Giting!

Be Sociable, Share!