Saturday, June 21, 2014

How to Configure a WebServer in Linux

10:00 AM

Red Hat® Certified Engineer (RHCE®) is a Red Hat Certified System Administrator (RHCSA) who possesses additional skills, knowledge, and abilities required of a senior system administrator responsible for Red Hat Enterprise Linux® systems.

An RHCE is capable of:

    Configuring static routes, packet filtering, and network address translation.
    Setting kernel runtime parameters.
    Configuring an Internet Small Computer System Interface (iSCSI) initiator.
    Producing and delivering reports on system utilization.
    Using shell scripting to automate system maintenance tasks.
    Configuring system logging, including remote logging.
    Configuring a system to provide networking services, including HTTP/HTTPS, File Transfer        Protocol(FTP), network file system (NFS), server message block (SMB), Simple Mail Transfer Protocol (SMTP), secure shell (SSH) and Network Time Protocol (NTP).







Implement a webserver


CMD:

Install web server packages using yum command


root@linuxstorages:~#yum install httpd* -y


Configure the web server configuration in below path


root@linuxstorages:~#vim /etc/httpd/conf/httpd.conf




Copy the last 7 line and paste in last. Then change all dummy into your hostname

Change document root is /var/www/html

:wq!   
 Change directory to document root of web server


root@linuxstorages:~#cd /var/www/html

Connect FTP server using lftp command 


root@linuxstorages:~#lftp server id

>cd /var/www/ftp

>get data.html
>bye

get - download file from server to local

bye - exit ftp server connection

Rename data.html to index.html


root@linuxstorages:~#mv data.html index.html

Enter ip address details in host file


root@linuxstorages:~#vim /etc/hosts

Add   ipaddress    hostname(fully)        hostname(half)
               
xx.xx.xx.xx    user.linuxstorages.com   user.linuxstorages

:wq!

Check status of web server configuration file after configuring


         root@linuxstorages:~#httpd -t
         syntax ok

        root@linuxstorages:~#service httpd restart

        root@linuxstorages:~#chkconfig httpd on

Check the URL using elinks command in terminal


root@linuxstorages:~#elinks user.linuxstorages.com

Written by

0 comments :

Post a Comment

 

© 2014 Linux Storages | Updated . All rights resevered. Designed by Templateism