Migration to Web Farm 2 from NMIA Web Server

From SWCP Support Wiki
Jump to navigationJump to search

Migrating Your Website to the New Southwest Cyberport Webfarm

Purpose

  • Describe how to test your current site on the new Webfarm
  • Encourage thorough testing of sites moving to the new Southwest Cyberport Webfarm
  • List the upgraded software packages
  • Provide a few suggestions to avoid common pitfalls.
  • Encourage thorough testing. Really. You won't regret doing it. You will probably regret not doing it.

Testing Your Site

What to test

We cannot stress enough the importance of testing your site on the new webfarm. Do not just verify that your home page loads. Here is a partial list of behavior that should receive close scrutiny:

  • Form submissions
    • Make sure your customers can reach you!
  • Dynamic content generated by:
    • PHP code
    • CGI scripts
    • Apache Server Side Includes
    • Javascript
  • Redirection (best used sparingly):
    • .htaccess, PHP, META tags, CGI, Javascript, etc.

Beware any hard-coded links (like <a href="http://www.YourDomain.com/otherfile.html">) - those will go to the current server, rather than the new one.

Where to test

In most cases, we want to add the subdomain 'test' so that:

www.YourDomain.com => your site, via the NMIA Web Server
test.YourDomain.com => your site, via the new webfarm
  • If we control DNS for your domain:
    • We have already created the URL 'test.YourDomain.com' - use this URL to test your current site on the new webfarm. Let us know if this URL doesn't work.
    • When you're finished testing your site, send us an email instructing us to fully migrate your site to the new webfarm.
    • Test your site again, using 'www.YourDomain.com' rather than the test URL.
  • If we do not control DNS for your domain:
Be careful when changing DNS entries for your domain.
Invalid DNS entries will make it impossible to reach your site.
These steps may not work for domains with multiple subdomains or other non-trivial DNS records
  • For testing, we have created a URL for you to use that is similar to this:
test-yourdomain.swcp.com.
  • Once you are finished testing, update all relevant A records to point to 216.184.2.32.

The files you are testing

The test URL points at exactly the same files as your main, live site. You do not need to upload anything. Anything that you want to change can be changed through your normal file upload method (FTP), but be aware that this will also change your live site. If this presents a problem and you need to work on a copy of your web site, let us know and we will set that up.

Hosting Environment Changes

  IP Address PHP
Version
suPHP
Available?
Apache
Version
Supports
SSL?
Current Server 64.42.128.55  or
64.42.142.0/22
4.4 No 1.3 No
New Webfarm 216.184.2.32 5.2 Yes 2.2 Yes


PHP Notes

  • SuPHP
    • The SWCP Web Farm enables SuPHP by default. While we can disable it for your site upon request, we strongly encourage you to take advantage of this security enhancement.
    • The transition to SuPHP may require a one-time file permissions change for files that were created by Apache on the current server.
  • Register Globals
    • Register Globals is now disabled by default. We can enable it for your site at your request.
    • We strongly encourage our customers using Register Globals to consider refactoring their code at this time. Register Globals is deprecated and will be removed from PHP 6.
    • Questions? Please read PHP.net's thorough description of Register Globals.

CGI Notes

CGI changes are probably the most significant, with the greatest potential for confusion.

  • cgiwrap
    • Your cgiwrap scripts will not work if you reference them using 'www.nmia.com.' For example, this form would not submit to the new Web Farm:
      • <form action="http://www.nmia.com/cgi-bin/cgiwrap/Username/SomeScript.pl"...
    • Your cgiwrap scripts will work if you used relative URL's or your domain name. Both of these forms would submit as desired:
      • <form action="/cgi-bin/cgiwrap/Username/SomeScript.pl"...
      • <form action="http://www.YourDomain.com/cgi-bin/cgiwrap/Username/SomeScript.pl"...
    • Gory details for those who care:
      • The Web Farm uses suEXEC rather than cgiwrap. We emulate the behavior of cgiwrap by adding an Apache ScriptAlias for your virtual:
        • Name=/cgi-bin/cgiwrap/Username/ Path=/users/Username/public_html/cgi-bin/
        • If you're changing your code anyway, we can change this ScriptAlias something a little nicer. Just let us know.
  • formmail

Apache Notes

  • .htaccess files
    • Though most .htaccess behavior will not be affected, all sites with .htaccess files should be tested.
    • The directive +FollowSymLinks needs to be changed to +SymLinksIfOwnerMatch
    • The directive Options All worked on the old system but will cause an error on the new system.

Web Hits Reports

  • Web Trends
    • We will be replacing the Web Trends log analysis report with Webalizer.