To share or not to share? The difference between shared and dedicated server hosting

Whenever you’re looking for a new hosting company, you always need to know what you’re planning to do beforehand. You also need to communicate with the provider you’re thinking of going with beforehand to make sure that your project will be stable for their equipment. For the most part, these people don’t want to deal with you if your scripts are hogging up bandwidth because it only makes their other customers angry and more money being spent from their pockets.

For example, I wanted to pursue a podcast that reached 10,000 subscribers every week and that was 20MB in size. The host I approached said that it wasn’t a good idea, so they pointed me to another. That’s better than me having to find a new one after one month anyway.

With media files, you always want to go dedicated because of the size. If you’re an artist, filmmaker, or photographer, you’re most likely wanting to showcase your work in the best quality. Photographs are usually 2 to 5MB in size and shared hosting might not always be set to take it via something like WordPress. Otherwise, you’d have to do it manually. The fix would be to edit your php.ini which is only available in a dedicated server setting. Applications, forums, and any other site that requires registration is more suited to this type of server.

Shared servers should be used for small blogs and single page resumes or showcases. They’re mostly limited in size for that reason. Having 100 forums with 1,000 active members each will overload the server. So it’s not exactly the best setup.

So basically, if you want space to grow your own community, a dedicated server is the best. If you’re looking to operate a one man band with a small blog that won’t have much, then sharing is the better option.

How to install APC Cache (Latest Version) In 10 Steps

If you’re unable to get xCache working, or are looking for other PHP caching solutions on your server to help reduce the load, APC cache is a great alternative. APC stands for Alternative PHP Cache and has been around for a long time, and now supports PHP 5.3 in its latest version we’re about to install.  APC is an open source cache alternative, and gets it’s updates from a handful of dedicated developers.

Simply follow along to get a good clean install of the latest APC version. All of these commands are run from SSH as the root or super user.

[sourcecode language=”bash”]
# cd /usr/src
# wget
# gzip -d APC-*
# tar -xf APC-*
# cd APC-*
# which php
# phpize
# ./configure –enable-apc –enable-apc-mmap –with-apxs –with-php-config=/usr/local/bin/php-config
# make
#make install

Line 1. Changes you to the /usr/src directory. {optional}
Line 2. Gets the latest APC version
Line 3. Unpacks the version
Line 4. Unpacks the download
Line 5. Moves you to the APC folder
Line 6. Lets you know where PHP is, should be something like ‘/usr/local/bin/php’
Line 7. Creates configuration files
Line 8. Configures APC cache with the predefined options
Line 9. Makes the install files
Line 10. Installs APC to your system

Lastly we need to edit the php.ini file

[sourcecode language=”bash”]
# locate php.ini
# nano /location/of/php.ini

Search for ‘extension_dir’ and below that place

[sourcecode language=”bash”]

Finally restart apache
[sourcecode language=”bash”]
# service httpd restart

Alternative PHP Cache (APC) is now installed to your system. You can tweak the settings by editing the lines above in your php.ini file. (Don’t forget to restart every time). If you want to check if APC is working, simply create a php info page, and look for the section on APC. There is also an “apc.php” file inside your /usr/src/APC-* folder, you can move to a public location and view it from the internet for stats.

How to install xCache from source

Running a caching solution on your VPS or dedicated server can squeeze a few extra users on it before you’ll have to upgrade to more expensive hardware, and should reduce load times for visitors. A total win-win situation for all involved.

{code type=code}wget
tar -zxf xcac-*.tar.gz
cd xcache
./configure –enable-xcache
make install
cat xcache.ini >> /etc/php.ini

Line 1. This gets the xcache files needed for install. Currently at version 1.2.2
Line 2. This untars the package
Line 3. Switches you to the xCache directory
Line 4. Lets you install xCache without recompiling php
Line 5. Sets configuration options
Line 6. Prepares it for install
Line 7. Installs
Line 8. Adds the default xCache configuration options to your php.ini file. (Note: If your php.ini file is in a different location do a ‘locate php.ini’ to find it)

After you’ve installed it you’ll need to change php.ini to ensure everything is okay.

{code type=code}nano /etc/php.ini{/code}

Make sure that ‘zend_extension=../../’ appears before all other ‘zend_extension=….’ or else you’ll have problems.

Just for good measure, restart php and apache to ensure nothing fails. Enjoy your new optimized caching server!

Choosing the correct hosting company

Whenever you decide you want to launch a website one of the first things you’ll need, is the hosting services. Luckily sites like this one exist that let users rate their hosting experiences and you don’t have to worry about if the hosting company is good or not, or if they pay out the highest affiliate sale for their number one rating.

Specialized Hosting:
Choosing the correct hosting company really depends on the project. For instance if you use a popular script like vBulletin, there are hosting companies who specialize in their hosting for them. URLJet is one example of a provider who would be a specialized hosting company.

Hosting for SEO:
Your websites speed is a ranking factor of how well it does in search results. If you have a slow site, then you’re ranking could be negatively effected. If you have a fast site, your rankings would positively be effected. While this maybe a small ranking factor it can also be a deal breaker for your visitors. If your site is taking over 5 seconds to load, then expect the visitor to be on his way out before he ever gets a look at it. If you have a project where it’s success is vital, completely skip shared hosting environments and go with a VPS provider. Reading user reviews of VPS hosting providers can be a good way to learn about what companies to go with, and who to avoid.

The Best Support:
No one ever wants to experience the dreaded down time, especially when its something out of your hands. Having a hosting company with a great support department is essential to your hosting experience. If the hosting support team doesn’t know what they’re doing, expect it to be a bad overall experience. The best support teams for hosting companies out there I’ve seen will help you every step of the way, and will actually work improving your sites load times by making suggestions to improve it, don’t settle for anything less when it comes to support.

Don’t rely solely on numbers, and don’t get scared of them either:
Most hosts these days are really throwing the “Unlimited” term around. Nothing is or can be unlimited, and it couldn’t be more true in the hosting industry. This is a common tactic known as “overselling” and you shouldn’t make your decision based off of it. Don’t be afraid to go with a host who oversells either, usually they are still reliable and provide good service for the price you’re paying.

Find a hosting company, who is only a hosting company:
It maybe tempting to get hosting after you’ve purchased a domain name, especially if you can do it all in one spot. This generally leads to major disappointment, and paying to much for hosting services that are sub-par and could be found cheaper and better else where. A company who’s primary focus is on something like domain names, won’t be able to provide the top level of support they should, and you shouldn’t have to settle for less!

Find a host that gives back:
Most hosting companies usually give you something in return for using their services. Some hosting companies will provide you with over $100 in coupons to services like Google Adwords, or Yahoo search marketing, and some provide them for Miva merchant accounts. If you’re looking for a hosting company that gives back to the environment rather than your pocket books check out Think Host and their eco friendly approach to hosting.