I no longer host my sites at WestHost. This information is no longer maintained.

Other similar sites

Jalal's site

See Jalal's site for more useful information about running sites on WestHost. In particular, he keeps a copy of ssh in a tarball, so you can scp it into the site and can then use it.

Shawn Sorrell's site

wildjokerdesign.com has a set of forums for helping WestHost users with common problems.

WestHost Forums

forums.westhost.com has a set of forums too, and the chance to offer direct feedback, feature requests, etc. to the WestHost staff. The site itself feels incredibly slow to me though.

WestHost tips and tricks

Cron jobs

The WestHost crontab interpreter isn't very smart. Your crontab entries cannot contain comma or forward-slash (, or /) characters in the time fields. If any of your crontab entries contain these characters, then none of your cron jobs will run, which is exactly what you don't want to happen.

SSH keys

Near 5-June-2005, WestHost added some new server hardware for their VPSs to run on, and moved the VPSs among the new servers. This causes 2 interesting changes from a client perspective:
  1. Your SSH host key changes. The first time you connect to the server using ssh, you'll get a warning message that the host key has changed, and that this may be a man-in-the-middle attack. It's not, your VPS is just on a new piece of hardware that has a fresh install of the sshd, so it has a new host key. It's OK to remove the .ssh/known_hosts line noted in the message and re-connect.
  2. Automatic logins using ssh public/private keypairs may no longer work. Per WestHost tech support, there is a per-server (not per VPS) change that must be made to enable use of public/private keypairs. Contact tech support if you use this feature, but are still prompted for a password rather than it using your keypairs, and they will enable it for the server that your VPS is running on.

Matt's WestHost add-ons

Here are instructions for installing most of the extra packages I use on WestHost from source code. Maybe some of these will become standard offerings in the future.

transmission bittorrent client

Note: If you are on a shared hosting plan, WestHost wants you to keep your processes to below 1% CPU utilization. For me, transmission-daemon was routinely running at 6-7%, even running at nice 19. You can try limiting your bandwidth used, and limiting max peers, to see if that helps. If not, WestHost may ask you to move to a more expensive plan. Using the --encryption-tolerated option seems to --reduce the amount of CPU used, and I limit the number of peers to 20.

Transmission 1.73 works fine. The below presumes you have newer libcurl and libssl in /home/youruser/lib already.

$ PKG_CONFIG_PATH=/home/youruser/lib/pkgconfig ./configure --disable-nls --prefix=/home/youruser
$ make
$ make install
Then I use this shellscript to start it:
export TRANSMISSION_WEB_HOME=/home/youruser/share/transmission/web
nice -n 19 transmission-daemon -w ~/torrents -c ~/torrents -L 20 -M 
sleep 10
transmission-remote -GSR -u 700 -D -gpr 20 --encryption-tolerated
When running it, be sure to set your maximum upload / download bandwidths based on your vhost pricing package. For a 200GB/month transfer, I limit to 50KB/sec. For 2TB/month, I use 700KB/sec. This leaves some headroom for other applications.

Older version 1.1

See the README for instructions, and the patches for version 1.11 you'll need. A set of pre-compiled executables (and corresponding source) are also available.

rsync

$ ./configure --prefix=/usr/local --with-included-popt
$ make
$ make install
If you need to run rsync as a daemon, I did so from xinetd. Note however, that you cannot make it listen on the default rsync port 873/tcp, because WestHost's own system backup tools running in the hosts (not the VPSs) bind to 873/tcp on all IP addresses, including those inside the VPSs. From WestHost support 2005-Dec-01:
 rsync is used in the backup process for our servers. I am afraid that
 the setup of this process cannot be modified, as this would entail
 changing the configuration of our backup utilities system wide. I am
 sorry about the inconvenience, but you will need to configure rsync
 to run on a different port.

mailman

The only problem with installing mailman as described here is that apache runs as your username and group vuser, which means that mailman must be compiled the same way. When doing so, your private mail archives can't be private. So, either don't archive private lists, or don't make any archives private.
$ ./configure --with-username=myusername --with-groupname=vuser \
  --prefix=/home/myusername/mailman --with-mail-gid=vuser \
  --with-python=/usr/local/bin/python --with-mailhost=mydomain.com \
  --with-urlhost=mydomain.com --with-cgi-gid=vuser
$ make
$ make install
You must also add a line:
SMTPHOST = 'mydomain.com'
to mailman/Mailman/mm_cfg.py because sendmail listens on this, not on localhost.

emacs

$ ./configure --prefix=/usr/local --with-x=no \
  --without-toolkit-scroll-bars --without-xim
$ make
$ make install
Remove -g flag to gcc in Makefile before running make, else the binaries will segfault. I don't know why.

