Cloud Sites: FAQs


- Getting Started -

What goes in to calculating a compute cycle?

Mostly, CPU processing time. However, compute cycles also account for the disk I/O your application's operations consume. For example, a page with heavy database queries will consume more compute cycles in part due to the larger volume of disk I/O it requires.

How do I track my compute cycle usage?

The compute cycles you use are presented in your control panel in near real time.

What are compute cycles?

Compute cycles measure the amount of processing time your applications take to execute in order to serve content to users from the Cloud Sites environment.

Account Services

How far can I really scale?

We currently have users pushing hundreds of millions of requests on single domains. There are many factors that impact how easily a web application can scale, including the application’s code and its architecture. Rackers are ready to review your web application/solution and provide guidance on how to optimize it for Cloud Sites. If an application is not properly built for scale, Cloud Sites will not be able to compensate for it.

Also, if you are expecting a massive surge in traffic (perhaps your site was featured on Oprah) please contact us via chat, phone, or ticket in advance and we will help you prepare for it. The information we will need can be at the end of the How do I optimize my website? article.

What happens if I exceed the included amount?

While most customers will fall well below the included amount, we have created fair and simple pricing beyond the base amount that means you pay ONLY for what you use and nothing more. There are no onerous penalties for exceeding the included plan amounts. The prices for all scaling metrics can be found on the Cloud Sites Pricing Page.

What is included for $150?

We have included enough resources in the Cloud Sites base package to power most business needs. You get 50GB of high performance storage as well as 500GB of bandwidth per month. In addition, Cloud Sites uses compute cycles to monitor your computing usage. You get 10,000 compute cycles per month across all your sites and applications. Unlike many hosting companies, The Rackspace Cloud will never cut you off for using what we sell you.

The base package does not include the cost of MySQL/MSSQL database storage, SSL, or domain registration.  More details can be found on our pricing page.

I've had shell access (SSH) in the past. Why isn't it offered on Cloud Sites?

Shell access (also commonly known as SSH access) is not offered on Cloud Sites, primarily for security reasons. Keep in mind, however, that many functions typically accessed via shell are available on The Rackspace Cloud, including cron jobs, file permissions, and unzip. You can also do many SSH type functions by mounting your FTP location locally using SSHFS. More information can be found here.

Finally, if full shell access is required, check out our Cloud Servers offering.

Will The Rackspace Cloud ever suspend my site if it receives tons of visitors?

The Rackspace Cloud will never suspend a site as long as the traffic is legitimate and the hosted content doesn't violate our TOS or our AUP. As a company, we succeed when you succeed so we will always encourage legitimate traffic to your sites. We have several domains on Cloud Sites that receive millions of hits each month. We have never limited or throttled their accounts, as that is one of the many benefits of going with a Cloud offering like The Rackspace Cloud Sites service. On the other hand, we will stop any illegitimate spikes in traffic, such as, runaway scripts or DDOS attacks, etc.

Can I use Cloud Sites as an audio or video encoder?

The Rackspace Cloud isn't afraid of the facts. And the fact is, audio and video encoding is a good example of a task that a Cloud Server is better suited for. We built Cloud Sites to be a highly specialized and optimized computer cluster for serving web content. That means it's not really designed for audio processing, video processing or streaming tasks. It's okay to have some audio or video content on Cloud Sites (if you own the copyrights, of course), but it's not meant to be a processing farm for audio conversion, video conversion or a Shoutcast system to use for live audio streaming. Check out FFMPeg on Cloud Servers.

Can I host adult content sites on The Rackspace Cloud?

Please refer to our Acceptable Use Policy for details on what content can be hosted with us. You can find a copy of our AUP on our website.

