0% found this document useful (0 votes)
45 views40 pages

Web Servers

This document provides an overview of the Apache Tomcat web server. It discusses that Tomcat is an open source web application container developed by the Apache Software Foundation that executes Java Servlets and renders JavaServer Pages. Key points covered include that Tomcat implements the Java Servlet and JavaServer Pages specifications from Oracle, and is commonly used as a web server to host Java web applications. Alternative web servers to Tomcat like Sun's Java Web Server and JBoss are also briefly mentioned.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
45 views40 pages

Web Servers

This document provides an overview of the Apache Tomcat web server. It discusses that Tomcat is an open source web application container developed by the Apache Software Foundation that executes Java Servlets and renders JavaServer Pages. Key points covered include that Tomcat implements the Java Servlet and JavaServer Pages specifications from Oracle, and is commonly used as a web server to host Java web applications. Alternative web servers to Tomcat like Sun's Java Web Server and JBoss are also briefly mentioned.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 40

An In-Depth Look into Web

Application Administration

Web Servers

Shashikant S Kulkarni

1
Introduction
 Web server
 Responds to client requests by providing resources
 Web server and client communicate with platform-
independent Hypertext Transfer Protocol (HTTP)

2
Web server architecture

3
How the WWW Works

(Fitzgerald and Dennis, 2005 Figure 2.8)

4
Domain
Name
Server
System

5
HTTP Request Types
 GET (default) and POST do basically the same thing:
Send data from the client to the server. However, they
have some differences:
 GET
 Appends form data directly to the end of the URL—visible to users
(not suitable for sending passwords)
 Limited to 2,048 characters for the entire URL
 Result page can be bookmarked and cached
 POST
 Sends form data in the HTTP request—invisible to users
 Virtually no limit (but check your specific configuration)
 Results are not cacheable or bookmarkable

6
System Architecture
 Multi-tier application (n-tier application)
 Information tier (data or bottom tier)
 Maintains data for the application
 Stores data in a relational database management system
(RDBMS)
 Middle tier
 Implements business logic and presentation logic
 Control interactions between application clients and application
data
 Client tier (top tier)
 Application’s user interface
 Users interact directly with the application through the client tier

7
N-tier Client-Server Architecture

8 (Fitzgerald and Dennis, 2005 Figure 2.5)


Client-Side Scripting versus Server-
Side Scripting
 Client-side scripts
 Validate user input
 Reduce requests needed to be passed to server
 Access browser
 Enhance Web pages with DHTML, ActiveX controls, and applets
 Server-side scripts
 Executed on server
 Generate custom response for clients
 Wide range of programmatic capabilities
 Access to server-side software that extends server
functionality

9
Installing a web server

10
Hosting a website:
Self hosting
 Install a web server on a computer
 Local access
 Using domain <localhost>
 or IP address 127.0.0.1
 Necessary for server-side programming development
 Global access
 Register a human-readable domain name
 Obtain IP address
 Static: Costs more
 Dynamic: Needs dynamic DNS system, e.g.
http://www.dyndns.com/

11
Hosting a website:
Hosting service
 Register a domain name
 Assign name servers
 Host takes care of IP addressing
 Develop website locally
 Upload website via FTP for global access
 E.g. Filezilla

12
Web server architecture
 LAMP: Most popular—fully open source
 Linux for operating system
 Apache for web server
 MySQL for database
 PHP for server-side scripting
 Others:
 WAMP: Uses Windows for operating system, with
Apache, MySQL, and PHP
 WISA: Full Microsoft package
 Windows
 Internet Information Server (IIS)
 SQL Server (enterprise) or Access (small-scale)
 ASP or ASP.NET

13
Apache Web Server
 Currently the most popular Web server
 Stability
 Efficiency
 Portability
 Open-source

14
All-in-one Apache/MySQL/PHP packages
 EasyPHP
 Includes PHPMyAdmin for administering MySQL
database
 Installation and configuration
 WAMP Server (recommended)

15
IIS Technologies
Introduction
 Designed to deliver high speed and secure information
publishing

 Serves as a platform for developers to extend internet


standard communication capabilities

 Runs as a Windows NT 4.0 (Option Pack) service


IIS Components
 Full Scale publishing includes following
components
 Transport Services
 Client applications
 Administrative Tools
 Database Connectivity
 Encrypted Communication
