How to configure Apache Web Server in RedHat Linux
hello guys today we will learn how to configure Apache web Server in Linux redhat and also host web page with Apache web server. We will also understand concept of web server that how to host any website in Redhat Linux server. So before you need to Configure YUM server in our Linux machine. if you don’t know how to configure yum in linux so click on link and look . After YUM server configuration we can install any package in Linux very easily
Step 1 here i accept you configure Yum in your Linux machine so fist we will install Http package
[root@localhost ~]# yum install http*Step 2 then we off our Linux machine IP Address and also Disable Firewall and seLinux through below Commands
[root@localhost ~]# ifconfig eth0 Link encap:Ethernet HWaddr 08:00:27:93:6D:E8 inet addr:192.168.56.101 Bcast:192.168.56.255 Mask:255.255.255.0 inet6 addr: fe80::a00:27ff:fe93:6de8/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:227 errors:0 dropped:0 overruns:0 frame:0 TX packets:197 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:20134 (19.6 KiB) TX bytes:25158 (24.5 KiB)
Here my ip address is 192.168.56.101
[root@localhost ~]# iptables -F
[root@localhost ~]# setenforce 0Step 3 then we will Start httpd Service and go to any browser Url bar and put our Linux machine ip Address
[root@localhost ~]# service httpd restart Stopping httpd: [ OK ] Starting httpd: [ OK ]
then we will look Apache web server description and instruction here


Step 2 now we will go our Linux terminal and put below commands
[root@localhost ~]# cd /var/www/html
[root@localhost html]#Step3 here this directory in we will create simple Html page
for example here i create index.html file
[root@localhost html]# vim index.html <html> <head> demo</head> <title> Demo index File</title> <body> <h1> This is Apache web Server Demo </h1> <h2> you can found linux server all configureation in visworlditsolution.com</h2> <marqoee><h2> visworlditsolution.com is a very help full website in it fields</h2></marqoee>\ </body> </html> ~ ~ ~ :wq
Step4 then we will go to Apache man configuration file and do something configure like this
[root@localhost html]# vim /etc/httpd/conf/httpd.conf979 # 980 # VirtualHost example: 981 # Almost any Apache directive may go into a VirtualHost container. 982 # The first VirtualHost section is used for requests without a known 983 # server name. 984 # 985 #<VirtualHost *:80> 986 # ServerAdmin webmaster@dummy-host.example.com 987 # DocumentRoot /www/docs/dummy-host.example.com 988 # ServerName dummy-host.example.com 989 # ErrorLog logs/dummy-host.example.com-error_log 990 # CustomLog logs/dummy-host.example.com-access_log common 991 #</VirtualHost> 992 <virtualHost 192.168.56.101:80> 993 DocumentRoot /var/www/html/ 994 Directoryindex index.html 995 </VirtualHost> :wq
Step5- we will restart httpd servies
[root@localhost html]# service httpd restart Stopping httpd: [ OK ] Starting httpd: [Thu Jan 19 05:05:47 2017] [error] (EAI 2)Name or service not known: Failed to resolve server name for 192.168.56.101 (check DNS) -- or specify an explicit ServerName [ OK ] [root@localhost html]#
also check httpd below commands
[root@localhost html]# httpd -tthen we will on httpd server below commands
chkconfig httpd onStep 6 now go to internet browser and type your linux machine ip address

Its a very simple process .if you have any problem in this process so please comments here i will solve your problem if you like my tutorial so follow my website like ,share,
Thank you
by Vishnu Sharma

WOW just what I was searching for. Came here by searching for
web hosting 5 years