Where can I find your AUP (Acceptable Use Policy

You can find a copy of our AUP, TOS, and SLA on our website.

How many compute cycles will my applications use?

Since web applications vary so greatly, it's hard to make a perfect guess. There are, however, some guidelines that can help. For example, 10,000 compute cycles would power approximately:

  • 2.1 million page views using a database-driven content management system
  • 11 million page views of rackspacecloud.com
  • 25 million requests for a static 15KB image

Backups

How often do Cloud Sites backup information?

The entire Cloud Sites FTP structure is backed up in an FTP Snapshot at the top of every hour, going back 32 hours. Those backups are rolled into a nightly backup, which are retained for two days. However, these backups are for disaster recovery on the server side. If for any reason a storage node on our side were to crash, our backups will be there to replace any lost data.

That said, we recommend that you make periodic backups of your site and data to your local computer since we are unable to extract an individual site's data from the nightly backups. If you need a backup of your MySQL or MS SQL databases, they can be exported through our online utilities (MySQL or MS SQL) or by connecting directly to the servers using desktop software.

What does The Rackspace Cloud use for a storage system? Have you done anything there to make it redundant?

Nothing as important as your website should be served from a single hard drive, but you'd be surprised by how many web hosts have little more redundancy than a pair of crossed fingers. We're different - and for good reason.

The advanced architecture powering our hosting solution uses groups of high-performance, network-attached storage devices to reliably serve every web page, image, and email. Inside each storage device, drives are mirrored to each other in a RAID configuration to create a first level of redundancy. And, as a final precautionary measure, all data on the system is automatically backed up on a repeating schedule.

Billing

Is there a referral bonus or any discounts available?

Please visit http://www.rackspace.com/cloud/partners/ for updates on the referral program.

Will there be a discount if I prepay for a full year?

We currently only offer month-to-month billing terms. It's our belief that we have to earn your business every month.

Will I be notified through the system that a bill wasn't collected or that a payment didn't go through?

Yes, Cloud Sites has a billing section that has a historical view of all past invoices and payments. If billing for your account has failed, you will see a message as soon as you log in that there has been an issue billing your account and to contact our billing team.

When am I billed for my account?

Your credit card will first be charged when you sign up for your account. After 30 days have elapsed, you will then be billed for the next month of service. The exact amount may vary as it is based on recurring charges in addition to whatever one-time fees you have incurred during the previous month.

Going forward, you will be billed every month on the anniversary of the date you first signed up for service. If you have any questions about the billing of your account, please call 1-877-934-0410.

What will appear on my credit card invoice?

You should see "Cloud Sites" listed on your credit card statement for any payments made to The Rackspace Cloud.

What forms of payment does The Rackspace Cloud accept?

At this time, The Rackspace Cloud only accepts credit card payments. We allow payment by Visa, MasterCard, or American Express.

Is there a discount if I purchase multiple hosting accounts with The Rackspace Cloud?

No, at this time we do not offer a discount if you purchase multiple accounts... but let's face it: as is, Cloud Sites is already a screaming deal. We won't limit the number of accounts you sign up, so if you need more than one to fit your needs, have at it.

I live outside the United States. Can I use my foreign credit card to pay for my account?

Yes, international credit cards are accepted. The Rackspace Cloud will honor Visa, MasterCard, and American Express.

How do I update my billing information?

To replace a credit card:

  1. Login to your control panel at https://mycloud.rackspace.com.
  2. Open the pull down menu on your account name and click on the "Billing" link.
  3. Click on the "Edit Credit Card" link found on the "Billing Overview" tab.
  4. Complete your credit card information and click the "Finish" button.

To edit your billing information:

  1. Login to your control panel at https://mycloud.rackspace.com.
  2. Open the pull down menu on your account name and click on the "Billing" link.
  3. Click on the "Edit Billing Contact" link found on the "Billing Settings" tab.
  4. Enter in the billing information and click on the "Finish" button.
Am I charged bandwidth for FTPing data to or from my Cloud Sites?

No, FTP bandwidth does not count against your monthly transfer.

How can I cancel my Cloud Sites account?

To cancel your Cloud Sites account, you will need to complete the cancellation form within the control panel.

  1. Log into your control panel at https://manage.rackspacecloud.com.
  2. Click on "Your Account" and then click on "Billing."
  3. On the "Billing Overview" tab click on the "Cancel Account" button in the "Other Options" section.

Linux and PHP

What are the PHP configuration limits for Cloud Sites?

The maximum values for PHP configuration options via .htaccess are:

  • Memory (memory_limit): 512M
  • Upload size (upload_max_filesize): 500M
  • Execution time in seconds (max_execution_time): 30

Note that under some circumstances, PHP may grant an additional 30 seconds to a process that is still executing at the 30 second mark.

Linux Tools

What version of Linux does Cloud Sites run? What about for Windows?

Cloud Sites removed the ability to host disparate technologies due to changes in our technology options. The hybrid technology option removal allows us to release new changes more quickly. For more information, click here.

MySQL

How do I import a large MySQL Database?

You should be able to use the Online Manager (see PHPmyAdmin Database Management Interface) to import databases that are less than 16 MB in size without issue.

However, if you need to import database data that exceeds 16 MB into your Cloud Sites environment, you can use a script which you can schedule via a cron job.

Following is an example to help you set up this script:

#!/bin/sh
mysql -h DB_HOST -u DB_USER -p'DB_PASSWORD' DB_NAME < /path/to/file/db_import.sql
  1. Create a new text file, add the preceding code to it, and save it as restore.sh. In the preceding script, replace the placeholders with your actual information, as follows:
    • pathToFile—This is the absolute path to your files. You can find this path by clicking on Hosting > Cloud Sites > Features in the Cloud Sites Control Panel and scrolling down the page. This path is the Linux Path listed there. An example is /mnt/target02/123456/www.domain.com. (Note that the file name is not included in this path.)
    • databaseHost - The name of the database host. An example is mysql5-9.wc1.
    • databaseUser - The name of the database user.
    • databae_Password - The password of the target database.
    • databaseName - The name of the database to which you are restoring.
  2. Upload this file to your Cloud Site (for security purposes, we recommend keep this file outside your webroot) and create a "perl" cron job to schedule the task (the perl option runs shell scripts as well). For instructions on how to create a cron job, see How_do_I_enable/disable_a_cron_job?.
    Note: For security purposes, we recommend that you keep this file outside your webroot directory.
  3. Put the name of the file, which in this example is import.sh, in the "Command To Run" field.
  4. Select Perl as the Command Language and then select the minimum interval at which you want to run that script (5 minutes is recommended).
    Logs are available in your /logs/ folder each time a cron job is performed and you receive an email confirmation informing you if the job was successful or not.

Note: The cron job has 15 minutes to complete. If the script takes longer than 15 minutes to complete, it will time out. If this is a problem for you please break up the import into smaller pieces (several .sql files) and reschedule the job as necessary.

For more information about cron and related tasks, please see the following articles:

Cron FAQ's:

How do I create a cron job to backup my MySQL database on Cloud Sites?

We suggest using the Scheduled Backup Tool to help schedule backups via cron job.  For more information see Scheduled Backup -- Cloud Sites to Cloud Files.

Advanced users can also set up their own database backups using a shell script running mysqldump via cron.

Security

How do I deny certain IP addresses from accessing my site on Cloud Sites?

Visitors to a Cloud Site come through our load balancers, which means the IP address reported to your site will be that of our load balancers.  We store the visitor's IP address in the X-Cluster-Client-Ip variable to work around this behavior. The value of X-Cluster-Client-Ip can be used when configuring allow and deny rules.

For instructions, see Controlling access to Linux Cloud Sites based on the client IP address.

Web Servers

How do I change the default character set for HTML?

In an .htaccess file placed in the directory you want to have the character set changed on, include the following lines:

AddDefaultCharset ?
# Or AddType 'text/html; charset=?' html
DefaultLanguage en-US

Replace the "?" with the character set required for your site, such as UTF-8.

Note: Cloud Sites has a default character set of UTF-8 if otherwise not specified in .htaccess

How can I do a 301 redirect?

Please note: The following examples are specific to PHP technology and will only work if the Cloud Site is configured to utilize this technology. This will not work for IIS (ASP / ASP.NET).

Please see this article for converting a site from Windows (IIS) to Linux (PHP) technology:

How do I change my site's default technology?

You can also view this article for assistance with rewriting from ASP.NET:

How do I rewrite URLs from ASP.NET?

Redirect examples

Here are some basic 301 redirect examples via the .htaccess text file (please create or upload this file in the folder you want to perform the redirect from).

For example placing the .htaccess file into the /www.domain.com/web/content/ folder (via FTP), will perform the redirect when a visitor goes to http://www.domain.com in their Web Browser.

Redirect a single page:

Redirect 301 /pagename.php http://www.domain.com/pagename.html

Redirect an entire site:

Redirect 301 / http://www.domain.com/

Redirect an entire site to a sub folder

Redirect 301 / http://www.domain.com/subfolder/

Redirect a sub folder to another site

Redirect 301 /subfolder http://www.domain.com/

You can also redirect based on file extensions via the following syntax:

RedirectMatch 301 (.*)\.html$ http://www.domain.com$1.php

This will redirect any file with the .html extension to use the same filename but use the .php extension instead.

Rewrite examples

You can also perform 301 redirects using rewriting via .htaccess.

Here are four examples:

#Redirect from old domain to new domain
RewriteEngine on
RewriteBase /
RewriteRule (.*) http://www.newdomain.com/$1 [R=301,L]
#Redirect to www location
RewriteEngine on
RewriteBase /
RewriteCond %{HTTP_HOST} ^domain.com [NC]
RewriteRule ^(.*)$ http://www.domain.com/$1 [R=301,NC]
#Redirect to www location with subdirectory
RewriteEngine on
RewriteBase /
RewriteCond %{HTTP_HOST} domain.com [NC]
RewriteRule ^(.*)$ http://www.domain.com/directory/index.html [R=301,NC]
# Redirect from www to non-www location
RewriteEngine on
RewriteBase / RewriteCond %{HTTP_HOST} ^www.domain.com [NC] RewriteRule ^(.*)$ http://domain.com/$1 [R=301,L]

Below is a tool that will check your redirect to ensure that it is indeed search engine friendly: http://www.webconfs.com/redirect-check.php

How do I install my own PEAR Module?

You can deploy PEAR modules and other useful scripts locally on your site by modifying PHP's include_path. The default include_path on a Cloud Site is:

.:/usr/share/pear:/usr/share/php

To add another location for PHP to search for modules, just append a directory separator (colon) and the path to your PEAR modules. For example, you might add this to your .htaccess:

php_value include_path ".:/usr/share/pear:/usr/share/php:/mnt/stor1-wc1-dfw1/123456/www.domain.com/web/pear_modules"

You will want to change the path in the example above to use your website's absolute path. Please see this article to locate your website's absolute path.

Your website's absolute path should resemble this:
/mnt/stor1-wc1-dfw1/123456/www.domain.com/web/content

Install the modules

Following the above example, you would login to your FTP and create a directory at the location:
/www.domain.com/web/pear_modules

Then you would place the PEAR modules into this directory.

Use the modules

Now when you reference your modules in your script using a PHP function like include() or require(), the server will know where to look for them!

How do I set up error pages for my PHP site?

You can use an .htaccess file to create custom error pages for your site's defaulted to PHP.

ErrorDocument "code" "location of error document"

For example, with a 404 error:

ErrorDocument 404 /404.html

You can use this directive to create error pages for other error codes as well. You will need to specify the path to the error page relative to the location of the .htaccess file.

http://www.javascriptkit.com/howto/htaccess2.shtml

How Do I Stop PHP Scripts From Executing In A Directory?

In an .htaccess file placed in the directory you want to stop scripts include this line:

removehandler .php

Then simply add the file extensions you wish to stop.

How do I enable directory listing in PHP?

In a .htaccess file, insert the following line:

Options +Indexes

Directory listing is disabled by default on our system

How Do I Change The PHP Memory Limit Value?

Include this line in an .htaccess file in the same directory as the script:

php_value memory_limit ?M

Replace ? with the appropriate megabyte value. Our default size is set to 128MB, and a successful modification of the memory limit will show in your PHP info file. For more information, see How can I view server configuration information for PHP?

For information on PHP configuration option limits, please see this entry in our FAQ.

If you are continuing to encounter issues, please contact support.

How do I change the PHP maximum upload file size?

In an .htaccess file in the same directory as the upload script, include this line:

php_value upload_max_filesize ?M

Replace "?" with the applicable value. Our default size is set to 2MB and a successful modification of the max upload size will show in your PHP info file. See How can I view configuration information for my PHP sites?

If you're running WordPress and continue to have problems after increasing the upload_max_filesize value you can try adding these settings as well:

php_value post_max_size ?M
php_value max_execution_time 200
php_value max_input_time 200

If you are continuing to encounter issues, please contact support.

How can I view any PHP errors?

On a PHP-based site, a blank white screen is usually indicative of a PHP error.  By default, Cloud Sites will store PHP errors under  the /log folder in FTP to a file named “php_errors.log”.

To view the error on the page itself, you can create or edit an .htaccess file in the same directory as the executing script or content, and include these lines:

php_flag display_errors 1
php_value error_reporting 8191

If you continue to encounter issues, please contact support.

How do I change the PHP maximum execution time?

In an .htaccess file in the same directory as the executing script, include this line:

php_value max_execution_time ?

Replace "?" with the with the value you need to replace it with. Our default time is set to 30 seconds and a successful modification of the maximum execution will show in your PHP info file. See How can I view configuration information for my PHP sites?

If you are continuing to encounter issues, please contact support.

How do I change the default character set for PHP?

In an .htaccess file placed in the directory you want to have the character set changed on, include this line:

php_value default_charset ?

Replace the "?" with the character set required for your site, such as ISO-8859-1.

Note: Cloud Sites has a default character set of UTF-8 if otherwise not specified in .htaccess.

How do I change the post max size value?

In an .htaccess file in the same directory as the executing script, include this line:

php_value post_max_size ?M

Replace "?" with the with the required value needed such as 16. Our default post_max_size value is set to 8MBs.

How Do I Prevent Hotlinking on Cloud Sites?

Using the .htaccess file, you can prevent hotlinking--presenting pictures, videos, or other media from one site on another by means for a link--by denying access to specific files based on the domain requesting the file. Hotlinking makes the person who hosts the media pay for the bandwidth to present it, while not getting any of the viewers on her own website. You can deny domains who would hotlink your media by using mod_rewrite, so don't forget to use RewriteBase!

Fully Denying

Below is an example that will only allow .gif, .jpg and .png files to be accessed from www.example.com and example.com:

RewriteEngine on
RewriteBase /
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?example.com/.*$ [NC]
RewriteRule \.(gif|jpg|png)$ - [F]

Using the above example, another website embedding one of your .gif, .jpg or .png images would see a broken image or the alt text specified in the img tag.

Denying With Another Image

If you want to be even more creative, you can even submit a different image to the other website, such as one that reads Stop Hotlinking or Stop Stealing My Bandwidth! Replacing the images with one like that will usually deliver the right message to the offenders and you could even advertise your own site if you make a custom image--though the above example will ultimately save you more bandwidth since it denies the image altogether. Below is an example that will only allow .gif, .jpg and .png files to be accessed from www.example.com and example.com, while serving hotlinking.png to any other websites requesting these files:

RewriteEngine on
RewriteBase /
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?example.com/.*$ [NC]
RewriteCond %{REQUEST_URI} !^/hotlinking.png$ [NC]
RewriteRule \.(gif|jpg|png)$ http://www.example.com/hotlinking.png [R,L]

Using the above example, another website embedding one of your .gif, .jpg or .png images would see hotlinking.png instead.

How Can I Password Protect My Cloud Sites Website?

You can password protect your website, or any of its directories, through basic authentication using a .htaccess file. PHP must be set as the default technology for a site in order to utilize a .htaccess file. If used on a site where ASP is also an enabled technology, please be aware that this will not protect ASP pages.

Create the .htaccess file

This file sets up the requirement for basic authentication and also points to the file containing a list of authorized users.

  • Open a simple text editor, such as Notepad.
  • Insert the following code:
# The name of the area
AuthName "Name of Password Protected Area"
 
# Type of authentication. Always basic
AuthType Basic
 
# Path to .htpasswd file for the site.
# It's preferable to not have this in any
# of the site's content directories.
AuthUserFile /mnt/Target01/[DDI_ID]/[CLIENT_ID]/[WEBSITE_NAME]/.htpasswd
 
# The requirements to view the site. This
# requires that the browser provide
# credentials matching on of the users in
# the .htpasswd file specified above.
Require valid-user
  • Replace the text inside of the quotation marks on the AuthName line to the name of your password protected area (Ex. AuthName "My Password Protected Directory").
  • The text after AuthUserFile must be changed to match your site's server side path to a .htpasswd file we will create soon. To find the server-side path, see How do I find the server-side path for my site?. (Ex. /mnt/Target01/000000/www.mywebsite.com/web/content/.htpasswd).
  • Save the file as "htaccess.txt" and upload it to the directory you want protected.
  • Rename the file to ".htaccess".

Create the .htpasswd file

This file will contain a list of usernames and password sets. Each line should contain one set and the username and password should be separated by a colon

  1. Open a simple text editor, such as Notepad.
  2. Use a .htpasswd encryption tool, such as the one available at http://www.htaccesstools.com/htpasswd-generator/. This will automatically generate the content for the .htpasswd file.
  3. Copy the output of the encryption tool to your text editor.
  4. Save the file as "htpasswd.txt" and upload it to your site to the path you are pointing to in the .htaccess file.
  5. Rename the file to ".htpasswd".

Following these steps will setup basic authentication password protection to the directory indicated. If you are unable to view the .htaccess and .htpasswd files after you renamed them, you will need to configure your FTP client to view hidden files.

Why is mod_rewrite not working on my site?

On Cloud Sites, due to our unique hosting environment, we require a slight addition to the code used for mod_rewrite. You will also need to make sure that the site is using either PHP4 or PHP5 as the default technology.

In the .htaccess file containing your rewrite rules, after RewriteEngine on, add RewriteBase /. Example:

RewriteEngine on
RewriteBase /

Depending on the application, you may need to further specifiy the RewriteBase / to include the subdirectory the application is installed in. For example:

RewriteBase /subdirectory

You can find more information on mod_rewrite at Apache's website.

How do I use a .htaccess file?

For a comprehensive explanation on how to use a .htaccess file and how to create one, please see one or both of the following links:
.htaccess-Guide.com's "How to use .htaccess"
JavascriptKit.com's "Comprehensive guide to .htaccess"

How do I enable Server Side Includes?

You can activate SSI using .htaccess with the following directives:

AddType text/html .shtml
AddHandler server-parsed .shtml
Options Indexes FollowSymLinks Includes

Note: You cannot serve CGI or PHP content using SSI. For this, we recommend using something like PHP's include() or require() or using an inline frame, such as the example below:

<html>
<head></head>
<body>
<iframe src="/cgi-bin/test.cgi"> </iframe>
</body>
</html>

Web Technologies

How can I implement an e-commerce site?

While Cloud Sites is not designed for credit card storage and is not PCI compliant, it can be used as a flexible front-end to a payment gateway.  For more information, see our article on utilizing Cloud Sites in an e-commerce solution.

Windows Tools

What version of Linux does Cloud Sites run? What about for Windows?

Cloud Sites removed the ability to host disparate technologies due to changes in our technology options. The hybrid technology option removal allows us to release new changes more quickly. For more information, click here.