· 9 years ago · Oct 19, 2016, 03:16 PM
1
22
32
4SETTING UP THE LAB ENVIRONMENT
5This chapter contains instructions on how to se
6t up the machines you will be using for the lab
7assignment. To save time, you may install the
8Windows Server 2012 R2 ma
9chine (instructions are
10found in chapter 3) in parallel to installing the Ubuntu/VirtualBox machine. However, before you
11start doing anything, take your time to read through chapter 2 as a whole.
122.1
13Topology overview
145 machines in total (physical or virtual) will be
15 set up. Illustration 2.1 shows an overview of the
16lab topology. Table 2.1 presents the IP addresses
17and hostnames to be used
18 for each machine in
19your environment. Use this table later on, when
20 you configure the IP address and computer/host
21name for a machine. The netmask is always
22255.255.255.0 in the computer group networks, and
23the gateway address should be the first usable (1 in the last octet). Use the both NSA DNS
24nameservers, the primary has the IP addre
25ss 10.0.252.201 and the secondary 10.0.252.202.
26Table 2.1: IP addressing and naming
27Machine IP address Hostname / computer name
28Windows Server 2012 R2 Standard
2910.<room>.<group>.10 wgserver
30Virtual machine host with Ubuntu DHCP vmhost-<your username>
311
32Lisa's workstation (Windows 10) 10.<room>.<group>.21 lisa-ws
33Max's workstation (Windows 10) 10.<room>.<group>.22 max-ws
34Klara's workstation (Windows 10) 10.<room>.<group>.23 klara-ws
351
36Set by configuring the /etc/hostname and /etc/hosts file
37Illustration 2.1: Lab topology overvie
38w
393
402.2
41Setting up the virtual machine host
42The workstations of three users will be set up in a virtual machine each, running on top of
43Ubuntu Linux and VirtualBox, on the machine labeled
44Server
45. Version 14.04 of Ubuntu should be
46used and you should continue using the installation made during the Linux assignment.
472.2.1
48Setting up VirtualBox
49VirtualBox is software that lets you run so ca
50lled “virtual machines†on a physical machine.
51Instead of setting up a physical machine for ea
52ch computer/operating system we need for the
53lab, each machine can instead be installed as a
54virtual machine on top of an existing operating
55system. Each machine gets allocated a part of the physical machine's main memory, and gets
56allocated a virtual hard drive which is represented as a single file in the host operating system (i.e.
57the machine VirtualBox is running on).
58To install Virtualbox on your Ub
59untu computer, follow the official
60 guide. It is available under
61https://www.virtualbox.org/wiki/Linux_Downloads
62, scroll down to the section “Debian-based
63Linux distributionsâ€.
64Note
65: the Ubuntu version is called “
66trusty
67â€, therefore you need to update
68the line you add to the
69sources.list
70 file:
71 deb http://download.virtualbox.org/virtualbox/debian trusty contrib
72When the install is finished, you can star
73t VirtualBox from th
74e Ubuntu unity dash.
75 Illustration 2.2: Virtualbox co
76nsole with three virtual machines
774
782.3
79Virtual machines for the workstations
80Workstations for three of the users in the small
81office should be set up as virtual machines.
82Create virtual machines for the three workstations from Illustration 2.1, using the “New†button.
83Configure them with the following characteristics:
84ï‚·
85Main memory of 2 GB
86ï‚·
87A virtual hard drive of 20 GB, of type “dynamically expandingâ€.
88Make sure to use the
89vdi
90 (VirtualBox image) – hard drive file type
91ï‚·
92Correct “OS Type†for each workstat
93ion according to Illustration 2.1.
942.3.1
95Network interface configuration
96After the machines have been created, a few settings have to be configured. For networking to
97work properly, the network interfaces of the virtual machines have to be “bridged†to the
98physical network interface of the host machine. This is done by clicking the “Settings†button for
99the virtual machine. From here, select the “Net
100work†settings category, and on the “Adapter 1â€
101tab, select “Bridged Adapter†on the “Attached to†drop-down box (currently set to NAT). If
102your machine has
103two Ethernet adapters
104, you also have to select which one to bridge with.
105Mark “Allow VMs†on “Promiscuous Mode†for all Windows virtual machines.
1062.3.2
107Disc images
108The most common way of manually installing an oper
109ating system on a comput
110er is to boot it up
111using an operating system installation disc. When you install virtual machines, you have a few
112different options. A simple way is to configure the virtual machine to use the CD/DVD reader
113of the host directly. Another way is to config
114ure the virtual machine to use a virtual CD/DVD
115reader, and connect an image file (ISO) to it, which is holding the contents of a disc (e.g a
116Windows installation disc). This is what you will do
117 in this lab. Below you'll find the steps to
118download the files.
1191.
120Download ISO files for
121Windows 10
122 from http://files.nsa.his.se/labfiles/it115g/
1232.
124When you start your virtual machine the first time, VirtualBox will ask you for a boot
125media. You will then select your downloaded ISO-image.
126To verify the network settings, the operating
127system must be installed and IP settings be
128configured. It is possible, if necessary; to change
129 the network interface configuration for a virtual
130machine after it has been installed.
131Instructions for installing the operati
132ng systems continue in chapter 3.
1335
1343
135ASSIGNMENT
136Your first assignment is to install your machin
137es. Please do the work in parallel. Start the
138installation of Windows Server as well as the workstation installation. It might be unwise to start
139the installation of the three workstations in parallel though.
140For the Windows 10 you will be using the test pe
141riod available and should NOT activate your
142version. The test period covers 30 days and you w
143ill have finished the lab before that, in case you
144end up having to do the re-examination an
145 activation key will be provided for you.
1463.1
147Operating system installation and basic configuration
148This section presents the installation and basic configuration of the server and workstations of
149the workgroup.
1503.1.1
151Personnel workstations
152Install Windows 10 on the virtual machines you just
153 set up. They should be configured according
154to the following:
155ï‚·
156How you set up your partition(s)
157and file system(s) is up to you
158ï‚·
159Locale settings and keyboard
160 layout set to Swedish.
161ï‚·
162Computer names and IP addre
163sses according to Table 2.1.
164ï‚·
165When asked for user account information in the setup, create a user named the following
166depending on who's computer you are setting up:
167-
168max-ws:
169maho
170-
171klara-ws:
172klar
173-
174lisa-ws:
175lila
176ï‚·
177Set their passwords to “Syp9393â€
178ï‚·
179All Windows 10 workstation should not use Microsoft account credentials. To skip this
180during setup be sure to select “Create a new account†and then “Sign in without a
181Microsoft accountâ€.
182ï‚·
183Configure Windows updates to automatically fetch and install Windows updates when
184available
185You may choose to install the “VirtualBox
186Guest additions†by selecting “Install Guest
187Additions†on the Devices menu in the windows where your machine instances are running.
188Installing the guest additions will make the perfor
189mance of your virtual machines better, and will
190make it possible to drag the mouse pointer betw
191een the host operating system and the machines
192freely, without having to release the mouse pointer using the right CTRL button each time you
193want to leave a machine.
1943.1.2
195The Windows Server 2012 R2 workgroup server
196On the machine labeled “
197Klientâ€
198, Windows Server 2012 R2 Standard
199edition should be installed to
200be used as a workgroup server for the small office environment you are setting up. DVD discs
201for Windows Server 2012 R2 are present in the lab.
202Make sure the disc is labelled “R2â€.
203 Do
204basic configurations and settings
205 according to the following:
2066
207ï‚·
208Make sure to install with a graphical user interface (GUI)
209ï‚·
210Create two partitions formatted with the NTFS file system:
211-
212A 40 GB partition for the system partition (C:)
213-
214A 5 GB partition for data storage (D:). If drive letter D gets allocated to the
215DVD reader, use the “Disk management†t
216ool in “Server Manager†to relocate
217the DVD drive to a new drive letter
218-
219More file systems will be created later
220ï‚·
221Local settings and keyboard layout same as for the workstations
222ï‚·
223Computer name according to Table 2.1. Note that this name may have to be set
224after
225 the
226operating system have been installed
227ï‚·
228Set the Administrator
229password to “Syp9393â€
230ï‚·
231IP address according to Table 2.1
232ï‚·
233Configure Windows updates to automatically fetch and install Windows updates when
234available
2353.2
236Shared file resources
237For the personnel of Contoso AB to be able to share common documents and other files, the
238workgroup server should be set up to hold a
239number of network shared directories. Those
240directories must also be properly
241 protected to deny any unauthorized person to access the files
242they contain.
2433.2.1
244User accounts and security groups
245Each employee of Contoso AB should have a personal user account on the workgroup server.
246Create a user for each employee from Table 3.1. Local users and groups can be added from
247Server manager
248→
249 Tools
250→
251 Computer Management
252→
253 Local users and groups
254. The
255password for all users should be Syp9393, except
256 for Max Holmgren (maho). Set his password to
257“Syp9494â€.
2587
259Table 3.1: Employees of Contoso AB
260Namn Användarnamn
261Birgitta Sundström bisu
262Filip Karlsson fika
263Max Holmgren maho
264Hanna Andersson haan
265A
266lbin Nyberg aln
267y
268Klara Arvidsson klar
269Elin Berggren elbe
270Erik Berg erbe
271Lisa Larsson lila
272Gustav Wells guwe
273Contoso AB consists of a number of divisions. Users’ permissions on shared directories and
274other resources should be based on what division the user belongs to. Hence, a number of
275security groups should be created. See Table 3.
2762 for a list of groups to be created, and their
277members.
278Table 3.2: Divisions of Contoso AB
279Group Members
280finance
281klar
282f
283ika
284lila
285guwe
286haan
287executives
288maho
289guwe
290research and development
291lila
292elbe
293bisu
294all personnel
295A
296ll 10 users from Table 3.1
2978
2983.2.2
299Shared directories
300The directories in Table 3.3 should be created and shared to the workstations of the workgroup.
301Correct permissions must also be set on them to
302 deny any unauthorized user to access the files
303of the company. Create a directory called “
304shared
305†in the root of the D drive, to keep the
306shared directories in.
307All directories of the table should be shared individually, and their share name should be the
308same as the name of the directory.
309Table 3.3: Shared directories
310Directory Drive letter
311(on workstations)
312Permissions
313hemligt M The
314executives
315 group should all have the modify access to the folder
316and all its contents, independen
317t of file/directory owners. No
318permissions at all for other users.
319rnd R The “
320Research and development
321†group should have modify access to
322everything created here.
323The
324finance
325 group should be able to
326read all documents saved in
327this directory
328temp T All files created in this direct
329ory should only be accessible by the
330user who created the file, and no one else. A user who creates a
331file must get modify permissions
332for that file, but no other users
333should be able to even read it.
334For directories, only the user who
335created it should have access to it. All other users should be
336denied to even list the contents of that directory.
337Hint: Use the
338Creator/Owner
339 placeholder
340fackligt F Modify access for user lila
341Read access (all files and contents of folders) for
342all personnel
343except
344members of the
345executives
346 group.
347publikt G All users of the personnel shou
348ld be able to create files in this
349directory and the creator should get modify access to his/her files.
350All users of the personnel group should be able to read everything
351in the directory (list directory contents, read the contents of files,
352etc).
353To make it easy to access the sh
354ared directories, drive letters in “My computer†on each user's
355workstation should be setup to point to all the directories that the user has at least read access to.
356See the “Drive letter†column in Table 3.3 for drive letter allocation. On each of the three
357workstations, make a network drive mapping that w
358ill stay permanent, i.e. still be present after a
359reboot of the workstation (or re-logon of the
360user). Notice that a username and password will
361have to be entered when accessing a share (and hence mapping a share to a drive letter). This is a
362username and password for a user known to the
363server that the shared directory resides on.
364There is one exception though. Before the user
365name and password dialog appears, Windows will
366try to connect to the shared directory using the username and password that was used to logon
367to Windows. Hence, if the credentials used to log on to Windows are matching a user account on
368the server that holds the shared directory, a
369successful authentication will be performed and no
370credentials are asked for. Note that this is true for Klara and Lisa, but not for Max since he has a
371different password in the server than on his workstation (Syp
3729494
373 instead of Syp9393).
3749
3753.2.3
376Home directories
377To further centralize storage of data, Contoso
378has decided to let the employees store their
379personal directories centrally on the workgroup server. Create home directories for at least the
380three users you have set up workstations for as subfolder to a folder named “homes†on the D
381drive. E.g the local path to Max ho
382me directory on the server will be “
383d:\homes\maho
384â€.
385Configure the permissions to allow the user the
386home directory belongs to full control, and no
387permissions at all for other users.
388Share the “d:\homes†directory and verify that each user can access its home directory over the
389network from its workstation.
390To make it easy to create a persistent drive letter mapping on each workstation, your task is now
391to create a Visual Basic script that can be executed on each workstation which should do the
392following:
3931.
394Retrieve the username of the user logged on
3952.
396Make a
397permanent
398(i.e. stays after a relogon or reboot) mapping for
399\\wgserver\homes\<username>,
400 where the username is the username of the logged
401on user retrieved in step 1.
402Call the script
403maphome.vbs
404and publish it to the
405publikt
406 directory. As an alternative you may
407do the same task with a PowerShell script (which would then be called
408maphome.ps1
409). If you
410prefer doing the task with another
411scripting language, it is allowed.
4123.2.4
413Temporary folder cleaning (G/VG)
414(G)
415 In this assignment you should create a schedu
416led job that removes all
417files and directories in
418the shared “temp†folder on the workgroup server every night at 01:30 (before the backup is
419run). This may be achieved with either a PowerShell script or a vb-script.
420(VG)
421 In this assignment you should create a
422scheduled job that removes specific files and
423directories in the shared “temp†folder on the workgroup server every night at 01:30 (before the
424backup is run). This may be achieved with either a PowerShell script or a vb-script. The files and
425directories to remove are chosen according to the following rules:
426ï‚·
427Only files older than 24 hours should be removed (rather than removing everything at
42801:30). A directory is not removed until all f
429iles in it are older than 24 hours, or as
430another way of seeing it, when all files have been removed from it.
431ï‚·
432 Hint: You will likely need a recursive loop.
4333.2.5
434Redirection of My documents (VG)
435Now when each user has a home directory, it would be nice if all documents stored in the “My
436documents†directory would be stored on the se
437rver. Your task is to set the location of “My
438document†to point to the new home directory of
439the user. Everything the user stores in the “My
440documents†directory is to end up in the users home directory. This should be done for each user
441on each workstation.
44210
4433.3
444Partitioning
445After the workgroup server has been used for a while to store common files, Contoso realizes
446that they need more disk space on drive D. Currently the size of this volume is 5 GB, but
447Contoso would like to have a 20 GB volume. Your task is to do the following:
448ï‚·
449Create a new partition of 20 GB and format it with the NTFS file system.
450ï‚·
451Transfer the all data (directories and files) from the old D drive to this new drive. Make
452sure to move the files in a way that preserves all permission data.
453ï‚·
454Let the new 20 GB drive take over drive letter D. The old partition mounted on drive
455letter D may still be kept, but it should not be mounted on a drive letter.
456Note that resizing the D drive is not a valid solution. The aim of the task is to get experience in
457moving data between volumes.
458In addition to making the D drive larger, Contoso would like to have a separate partition to put
459backups on (to be used in the File backup task). For this purpose, create a partition of 20 GB and
460format it with the NTFS file sy
461stem. Assign it drive letter E.
4623.4
463Data backup
464To protect the users' files in case
465 of a hard drive failure or accidental deletion, the system should
466be set up to automatically create a full backup of the contents of drive D every night at 2 am.
467The backup should be placed on the (newly created) E drive. Note that in your lab setup the D
468and E drives are actually volumes of the same
469hard drive, which means
470that backing up files
471between them does not protect from a hard drive failure. Because of practical limitations
472however, we have to imagine that the E drive is on a different physical hard drive.
473There are many tools to take backups. You are free to use any solution as long as it takes a full
474backup of all the contents of the D drive and it
475 is possible to restore files from the backup. A
476recommendation is to use “Windows Server Back
477upâ€, which is included in Windows Server 2012
478R2. Remember to have a method to test your ba
479ckup, so that you can know if your backups are
480working.
4813.5
482Remote administration
483Filip Karlsson (fika) has just been
484 promoted to the role as syst
485em administration for Contoso
486AB. Now he wants to be able to remotely configure the workgroup server, to avoid having to be
487at the same physical location as the server to admi
488nister it. For this to work you need to perform
489the following:
490ï‚·
491Enable Remote Desktop connections on the workgroup server
492ï‚·
493Add Filip to the Administrators group. In addi
494tion to administrative rights, this group by
495default have remote logon permissions
496Verify that Filip can logon remotely by starting a Remote Desktop client on one of the
497workstations, connect to the workgroup server, and logon as fika.
49811
4994
500LITERATURE
501The lecture slide provides most of the info
502rmation you need to pa
503ss the lab assignment.
504Manual for VirtualBox:
505http://www.virtualbox.org/manual/
506Microsoft Library for Windows 2012 and 2012 R2:
507https://technet.microsoft.com/en-
508us/library/hh801901.aspx
5095
510CHECKLISTA
511Fill out this checklist as you are prog
512ressing though the lab assignment.
513â–¡
514 All machines are up and running, and networking is working
515â–¡
516 Workgroup server
517â–¡
518 Vmhost with Ubuntu
519â–¡
520 Klara's workstation
521â–¡
522 Lisa's workstation
523â–¡
524 Max workstation
525â–¡
526 The following file systems exist on the server
527, formatted with NTFS and have correct sizes
528â–¡
529 C: (40 GB)
530â–¡
531 D: (5 GB after installation, but 20 GB after task 3.3)
532â–¡
533 E: (20 GB)
534â–¡
535 All user and group accounts exist on the wgse
536rver, and users are put in the correct groups
537â–¡
538 Shared directories are created and correct permissions configured
539â–¡
540 hemligt
541â–¡
542 rnd
543â–¡
544 temp
545â–¡
546 fackligt
547â–¡
548 publikt
549â–¡
550 Home directories
551â–¡
552 Correct permissions are set
553â–¡
554 The three users all have a persistent mapping of their home dir to H: (on workstations)
555â–¡
556 A VBS script exists to
557make a persistent mapping
558â–¡
559 Redirection of the “My documents†directory (VG)
560â–¡
561 Cleaning of temp folder
562â–¡
563 Cleaning everything at 01:30 (G)
564â–¡
565 Cleaning files older than 24 hours at 01:30 (VG)
566â–¡
567 Backup and restore of all files on the D drive works
568â–¡
569Remote administration of the
570wgserver using Remote Desktop
571â–¡
572 Remote desktop activated
573â–¡
574 Fika can logon using an rdp client and has administrative rights on the wgserver