IIS 4.0 Components
 Purpose  Component
 Hypertext Publishing  WWW Server
 File Transfer  FTP Server
 ODBC Gateway  Internet D/Base Con.
 Encrypted Comm.  Secure Socket Layer
 Server Admn.  Internet Service Mgr.
 Hypertext Clients  Browsers
Web Site Content
 HTML Pages
 HTML Code
 Client Side Scripts
 Active Server Pages (ASPs)
 HTML Code
 Client & Server Side Scripts
 Components
Web Content Creation Tools
 Hypertext Text Markup Language (HTML),
Dynamic HTML

 Scripting Languages
 JavaScript, Jscript and VBScript

 Component Creation Languages


 Visual Basic, Java, VisualC++, VisualJ++ etc.
Content Authoring & Management
Environment
 FrontPage
 InterDev6.0
 IIS Application (VB6.0 Feature)
 HTML Editors
IIS Application
 An IIS (Internet Information Server) application is
a Visual Basic application that lives on a Web
server and responds to requests from the
browser

 An IIS application uses HTML to present its user


interface and uses compiled Visual Basic code to
process requests and respond to events in the
browser
IIS Application
 To the user, an IIS application appears to be
made up of a series of HTML pages

 To the developer, an IIS application is made up


of a special type of object called a webclass, that
in turn contains a series of resources called
webitems
Browser-IIS Interaction
 Browser sends an HTTP request to the IIS for a
page on the web server

 The web server gets the requested page and


processes the server side scripts, (which are
enclosed within delimiters “<%” and “%>). The
scripts can assign values to variables or request
information from server (interaction with other
tiers)
Browser-IIS Interaction
 The processed page containing only HTML and
client-side scripts, if any, is sent to the browser
WAMP
What is WAMP?

 WAMP = Windows+Apache+MySql+PHP

Note:WAMP5 does not work with Windows 98,Me


WAMP Installation

 A single installation file downloaded from


http://www.wampserver.com/en/download.php
After Installation
Application Service
 Apache
wampapache
 PHP
 MySQL database
wampmysql
WAMP’s Menu

Management Portals
 PHPmyadmin
 SQLitemanager

Note: A user has to click


on the icon tray to access
WAMP's menu.
WAMP’s Menu

 Configuration and
Settings
 Loaded Modules
 Directory Access
Shortcut
WAMP’s Menu

Services
 Apache
 MySQL

Note:
The icon tray
reflects the status
of your server.
Overall
 WAMP is easy to install and it is free to use.
 Migration from IIS/PHP/MsSQL to WAMP is
practical.
 The cost of migration is mainly to review queries and
change them based on the SQL extension of
MySQL.
Apache Tomcat

35
The Apache Jakarta Project
 The Apache Jakarta Project “creates and
maintains open source solutions on the Java
platform for distribution to the public at no
charge”
 Apache Jakarta Tomcat--or just “Tomcat”--is one
of those projects
 Tomcat is a container for Servlets
 Tomcat can act as a simple standalone server for Web
applications that use HTML, Servlets, and JSP
 Apache is an industrial-strength, highly optimized
server that can be extended with Tomcat
36
Web apps
 A web application is basically a web site that:
 “Knows who you are”--it doesn’t just give you static pages, it
interacts with you
 Can permanently change data (such as in a database)
 A web application can consist of multiple pieces
 Static web pages (possibly containing forms)
 Servlets
 JSP
 Tomcat organizes all these parts into a single directory
structure for each web application
 ...but you have to help with the organization

37
What is Apache Tomcat?
 Apache is the most common HTTP Web Server on the
Internet.
 The Tomcat server is a Java-based Web Application
container which is used to run Servlet and Java Server
Pages (JSP) Web applications.
 Tomcat has become the reference implementation for
both the Java Servlets and Java Server Pages
specifications.
 Tomcat was chosen to be the official Sun Web
Component (JSP/Servlet ) Container Reference
Implementation.

38
What is Apache Tomcat? [Contd.]
 Apache Tomcat is used to serve Java Servlets and Java
Server Pages. It's a complex piece of software and
though the documentation is very comprehensive, it
helps to have a good reference work to hand.
 It is an open source Java Servlet application server used
to deploy Java applications after they are built with JSP
and Servlets. It can be used as a stand-alone product or
it can be integrated with the Apache server.

39
Alternatives to Tomcat
 Sun’s Java Web Server
 Old, no longer being developed, all in Java
 Java Web Server Development Kit (JWSDK)
 Official reference implementation
 Difficult to install and configure
 JBoss
 Open source
 Opinions vary on how easy it is to install
 Comes with built-in database

40

You might also like