1,576
edits
Changes
no edit summary
[[Category:OPS235]][[Category:OPS235 Labs]]
{{Admon/caution|THIS IS AN OLD VERSION OF THE LAB|'''This is an archived version. Do not use this in your OPS235 course.'''}}= State when Storage Setup (prior to starting Lab 4 ) =
At this point, having completed [[OPS235 Lab 3|Lab 3]] you should have <u>roughly</u> the following disk storage setup:<br />
/dev/vda2 vg_fedora3 lvm2 a- 9.80G 3.83G
* '''f13host f17host (i.e. "disk pack")'''
Four PVs, minimum VG size 60G
20% of disk space unallocated to any partition (min 15G)
= Logical Volume Management (Continued) =
{{Admon/note|Recovering VMs|'''Most of these investigations will take place in you virtual machines.''' If you make a significant mistake, your virtual machine may not boot. Remember that you created backups of your virtual machines in Lab 3, and you can '''restore them if something goes wrong'''.}}
* [[Logical Volume Management]]
== Investigation 21: How are LVMs are managed using Command-Line Tools ==# You are going to repeat the same LVM management operations (as your did with the ''fedora2'' VMin '''lab3'''), but you will using command-line tools in the '''fedora 3''' VM. Since the fedora3 VM only operates in command-line mode, you will need to refer to the '''"Logical Volume Management"''' link above.
# Write down the exact commands used at each step, and record appropriate command output:
## Determine the current LVM configuration using the <code>pvs</code>, <code>vgs</code>, and <code>lvs</code> command.
## Shrink <code>lv_archive</code> to 1G (use <code>umount</code>, <code>resize2fs</code>, <code>lvreduce</code>, and <code>mount</code>)
== Investigation 32: How can a PV be added to an existing VG? ==
'''Add an additional 2 GB virtual disk to your ''<u>fedora1</u>'' system, and use it as an additional physical volume:'''
# Start <code>virt-manager</code>.
{{Admon/tip|SELinux relabelling may be required|Your system may report that the files are not present in the new /home filesystem when they are clearly there. This is due to the Security-Enhanced Linux system (SELinux) preventing access to the files, because the files were tampered with (moved) and are no longer recognized as home directory content. You can fix this problem by restoring the file context labels so that SELinux accepts the files as valid home directory content: <code>restorecon -r /home</code>}}
== Investigation 43: How can I use LVM to manage storage on my disk pack? =='''On your <u>f13hostf17host</u> (i.e. "disk pack"), using your choice of the GUI and/or command-line tools:'''
# Create a new logical partition ('''NOT a logical volume!''') - minimum 5G, leaving at least 10G free space in the extended partition.
# Add that partition as a PV into the existing VG (using the commands you used in the previous investigation).
# Grow the root filesystem to fill the available space.
= User/Group Management =
== Investigation 84: The /etc/passwd file ==
# Look at the /etc/passwd file.
# The user IDs of real users (people) are different from the user IDs of system accounts. What is the pattern?
== Investigation 95: Adding users ==
{{Admon/note|Use f13hostf17host|Perform these steps in the '''f13hostf17host''' system. Due to a configuration issue, these steps may not work normally in the fedora1 virtual host (previous versions of this lab used fedora1 for this investigation).}}
# Read the man page for the useradd command.
# Add your matrix account user to '''fedora3'''.
== Investigation 106: Managing Groups ==
{{Admon/note|Use fedora1|Perform these steps in the '''fedora1''' virtual machine.}}
Be sure to record your observations in your lab notes.
== Investigation 117: Deleting users ==
{{Admon/note|Use fedora1|Perform these steps in the '''fedora1''' virtual machine.}}
# Delete the user ops235_2 using the same command with the option which removes the home directory of the user.
# Check the contents of the /home directory. What do you notice?
# Check the contents of the /etc/group directoryfile. What do you notice?
Be sure to record your observations in your lab notes.
== Investigation 128: Modifying users ==
{{Admon/note|Use fedora1|Perform these steps in the '''fedora1''' virtual machine.}}
# Two PVs on '''fedora1'''.
# Separate <code>/home</code> filesystem (on an LV) in '''fedora1'''.
<!-- # Unnecessary accounts and groups have been removed on '''fedora1'''. -->
# Account created on '''fedora3''' matching your Matrix account.
# List contents of '''nled/etc/group''' installed on the host file (disk pack - main system '''f13host'''ops235 group).# Answer to this question: #* What is the license List contents of the '''nautilus/etc/passwd''' package?file (created accounts).
# Fresh backup of the virtual machines.
# What is a VG? PV? LV?
# What is the total size of the "main" VG on your system?
# How do you create a LV?
# How would you increase the size of the root filesystem by 50 MB?
# What is the purpose of <code>/etc/fstab</code>?
# What did you have to do in order to move is the home directories onto a new filesystem? Whypurpose of <code>/etc/shadow</code>?