1
00:00:00,300 --> 00:00:07,560
Now, let us go to our master system and modify this httpd.config file according to the way we

2
00:00:07,560 --> 00:00:08,210
have discussed.

3
00:00:08,790 --> 00:00:17,410
So we will go to our system, on master system and we are going to open that configuration file 

4
00:00:17,550 --> 00:00:19,080
httpd.conf.

5
00:00:23,240 --> 00:00:29,710
We are going to open this file, we will go to the end, and here we are going to make changes.

6
00:00:30,200 --> 00:00:33,590
So this NameVirtualHost, this line is not required.

7
00:00:33,950 --> 00:00:35,720
So we are going to delete this line.

8
00:00:36,500 --> 00:00:37,920
So here it is, OK.

9
00:00:38,690 --> 00:00:39,700
The first Stanga.

10
00:00:40,100 --> 00:00:42,040
So here what we are going to specify.

11
00:00:42,050 --> 00:00:52,760
We are going to specify the IP address, 172.24.0.1, now the second section.

12
00:00:53,850 --> 00:01:08,160
the ip address is two, and ServerName is going to be 172.24.0.2, and then here your

13
00:01:08,880 --> 00:01:12,420
third section, it will listen on ip address three.

14
00:01:14,070 --> 00:01:22,230
And here also we have to specify the ip address as 172.24.0.3.

15
00:01:23,230 --> 00:01:24,120
So we will.

16
00:01:26,220 --> 00:01:38,100
save and then, we can verify that also whether settings are ok or not, so tail you can specify the

17
00:01:38,490 --> 00:01:42,800
number of lines you want to open tail -15.

18
00:01:42,810 --> 00:01:48,230
It is going to show us that 15, last 15 line of the file.

19
00:01:48,750 --> 00:01:54,180
So it is showing us, let us again check whether everything is okay.

20
00:01:54,360 --> 00:02:00,440
VirtualHost one, two, three and addresses are serverName one, two, three.

21
00:02:00,630 --> 00:02:05,070
And from which directory it is serving example1, example2, and example3.

22
00:02:05,580 --> 00:02:14,280
Then what we are going to say service httpd configtest.

23
00:02:16,440 --> 00:02:22,890
it is OK, then we are going to say service.

24
00:02:25,920 --> 00:02:30,320
reload httpd.

25
00:02:34,150 --> 00:02:40,840
Sorry, again, we have made some mistake, which command we are going to run systemctl.

26
00:02:46,300 --> 00:02:53,290
So this is the way we have created a virtual host, we have made the settings in the file, then we

27
00:02:53,290 --> 00:02:54,750
have restarted the service.

28
00:02:55,150 --> 00:03:01,690
Now we will be testing whether our virtual hosting is working properly.

29
00:03:01,690 --> 00:03:04,240
IP based virtual hosting is working properly or not.
