Edward Parrish © 2003     

2. Planning Your Server

What We Will Cover


Log Tails

WebCT

  • Current students added from Wednesday 2/12
  • Any problems?

2.1: Hosting Your Site

Objectives

At the end of the lesson the student will be able to:

  • Determine how to host your site
  • Need to find appropriate host for your site
  • Will review most important options including:
    • Setting up your own Web server
    • Co-located servers
    • Virtual hosts

2.1.1: How are Sites Hosted?

  • Most Web sites accessed through domain names
  • edparrish.com
    google.com
    
  • Browser attempts to resolve domain names into IP addresses
  • 66.70.10.18
    216.239.35.100
    
  • With IP address, client attempts to connect to host over Internet

What's My IP Address?

  • Can determine the address of your computer on the Internet
  • On Linux/UNIX, run the ifconfig program
    • Open a command prompt (e.g. Terminal Emulation in Linux)
    • Make sure you are the super user

    • su -l root
    • Type ifconfig at the command prompt
  • On Windows, run the ipconfig program
    • From the Start menu, select Run
    • Type in command for Win98/ME and cmd for NT/2000/XP
    • At the command prompt, type ipconfig

Internet Service Provider

  • Internet service provider (ISP) provides many services for connecting to the Internet
  • Many people have a dial-up account with an ISP
  • Other ISPs offer all types of connections for individuals and other companies
  • ISP might also provide a hosting service
    • For hosting your Web site on one of their servers
  • Will look at how ISP's are involved in various hosting solutions

2.1.2: Your Own Web Server

To set up your own server, you need:

  • Computer with networking hardware
  • Internet connection with static IP address (provided by ISP)
  • Time for setup and maintenance
  • Domain name (optional, but highly recommended)

2.1.3: Co-Located And Dedicated Servers

Co-located Servers

  • Buy and configure machine but your ISP houses server for you
  • Provides flexibility of having your own machine
  • Do not have to install a network connection to your workplace
  • ISP monitors machine to make sure it’s alive and alerts you if the network goes down
  • You still have to administer equipment

Dedicated Servers

  • Similar to a co-located server except that you rent/lease machine
  • ISP will create user accounts, perform backups, and provide monitoring and reports
  • Allows Web development without becoming system administrator
  • Costs more than a co-located server -- Why?

Resources


2.1.4: Virtual Hosts

  • ISP can set up a machine to host hundreds of Web sites
  • Allows you to have your own domain and is relatively inexpensive
  • Limited to what kinds of programs you can run on the server
  • Sampling of low-cost services:
Name Server Prices/mo.
Brinkster IIS 5 Free to $15.95 or more
CQhost UNIX $14.95
Data Packet Networks IIS 5 $39.99 per year
Hostica Apache $5.00 to $39.50
The Domain Host Apache $7.95 to $55.95
Webmasters.com Apache $9.95

2.1.5: Other Options

  • ISP Personal-Page Site (e.g. AOL personal page)
  • Free-Page Site (e.g. Yahoo! GeoCities)
  • Email Presence (e.g. .name)

Lab Exercise 2.1

Instructions:

  1. Start a text file named exercise2.txt
    Will be adding to this file during the lesson -- save it often.
  2. Prepare the exercise header as described in the HowTo on submitting exercises
  3. Label this exercise: Lab 2.1
  4. Use the next 5 minutes to answer the following questions.
  5. Do not submit exercises until all from today's lesson are finished

Exercise Questions

  1. What options are available to you for putting a Web site on the Internet?
  2. What are the pros and cons of each option?

2.2: Hosting Your Own Server

Objectives

  • Describe what is required to put a server on the internet
  • In this course we will set up our own servers in the classroom (Lesson 4)
  • However, won't be connected to the Internet -- Why not?
  • Some good reasons to set up your own server:
    • Start your own hosting company
    • Have large site that needs constant maintenance
    • You want complete control over your site
    • You just want to try it for the fun of it!
    • Your instructor told you to...
  • To set up your own server, just need:
    • Computer with networking hardware
    • Internet connection with static IP address
    • Time for setup and maintenance
    • Domain name (optional but highly recommended)

2.2.1: What’s It Used For?

  • In addition to Web Server, may offer following services:
    • E-mail
    • FTP
    • Secure Server
    • Web Access
  • Usage affects hardware and bandwidth requirements

2.2.2: Getting Connected

  • Modem is fine for experimental or personal server without many graphics
  • ISDN (Integrated Services Digital Network) offers speeds to 128K
  • DSL (Digital Subscriber Line): downstream = 384Kbps - 1.5Mbps / upstream = 128Kbps
  • T-1 (DS1: Digital Signal Level 1): 1.544Mbps
  • IMA (Inverse Mutiplexing over ATM): 3Mbps
  • T-3 (DS3: Digital Signal Level 3): 44.736Mbps
  • OC-3c (Optical Carrier Level 3): 50Mbps - 148Mbps
