2. Table of Contents
Table of Contents........................................................................................................................................2
SETTING UP HYPER-V...................................................................................................................................3
CREATING A VIRTUAL SWITCH ....................................................................................................................6
INSTALLING WINDOWS SERVER 2012 IN HYPER-V.......................................................................................8
CREATING A DIFFERENCING DISK...............................................................................................................13
EXCHANGE SERVER ...................................................................................................................................21
DHCP FRAME RELAY SERVER.....................................................................................................................47
...................................................................................................................................................................58
2
3. SETTING UP HYPER-V
You can use the steps in the following procedure to convert a Server with a GUI installation to a Minimal Server
Interface Configuration using Server Manager:
1. On the Windows Server 2012 system, open Server Manager and select add roles and features
1. Select Hyper-V as a role
3
5. 5. The installation progress window shows as a summary what you have installed
5
6. 6. once the installation is finished, close the window
CREATING A VIRTUAL SWITCH
1. Select Hyper-V manager
6
7. 2. Select virtual switch manager
3. In this exercise we will connect the switch to a private network
4. Give the switch a name. I named it "Vm1" as shown in the following figure
7
8. INSTALLING WINDOWS SERVER 2012 IN HYPER-V
1. Choose a drive where the virtual machine will be stored
2. Create a folder that will contain the virtual machine
8
9. 4. In the Name text box, enter a name for the virtual machine, such as DC1.
5. By default, the virtual machine data is stored on the system disk. To select a different location, select the Store The
Virtual Machine In A Different Location check box, click Browse, and then use the Select Folder dialog box to select a
save location. Click Next.
9
10. 6. On the Assign Memory page, specify the amount of memory to allocate to the virtual machine. In most cases, you
should reserve at least the minimum amount of memory recommended for the operating system you plan to install.
Click Next.
7. On the Configure Networking page, use the Connection list to select a network adapter to use. Each new virtual
machine includes a network adapter, and you can configure the adapter to use an available virtual network for
communicating with other computers. Click Next.
10
11. 8. On the Connect Virtual Hard Disk page, use the options provided to name and create a virtual hard disk for the
virtual machine. Each virtual machine requires a virtual hard disk so that you can install an operating system and
required applications. Click Next.
9. On the Installation Options page, select Install An Operating System From A Boot CD/DVD-ROM. If you have
physical distribution media, insert the distribution media, and then specify the CD/DVD drive to use. If you want to
11
12. install from an .iso image, select Image File, click Browse, and then use the Open dialog box to select the image file to
use.
10. Click Next, and then click Finish.
12
13. CREATING A DIFFERENCING DISK
1. To ensure that you create a new machine identity, you should generalize your installation.
To do that for Microsoft operating systems, that means running sysprep. IThe simple usage of the tool is to simply
type sysprep from an elevated Command Prompt or the Run dialog box and read the dialog box. Review the
Sysprep dialog box, select the appropriate options, and then run it.
2. Ensured the generalize box is marked
13
14. 3. Change the shutdown option from reboot to shutdown then press OK
Leave the virtual machine shut down/off
14
15. 4. Locate the virtual hard drive file, vhdx, and set that as read-only. To do so, right-click the actual file, clickProperties,
then select the Set the virtual hard drive (.vhdx) file as read only. This will help prevent you or someone else from
accidentally modifying it.
15
16. 5. You no longer need the parent virtual machine configuration files or folders. In Hyper-V manager, right-click the
entry for the virtual machine and then select Delete. Confirm the deletion by clicking Delete. This should remove all
the extraneous files, leaving you only with the virtual hard disk. However, you can go check the file path to ensure
the folders and .xml files were removed. Just be sure not to remove the .vhdx file, because that is the one you want.
That is your parent virtual hard disk from which you will create the differencing disks.
16
17. 6. Right-click the Hyper-V server you want to target, click New, Hard Disk. The New Virtual Hard Disk
Wizardopens.
7. If the Before You Begin page appears, review it and then click Next.
17
18. 8. Select vhdx as the disk format
9. On Choose Disk Type, select Differencing and then click Next.
18
19. 10. On Specify Name and Location, type an appropriate name. For example, APP1.vhd and then enter a specific
location where you want to store the virtual hard disk. For example, I have stored the vhdx to I:DifferenceDisk2. Then
Click Next.
19
20. 11. On Configure Disk, in Location, type or browse to the file path to the parent vhdx that you created previously
and then click Next
12. The parent disk is under the virtual hard disks folder
13. On Completing the New Virtual Hard Disk Wizard, review your selections and then click Finish.
20
21. EXCHANGE SERVER
Setting up Linux server for mail purpose using Windows as a class DNS
First step is installing Linux. For this practice, we will use Fedora as a distribution
1. Select the appropriate language
21
22. 2. choose the destination where you want the operating system to be installed
3. For advanced set up , select " I will configure partitioning"
22
23. 4. Change the “Partitioning Scheme” to “Standard Partition” and click on the “+” button in order to create a new hard
drive
5. Make sure that the mount point is set to “/” and click on “Add mount point”, some options will show up.
23
24. 6. Assign a memory and When you’re done, click on the “Done” button and choose “Accept Changes”.
7. While installation is in progress, you should cease the chance to configure the root password
Configuring bind
24
25. 1. Login as root and Install bind
2. Install webmin . Before installing webmin , you may do the following steps :
a. create the /etc/yum.repos.d/webmin.repo file containing :
[Webmin]
name=Webmin Distribution Neutral
#baseurl=http://download.webmin.com/download/yum
mirrorlist=http://download.webmin.com/download/yum/mirrorlist
enabled=1
b. You should also fetch and install my GPG key with which the packages are signed, with the commands :
wget http://www.webmin.com/jcameron-key.asc
rpm --import jcameron-key.asc
25
26. Use "yum update" to install updates
Configure the network settings
26
27. Disable the firewall by typing the following commands:
iptables -L
iptables -F
systemctl disable firewalld.service
To confirm if bind is running , running the following commands:
systemctl start named.service
systemctl enable named.service
systemctl status named.service shows bind is active
Configure the named.conf configuration file
27
28. Replace the IP address 127.0.0.1 with your static IP address and "localhost" with "any"
In the same configuration file, replaced the lines highlighted where it says yes with no and comment out the last line .
28
29. Edit the resolv.conf by typing the following command : gedit resolv.conf
Configure the hosts file by adding the following as shown in the image
29
30. Configure the "hostname "file by typing the following command : gedit hostname
Configure the local-host-names file
30
31. Configure the sendmail.mc file by commenting out the following line as shown in the figure
gedit /etc/mail/sendmail.mc
I did change my server ip address to 9.0.24.16 at a point
To access the webmin site, type your < IP address >: port# , example: 9.0.24.16:1000
Your username is : root
31
33. In the domain name/network field, you can put any alias. I did earlier put fedora2.net but will later on change it to
.org.
The email address was also changed to fedora2.org.
Only the mail server field is not touched
Select address to create records
33
34. I created 2 records: a www and a blank one . For the blank record, simply leave the name field empty
Select mail address to create an MX record
34
35. Set priority to 10
Edit zone options in order to transfer the zones already created
35
36. Point the zones to the class DNS : 9.0.20.3
Create a forward look up zone pointing at the class DNS
36
37. Login windows 2012 server which is your edge server then connect to the slave the server
Enter the IP address of the slave server
37
39. In the exercise, I changed the record to .org. So please ignore the following record
The DNS could not resolve the IP address because I did not configure the named.conf properly.
39
40. Earlier I had changed the IP address from 9.0.24.10 to 9.0.24.16
40
41. Configuring sendmail
1. In order to use Sendmail, first ensure the sendmail package is installed on your system by running, as root
In order to configure Sendmail, ensure the sendmail-cf package is installed on your system by running, as root
2. Avoid editing the sendmail.cf file directly. To make configuration changes to Sendmail, edit
the /etc/mail/sendmail.mc file, back up the original/etc/mail/sendmail.cf, and use the following alternatives to
generate a new configuration file:
o Use the included makefile in /etc/mail/ (~]# make all -C /etc/mail/) to create a
new/etc/mail/sendmail.cf configuration file.
41
42. 3. You should be able to see the file "make" created
Edit the local-host-names file
Type gedit /etc/mail/local-host-names
42
47. DHCP FRAME RELAY SERVER
Using Relay agent to assign an IP address
I have used the following topology
Configure the network interface on the server that run the relay agent service and point the DNS to the DHCP server
47
48. Configure Ethernet interfaces of the router that I will be used as a gateway
Establish a link between the two networks with OSPF protocol . Use area 0 for the configuration
Test the network connection by pinging the gateways on both ports : 192.168.0.1 and 10.0.0.1
From the relay agent , ping the dhcp server to test if the connection has been established
48
49. Click start then server manager
Add role :
Select remote Access services
49
58. In the Routing and Remote Access console, expand the IPV4 Routing node in the left pane of the console and right
click on the General node. Click on the New Routing Protocol command
58
59. In the New Routing Protocol dialog box, click on the DHCP Relay Agent entry and click OK
A new node, the DHCP Relay Agent node, appears in the left pane of the Routing and Remote Access console.
Right click on the DHCP Relay Agent node and click New Interface
59
60. Select the Ethernet interface (this is an internal interface used by the Routing and Remote Access Service. Click OK
In the DHCP Relay Agent Properties dialog box , type in the IP address of the DHCP server in the Server
address text box and click the Add button. Click Apply and then click OK.
60
61. Configuring DHCP server
1. In the left pane of the DHCP console, right click on your server name and click the New Scope command
Then click Next on the first page of the New Scope Wizard
61
62. 2. Type a Name and Description for the scope on the Scope Name page
3. Put in the range of IP addresses used by the scope on the IP Address Range page. Type the first IP address in the
range in the Start IP address text box and the last IP address in the range in the End IP address text box. Note that the
subnet mask is entered for you automatically. You can change the default subnet mask if you require a custom mask
4. After clicking next, a new scope wizard pops to enter a range of IPs that need to be excluded.
In this exercise, we will not skip the wizard
5. You can set a lease duration on the Lease Duration page. For this exercise, we have left it at default
62
63. 6. Select the Yes, I want to configure these options now on the Configure DHCP Options page. Click Next.
7. You can enter a default gateway on the Router (Default Gateway). For this exercise, we have entered 10.0.0.1 as the
gateway on the other network
8. You can enter a Parent domain and a DNS server address on the Domain Name and DNS Servers page.My DNS is
192.168.0.2
9. On the Activate Scope page , select the Yes, I want to activate the scope now option and click Next
10. Click Finish on the Completing the New Scope Wizard
Login to your windows client
63
64. Disable then re-enable the network adapter
Run ipconfig
We see the DHPC giving the client an ip address 10.0.0.2
64