Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chapter 1 Web Server Setup and Configuration. Contents A.What is web server B.Installing and Configuring Web Server C.Testing the Installation.

Similar presentations


Presentation on theme: "Chapter 1 Web Server Setup and Configuration. Contents A.What is web server B.Installing and Configuring Web Server C.Testing the Installation."— Presentation transcript:

1 Chapter 1 Web Server Setup and Configuration

2 Contents A.What is web server B.Installing and Configuring Web Server C.Testing the Installation

3 A. What is the web server The most common use of web servers is to host website, but there are other uses such as gaming, data storage, running enterprise applications, handling email, FTP, or other web uses.gamingenterprise applicationsemailFTP The primary function of a web server is to store, process and deliver web pages to clientsweb pagesclients A user agent, commonly a web browser or web crawler, initiates communication by making a request for a specific resource using HTTP and the server responds with the content of that resource or an error message if unable to do so.user agentweb browserweb crawlerrequesterror message

4 A. What is the web server The communication between client and server takes place using the Hypertext Transfer Protocol (HTTP)Hypertext Transfer Protocol (HTTP) Pages delivered are most frequently HTML documents, which may include images, style sheets and scripts in addition to text content. HTML documents imagesstyle sheetsscripts

5 Architecture

6 Some of popular web server Apache Tomcat Apache HTTP Server Microsoft IIS Server IMB Lotus Server Lighttpd Macromedia JRun, and Caucho Resin

7 B. Installing and Configuring Web Server 1.Installing Java 2.Installing Tomcat Web Server 3.Configuring Tomcat

8 1. Installing Java  Download JDK at http://www.oracle.com/technetwork/java/ja vase/downloads/index.html and run it

9 2. Installing Tomcat Web Server Download tomcat Web Server at http://tomcat.apache.org/download-80.cgi and run it http://tomcat.apache.org/download-80.cgi Destination folder: C:\Program Files\Apache Software Foundation\Tomcat 8.0 (TOMCAT_DIR)

10

11 http://localhost:7777 Port number: 7777

12 3. Configuring Tomcat Configuration file: TOMCAT_DIR/conf/server.xml 3.1. Specifying Server Port 3.2. Hosting a website 3.3. Manage tomcat user 3.4. Deploy war file

13 3.1. Specifying Server Port Change port from 7777 to 7878

14 3.2 Hosting web site

15 3.3. Manage tomcat user Open the configuration file TOMCAT_DIR/conf/tomcat-users.xml

16 3.4 Deploy web application (war file)

17 B. Testing the Installation 1. Starting Netbean IDE 8.0 2. Create Web Application project “HelloTomcatApp” for testing: 2.1 Testing HTML 2.2 Testing JSP 2.3 Testing Servlet

18 1. Starting NetBean 8.0

19 2.1 Testing HTML Create hello.html to testing tomcat web server with html file

20 Using Firefox browser to access to hello.html

21 2.2. Testing JSP Create helloJSP.jsp in the “Web Pages” location to test JSP format

22 Using Firefox browser to access to helloJSP.jsp

23 2.3 Testing Servlet Create HelloServlet.java in the “Source Packages” location to test Servlet format

24 Running HelloServlet Using Firefox browser to access to helloServlet

25 References 1.Core Servlets And Java Server Pages, Volume 1, 2 nd Edition, Chapter 02.

26 Revision History


Download ppt "Chapter 1 Web Server Setup and Configuration. Contents A.What is web server B.Installing and Configuring Web Server C.Testing the Installation."

Similar presentations


Ads by Google