Name Bandwidth Installation Prices/mo. *
56K Modem 56Kbps $0 $10 - $25
ISDN 128Kbps $200 - $400 $40+
DSL 384Kbps - 1.5Mbps / 128Kbps $0 - $250 $35+
Higher Speeds 1.544Mbps - 148Mbps $1200 - $3000 $750 - $7000

* Static IP addressing (required for servers) extra


2.2.3: Networking

  • Internet is one huge network
  • Many government agencies and commercial business provide backbone services
  • Can see a visualization of the Internet backbones at Mapnet
  • ISPs provide connection to network
  • Must have static IP address to reliably receive client requests
  • Search Google for ISPs offering static IP addresses in Santa Cruz area

2.2.4: Server Hardware

  • Most any recent computer will do for basic server
  • Popular sites with large hit rates will need better equipment
  • Running many server-side services will also require better equipment
  • Need UPS (Uninterruptible Power Supply) to protect equipment
  • Need network equipment compatible with ISP
  • Extra RAM almost always helps performance

Lab Exercise 2.2

Instructions:

  1. Label this exercise: Lab 2.2
  2. Use the next 5 minutes to answer the following questions.
  3. Do not submit exercises until all of them from today's lesson are finished

Exercise Questions

  1. What is required to put a server on the Internet?
  2. Why is an ISP necessary to host your site?

Quiz

The Quiz/Exercise is open book, open notes and screen on. It is NOT open neighbor's books, notes, computer or quiz.

You may use your computer to work out the problems

You have 15 minutes to complete the test.

The link to WebCT is here.

Quiz Tips

  • Study before the quiz: review lesson notes and the textbook
  • If you get stuck on a question, make your best guess and return later
  • Save after every answer. You can always return and change your mind.
  • Try Site Search to find facts
  • If you are equally uncertain between two choices, go with first impression
  • Use the full time available
  • Remember that the time remaining is from the last time you saved an answer. If you have not saved an answer recently, the time remaining is wrong! You can press refresh/reload (or F5 in IE) to update the time remaining.
  • More quiz tips: Basic Rules For Taking a Multiple-Choice Test

2.3: UNIX vs. XP

Objectives

  • Describe the major differences between Windows NT/2000/XP and Unix
  • Determine which operating system best fits your needs
  • Operating system (OS) manages all the functions of a computer
  • Your operating system determines which applications you can run
  • Operating system may affect your choice of Web server since not all servers run on all OS's
  • We will review:
  • Will also consider security issues

2.3.1: UNIX

  • UNIX created by AT&T Bell Laboratories in the late 1960s
  • Good networking since TCP/IP built into OS
  • Designed to be multiuser and multitasking -- Why is this desirable?
  • Since UNIX has been around for so long, has been well tested
  • Many popular brands: Sun’s Solaris, IBM AIX, HP-UX, SGI IRIX, FreeBSD, Open UNIX and Linux
  • Many of these brands run on PCs

2.3.2: Linux

  • Created in the early 1990s by Linus Torvalds
  • Runs on PCs and other platforms
  • Source code for Linux is freely available
  • Is Linux as stable as other UNIX versions?
  • Sun also supports Linux

2.3.3: Windows XP

  • Proprietary OS sold by Microsoft
  • Most system administration tasks are done through a point-and-click interface
  • Needs significant amounts of RAM to run well, but almost any recent PC will work fine
  • What is your opinion of activation?

Further Information


2.3.4: Security

  • Any machine on the Internet is vulnerable to attack by crackers
  • Any server accessible on the Internet must be concerned about security
  • UNIX security has been put to the test more often than Windows
  • Bill Gates recently sent letter to all Microsoft employees on "Trustworthy Computing"
  • Does having the source code of OS available help or hinder security?

Lab Exercise 2.3

Instructions:

  1. Label this exercise: Lab 2.3
  2. Use the next 5 minutes to answer the following questions.
  3. Do not submit exercises until all of them from today's lesson are finished

Exercise Questions

  1. What are the pros and cons of UNIX and XP?
  2. How do you evaluate an operating system for your Web server?

2.4: Sizing Your Server

Objectives

  • Determine size and bandwidth requirements for your server
  • Describe how to spot and resolve performance problems
  • Will look at simple method for estimating bandwidth requirements

