Changes

Jump to: navigation, search

OPS235 Lab 3 - CentOS7

343 bytes added, 12:29, 24 September 2018
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.'''}}
= LAB PREPARATION =
</ul>
</li>
<li>What does the'''z''' option do?</li>
<li>Compare the sizes of '''/tmp/archive1.tar.gz''' and '''/tmp/archive2.tgz'''. Why are they so close in size?</li>
</ol>
# Part is to be performed in your '''centos2''' VM.
# Issue the following command to install a basic set of development tools and libraries:<br /><b><code><span style="color:#3366CC;font-size:1.2em;">yum groupinstall "Development Tools" "Development Libraries"</span></code></b><br><br>NOTE: If you are unable to issue the '''make''' command later in this lab, then issue the command:<br><b><code><span style="color:#3366CC;font-size:1.2em;">yum groupinstall "Development Tools" "Additional Development"</span></code></b><br><br>
<ol>
# Place your Centos7 Full Install DVD into the DVD drive of your hostmachine.
# View the contents of the DVD drive using the file manager application (called '''nautilus'''). Change to the Packages subdirectory. What does this subdirectory contain?
# Use a graphical file manager to view the contents of the DVD in your machine.<br><br>'''TIP:''' If you are having problems locating pathname to your DVD, open a terminal, login as '''root''', issue the command: '''mount''', and look for a path-name containing your Centos Install DVD and use that path-name when required later in this section.<br><br>
# Open a shell terminal and use the Linux command '''cd''' to change to the '''Packages''' sub-directory (hint: similar path-name as USB, but use '''Centos 7 x86_64/Packages''' and use '''quotes''' " " around full path-name since there are spaces within the pathname).
<ol>
<li value="14">We will now look at how we can add different repositories to our '''c7host''' machine.</li><li>As root, issue the following command: <b><code><span style="color:#3366CC;font-size:1.3em;">yum repolist</span></code></b></li><li>Take a few moments to view the contents of the file. Do you see which repositories are used by the '''yum''' command? Write down the repositories in your lab logbook.</li><li>View the following link to see a general listing of repositories:<br>[ [http://wiki.centos.org/AdditionalResources/Repositories Available Repositories for Centos] ].</li><li>To add this repository, issue the command:<br><b><code><span style="color:#3366CC;font-size:1.3em;">wget https://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-56.noarch.rpm</span></code> </b><br>Or if you receive a error message, try the command: <br><b><code><span style="color:#3366CC;font-size:1.3em;">yum install epel-release</span></code></b></li><li>To enable the repository in yum, issue the following command:<br><b><code><span style="color:#3366CC;font-size:1.3em;">yum install epel-release-7-56.noarch.rpm</span></code></b></li><li>To clean-up the repository list (including downloading new applications in added repositories), issue the command: <b><code><span style="color:#3366CC;font-size:1.3em;">yum clean all</span></code></b></li><li>To verify that you have added the repository, you can issue the command: <b><code><span style="color:#3366CC;font-size:1.3em;">yum repolist</span></code></b></li><li>Unused and unneeded software can present a security risk and ties up disk space needlessly. Find '''at least 4 other packages''' to remove on your c7host machine(for example: '''sound & video''', '''games''', etc) that you're not using on your system. Be careful to ensure that removing those packages does not also remove other software that you do need.</li>
</ol>
'''Answer Investigation 3 observations / questions in your lab log book.'''
 
= INVESTIGATION 3: LOOKING AHEAD =
&#35; packageInfo.bash<br>
&#35; Purpose: Generates a report to displaying specified information of installed software<br>
&#35;<br>&#35; USAGE: ./packageInfo.bash[application-name]<br>
&#35;<br>
&#35; Author: *** INSERT YOUR NAME ***<br>
<code style="color:#3366CC;font-family:courier;font-size:.9em;">
&#35; Clear screen and use Here Document to display select on report items to read into variable<br>
clear<br>
cat &lt;&lt;+<br>
Available Package Information Items:<br>
<br>
cat &lt;&lt;+<br>
File "/root/package-info.txt" can has been created<br>
+<br>
</code>

Navigation menu