1
00:00:00,480 --> 00:00:08,330
Now We will see what changes we are going to make in this system that means on master.example.com for launching

2
00:00:08,340 --> 00:00:09,250
single website.

3
00:00:09,630 --> 00:00:17,090
So first of all, we will go to our master system and check whether our Apache packages are available or not.

4
00:00:17,430 --> 00:00:24,540
And what is the default home page directly, whether it is some data is there or it is empty, please.

5
00:00:24,620 --> 00:00:31,070
Remember the Apache servers package name is httpd, Hypertext Transfer Protocol Deamon.

6
00:00:31,500 --> 00:00:38,350
So in certain distributions like ubuntu the Package name is Apache or Apache2.

7
00:00:38,760 --> 00:00:45,090
But in this redhat based distribution, like in our case, we are using centos7.

8
00:00:45,360 --> 00:00:52,740
So the Package name is httpd that when when we are installing httpd Package mean we are

9
00:00:52,740 --> 00:01:00,870
installing the Apache package, a web server, so we will verify with rpm -q query httpd command.

10
00:01:01,230 --> 00:01:06,540
And if it is not installed, you can use the yum install httpd command.

11
00:01:06,750 --> 00:01:15,050
But please remember because we have now given the static address, so internet might is not running.

12
00:01:15,270 --> 00:01:19,800
So again, you have to change those settings from Bridge to NAT.

13
00:01:20,040 --> 00:01:26,760
And in that network adapter settings we are to also change from static to dhcp.

14
00:01:27,270 --> 00:01:32,520
Then you can install the package that we have discussed, already how to set up the lab.

15
00:01:32,940 --> 00:01:40,220
Then we will go to the /var/www/html directory and we will check whether some data is there by default.

16
00:01:40,230 --> 00:01:41,430
Nothing you will be there.

17
00:01:41,700 --> 00:01:47,340
And with the ip a s ens33, we will verify the address also.

18
00:01:47,820 --> 00:01:55,590
So in this is what we are going to do, we are going to check whether packages installed or not or IP

19
00:01:55,590 --> 00:01:58,680
addresses, they are proper or not.

20
00:01:59,430 --> 00:02:06,990
Then what we are going to do, we are going to create one homepage and by default the file name

21
00:02:07,000 --> 00:02:08,950
should be index.html.

22
00:02:09,600 --> 00:02:16,740
Please remember, whenever we are installing the Apache Web Server, one /var/www/html directory will be available

23
00:02:16,740 --> 00:02:21,290
to us in which we are going to check whether anything is there or not.

24
00:02:21,300 --> 00:02:22,410
Initially it is empty.

25
00:02:23,130 --> 00:02:31,680
Now we have to put some contents for our website in this directory. and you can create complex webpages.

26
00:02:31,920 --> 00:02:37,800
But in our case, what we are going to do simple one line page we are going to implement because we

27
00:02:37,800 --> 00:02:44,000
are not interested in learning how to design the website that we are concerned with our Web server.

28
00:02:44,250 --> 00:02:50,570
So even one-Line page will be sufficient for mastering the Apache web server.

29
00:02:51,180 --> 00:02:54,170
So there are now two options for us.

30
00:02:54,660 --> 00:03:01,450
You can use the html for creating the static pages and you can use the php for dynamic pages.

31
00:03:01,890 --> 00:03:05,200
But initially we will be using the html.

32
00:03:05,220 --> 00:03:09,610
Only, later on we will be giving one or two example of php.

33
00:03:09,630 --> 00:03:14,970
Also how to use php along with your Apache.

34
00:03:15,480 --> 00:03:21,110
That means we will be discussing that lamp stack Linux, Apache, MySQL, php briefly also.

35
00:03:21,870 --> 00:03:27,720
So in our case, what we are going to do, we will create some small html page.

36
00:03:28,140 --> 00:03:34,710
We will go to the /var/www/html directly and we are going to create that index html file and we are

37
00:03:34,710 --> 00:03:36,810
going to put some data there.

38
00:03:36,810 --> 00:03:40,830
In our case, that data is going to be welcome to test the website.

39
00:03:41,550 --> 00:03:47,570
And please remember, the name of the file should be always be index.html.

40
00:03:47,940 --> 00:03:55,290
Later on, we will see why we have to keep the name as index html, what will happen if we are going

41
00:03:55,290 --> 00:03:57,540
to change the IP address.

42
00:03:58,380 --> 00:04:05,050
Sorry the name of the file to something else, instead of index.html.

43
00:04:05,880 --> 00:04:12,270
And also we are going to take the back up of our httpd.config, how we are going to take the back

44
00:04:12,270 --> 00:04:14,370
up by using the copy command copy.

45
00:04:14,370 --> 00:04:24,120
/etc/httpd/conf/httpd.conf curly bracket comma dot bak that mean we are going

46
00:04:24,120 --> 00:04:31,590
to back up by using the combination of copy command and other culebras concept.

47
00:04:31,950 --> 00:04:37,780
Then we will verify whether backup has been taken properly or not with which command ls command.

48
00:04:38,400 --> 00:04:39,540
So we will see that.

49
00:04:39,810 --> 00:04:42,390
original file is also there backup is there.

50
00:04:42,600 --> 00:04:43,560
Why we are taking?

51
00:04:43,560 --> 00:04:50,400
Because sometimes we you make so many changes and we have to revert back to the original file.

52
00:04:50,640 --> 00:04:56,640
So if we have taken the backup, we can again go back to our original file.

53
00:04:57,450 --> 00:04:59,220
Then we are going to make the additions.

54
00:04:59,960 --> 00:05:02,030
So now let us see demo of this.