2.4.1: Bandwidth and Network Capacity

  • Bandwidth is used to describe capacity or speed of a network
  • Need to make sure your server has large enough network capacity to service clients
  • Examine log files to determine how many people visiting your site
  • Each page that is requested counts as a "hit" or http operation (httpop)
  • Want to determine number of operations per second (httpops/sec) as follows:
    1. Determine the number of lines in your log file.
    2. Determine how many days that log file has been in use (look at the timestamp of first and last entries).
    3. Divide the number of lines by the number of days; this gives you the number of operations per day.
    4. Divide the number of operations per day by 86,400 (number of seconds in a day).
    5. This gives you the number of operations per second.
  • For example
    1. You count roughly 15,000 hits in your log files
    2. This occurred over 30 day period
    3. Dividing #hits / #days = 15000 hits / 30 days = 500 hits/day
    4. Divide (#hits/day) / 86400 seconds = 500 hits/day / 86400 seconds
    5. Roughly 0.006 httpop/second
  • Need about 3 times average for peak loads = 0.006 x 3 = 0.018 peak httpop/second
  • Since 1 httpop/sec equal to roughly 128 Kbps, can create following table
  • Network Connection Peak httpops/sec
    56K Modem 0.5
    T1 (DS1) 10
    T3 (DS3) 300
    OC3 900

  • Look up network requirements in table to support peak httpop/second
  • What is the appropriate network connection for this example?

2.4.2: Server Performance

  • Network connection to Internet is often bottleneck for Web server
  • Even a small, inexpensive machine can keep up with a large number of hits
  • Transferring Web page or image isn’t computationally intense process
  • Turns out that size and type of files being transferred not large factor
  • Number of transactions is more important
  • Viewing page with three images requires four separate connections
    • One for the initial HTML page
    • Three more for the images
  • Moderately fast computer can easily support millions of hits per day
  • Server-side programs will slow the server considerably
  • Programs that run in browser have little effect: Flash, Applets, etc

Lab Exercise 2.4

Instructions:

  1. Label this exercise: Lab 2.4
  2. Use the next 5 minutes to answer the following questions.
  3. Do not submit exercises until all of them from today's lesson are finished

Exercise Questions

  1. How can you approximate bandwidth requirements for your server?
  2. What can be done to improve performance if a server is running at capacity?

2.5: Domain Names

Objectives

  • Register a domain

2.5.1: What’s in a Domain Name?

  • Having your own domain name is one key to having a good site
  • Domain name easier to understand and remember than string of numbers
  • google.com
        vs.
    216.239.35.100
    
  • Most common to name your Web server machine www
  • If domain name is edparrish.com then full address would be www.edparrish.com
  • To have domain name of your own, you must register a domain
  • Registration is easy and many ISP's will do it for you -- why do they bother?

Top-Level Domains

  • Domain names fall into one of the top-level domains (TLDs)
  • Number of TLDs available
  • May have limited choice due to domain name rules
  • Some of the most popular TLDs:
.com
Commercial domains, used by most for-profit companies
.org
Mostly nonprofit organizations
.net
Usually ISPs and other companies that support networks
.edu
Educational institutions, mostly universities
.gov
U.S. federal government organizations
.mil
U.S. military organizations
  • Domain names also organiaed by location (i.e. country)
.us
United States: mainly for local and state gavernments and schools
www.cabrillo.cc.ca.us
.au
Australia
.ca
Canada
.jp
Japan
.sw
Sweden
.uk
United Kingdom
  • What is the .tv TLD used for?
  • How many one or two letter domain names do you know about? (q, x, z)
  • Why are so few single letter domains in use?

2.5.2: Registering a Domain

  • Domain names are available on a first-come, first-served basis
  • To register a domain, you will need:
    • A domain name that hasn’t already been registered
    • A valid e-mail address
    • Names and addresses of your primary and secondary DNS servers
    • A credit card (if you want to pay online)
  • Should have your ISP service set up before registering a domain
    • Need to supply names and addresses of DNS servers during registration
  • Can get free DNS service at Granite Canyon Group
  • Can check availablity of names and register domains at Register.com
  • Pricing at Register.com and Dotster
  • InterNic maintains list of Accredited Registrar's.

2.5.3: Maintaining your Domain

  • Once you register, ISP must add your domain and IP addresses to their name servers
  • Must also renew your domain when term is up
  • May be additional charges to move domain names and other maintenance tasks

Further Information


Lab Exercise 2.5

Instructions:

  1. Label this exercise: Lab 2.5
  2. Use the next 10 minutes to answer the following questions.
  3. Do not submit exercises until all of them from today's lesson are finished

Exercise Questions

  1. What is required to register a domain?
  2. If you change ISPs, how does that affect your domain?

Wrap Up

  • When class is over, please shut down your computer
    Main Menu => Logout => Shut Down
  • Due Next: N/A

  • You may complete unfinished exercises at any time before the next class.
  • Be sure to submit the file to the instructor before the beginning of the next class to receive credit.
  • Instructions on submitting exercises are available from the HowTo's page.

Home | WebCT | Announcements | Schedule | Expectations | Syllabus
| Help | FAQ's | HowTo's | Links

Last Updated: 7/16/2003 4:45:33 PM