Daniel P Faigin also reports:

Actually, -g wasn't all that critical. What I ended up need to do was
to edit configure, and change the default setting of doug_lea_malloc
to no (the default is yes). Then it compile and ran just fine (this is
emacs 21.3).

IMAP

As of late October 2006, WestHost provides IMAP. That works great.

ncurses

ncurses normally writes to /usr/local/lib, but on WestHost, that directory is mode 555 root:root, so your normal user can't write to it. This means it needs to be installed elsewhere, like your home directory.
$ ./configure --with-shared --with-normal --without-debug \
  --enable-overwrite --prefix=/home/myusername
$ make
$ make install

mutt

Mutt needs one additional patch due to the permissions on /dev/urandom that mutt doesn't like, and it can't chgrp files to group 'mail'. In addition, I like having the current time added to the status line. Apply one or both of these patches, then build as normal.
$ ./configure --with-included-gettext --prefix=/usr/local \
  --enable-imap --enable-pop --with-curses=/home/myusername \
  --with-ssl --without-gss
$ make
$ make install

gnupg

$ ./configure --prefix=/usr/local
$ make
$ make install

xinetd

$ ./configure --prefix=/usr/local
$ make
$ make install
Here's my /etc/xinetd.conf file which provides rsync and IMAP services, and my /etc/rc.d/init.d/xinetd startup script.

elinks

$ ./configure --prefix=/usr/local
$ make
$ make install
$ rm -rf /usr/local/man/*
I also added this line to my .mailcap file so mutt calls elinks to display text/html messages:
text/html; elinks -dump -dump-charset iso-8859-15 -default-mime-type text/html %s; needsterminal; copiousoutput;

tcsh

From: "Daniel P Faigin"

In order for me to compile the tcsh shell, I had to edit the makefile
to use -lncurses.

ImageMagick

Pretty normal install, but /usr/local/lib is owned by root and nonwritable by mortals, so it needs to go in your home directory. Since it packages its own libs too, you need to run ldconfig afterwards. You do have /home/myusername/lib in your /etc/ld.so.conf file, right?
$ ./configure --prefix=/home/myusername
$ make
$ make install
$ ldconfig

lftp

I couldn't get lftp-3.4.2 to compile on WestHost 2.0. Then I realized that's because WestHost's environment is much like Red Hat Enterprise Linux 2.1, with (ancient) gcc and g++ (version 2.96). Current versions of lftp aren't so happy.

But of course, starting with the source from lftp-2.4.9-3.src.rpm on Red Hat's site, I was able to make this version work. Here's the source as extracted from the rpm. You need to specify --prefix, as it installs files in $prefix/lib/lftp, and /usr/local/lib isn't writeable by mortals. Since it packages its own libs too, you need to run ldconfig afterwards. You do have /home/myusername/lib in your /etc/ld.so.conf file, right?

$ ./configure --with-modules --disable-static \
  --with-ssl=/usr/include/ssl --with-debug \
  --with-included-readline --prefix=/home/myusername
$ make
$ make install
$ ldconfig

Perl

Check the Site Applications, newer perl releases (5.8.7) have been posted there starting late 2005. Use those if you can.

WestHost 2.0 makes Perl 5.6.0 available in the Site Applications. That's great, but newer SpamAssassin (3.0.2) needs at least Perl 5.6.1. And I get a lot of spam (~200/day) which newer SA blocks better than older SA. So, to installer new SA, I need to build a newer Perl too. This is pretty simple. And to keep it clean, I install the new Perl in its own location, rather than the default.

$ cd /home/myusername
$ mkdir perl586
$ cd perl-5.8.6
$ ./configure --prefix=/home/myusername/perl586
$ make
$ make test
  (here a couple tests failed, related to localhost sockets, which
  because we're on a VPS aren't working quite as Perl expects.  Ignore it.)
$ make install
Then if you use CPAN, install (using your new /home/myusername/perl586/bin/perl always!) the stuff it needs. Be sure to set makepl_arg to use your new location for PREFIX:
cpan> o conf makepl_arg "/home/myusername/perl586/bin/perl PREFIX=/home/myusername/perl586"
Then CPAN can install Mail::SpamAssassin and its dependencies for you. If you don't set makepl_arg, then CPAN may automatically put stuff in /perl586, which isn't right, and won't work.

MediaWiki

This is easy. Just unpack the mediawiki .tar.gz file into your web server directory, rename it 'wiki', chmod a+w config/, and point your web browser at it. You'll need mysql and php installed from the site applications. You'll also want a .htaccess file in your wiki directory to limit php globals:
php_flag register_globals off

Matt's WestHost Customizations

Here's how I customized some of the WestHost-provided applications.

Horde IMP

Nice little webmail tool. Just a few tweaks: