Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic...

21
Web Server [email protected]

description

Content Web Server installation ◦ Web Server Structure Web Server configuration ◦ Virtual Web hosting ◦ Server Side Include ◦ Comment Gateway Interface ◦ CGI VS FastCGI Question & Answer

Transcript of Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic...

Page 2: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Content What is web server Web Server working concept

◦Static document◦Dynamic document◦Client side Processing

Easy Web Server Programing

Page 3: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

ContentWeb Server installation

◦ Web Server StructureWeb Server configuration

◦ Virtual Web hosting◦ Server Side Include◦ Comment Gateway Interface◦ CGI VS FastCGI

Question & Answer

Page 4: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

What is Web Server

Page 5: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

History of web server 1989 Tim Berners-Lee employee of CERN (European Organization for Nuclear Research) Work on HTTP (Hypertext Transfer Protocol)

◦ HTTP V 0.9 (1991)◦ HTTP WG 1995◦ HTTP V 1.1 (1996) RFC 1945◦ HTTP V 1.1 (1999) RFC 2616

Page 6: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Web Server Working Concept Client – Server Network Concept Resource Type On Server

◦Static document◦Dynamic document

Client side Processing

Page 7: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Static Document Resource

Page 8: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Dynamic Document Resource

Page 9: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Client Processing

Page 10: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Popular Web Server Apache Web Server Microsoft Internet Information Services Nginx (engine-x)

Page 11: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

All Web Server Market Share from NetCraft

Page 12: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Active Web Server Market Share from NetCraft

Page 13: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Active Web Server 2014 -2015 from NetCraft

Page 14: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Easy Web Server Programming with Node.js

var http = require('http'); http.createServer(function (req, res) { res.writeHead(200, {'Content-Type': 'text/plain'}); res.end('Hello World\n'); }).listen(1337, '127.0.0.1'); console.log('Server running at http://127.0.0.1:1337/');

node example.js

Page 15: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

How to Apache Web Server Installation Web Server Only # yum install httpd

Web Server with php # yum install httpd php php-common

Page 16: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Configuration VirtualHost NameVirtualHost *:80 <VirtualHost *:80> DocumentRoot /www/docs/www.web1.com ServerName www.web1.com </VirtualHost> <VirtualHost *:80> DocumentRoot /www/docs/www.web2.com ServerName www.web2.com DirectoryIndex index.htm </VirtualHost>

Page 17: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.
Page 18: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.
Page 19: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Perl CGI Test # yum install perl # vi /var/www/cgi-bin/echo.pl #!/usr/bin/perl use strict; use warnings; print qq(Content-type: text/plain\n\n); print ”Hello CGI\n";

Page 20: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

Question & Answer

Page 21: Web Server Content What is web server Web Server working concept ◦ Static document ◦ Dynamic document ◦ Client side Processing Easy.

LAB 03 Install Apache Web Server with PHP Programming Hello World CGI Create Virtual Web Hosting And index.html◦www.mysite-57160000.com◦www.yoursite-57160000.com