PART ONE: Textbook Answer each question posed in these projects and insert the answers in order into this document directly under the project description. No need to enter the questions, only the...

1 answer below »

PART ONE: Textbook


Answer each question posed in these projects and insert the answers in order into this document directly under the project description. No need to enter the questions, only the answers. If asked to login to user1, use your personal account instead. When asked for passwords, use the ones you created on your system.



  1. Do Project 5-1, pg. 245. In step 5, if you receive an SELinux error message just continue with step 6. In step 8, recall that the units output for du are blocks unless one uses –h.



  1. Additional Project – Switch to command-line terminal (tty2) by using
    Ctrl+Alt+F2
    and login to root. Enter this command
    ls -l /dev/sr0. Is the device file sr0 present? ______


Insert the CentOS installation DVD or the Fedora DVD that came with your text. Go back to the GUI with
Ctrl+Alt+F1. Did the DVD automount? _______ Enter the command
mount
without arguments from the command line. What is the device file shown for the DVD? _________________ What is the mount point (give absolute pathname)? _________________________________________ What is the type _______________________? Now, enter
umount /dev/sr0
from the command line. Does the DVD unmount? _____ Now, try to mount it manually by entering
mount -t iso9660 /dev/sr0 /media/dvd
(be sure you are logged into root at this point). What is the message you get? ____________________________________________________________ Create the mount point directory with the command
mkdir /media/dvd, then re-execute the above mount command. Is it successful? _____ Now, try to eject the DVD with the eject button on the drive. Does it eject? ____ Enter
umount /dev/sr0
then press the eject button. Does it now eject? _____ Is the mount point directory still present? _____


  1. Additional Project – From the GUI terminal window, enter
    df -h. Screen print the display and include it immediately below. What does the –h option do for us? ____________________________________________________________________________________


Do a Google search for /dev/shm. What is /dev/shm used for? __________________________________
____________________________________________________________________________________


  1. Additional Project – From the GUI terminal window give yourself root permission with the command


su - root, then enter
du –h /var/log. Enter
du –hs /var/log. Screen print the window and include it immediately below. What does the –s option do for us? _______________________________________________________________________


  1. Additional Project – How many partitions did we create on our hard drive when we installed Linux in Lab 1? ________ Recall that these partitions had names. Fill in the missing partition names here: Boot partition, ______________________, and ______________________ Let’s create another partition on our hard drive. Recall that we left some free space when we did the install in Lab 1. We will use the procedure described on pp. 212-218 as a guide, but follow the steps here:

    1. Use
      Ctrl+Alt+F2
      to login to the terminal using the root account.

    2. Enter
      fdisk /dev/sda
      to launch the fdisk utility.

    3. Enter
      m
      to view the fdisk commands.

    4. Enter
      p
      to list the partition table on your hard disk.

    5. Enter
      n
      to create a new partition .

    6. Enter
      e
      for an extended partition.

    7. Enter
      4
      for the partition number.

    8. Enter the default cylinder for your first cylinder number.

    9. For the last cylinder, enter a number about half way between the first and last cylinder numbers shown.

    10. Enter
      p
      to list the partition table again. You should see your new extended partition.

    11. Enter
      n
      to create a new logical partition in the extended partition.

    12. Enter
      l
      for logical partition. (That is the letter l.)

    13. Enter the default cylinder for the first cylinder.

    14. For the last cylinder, enter a size that is less than the size of the extended partition you created above and which was shown as a result of the p command, for example, enter
      +3G. Alternatively, enter a cylinder number somewhat less than the last cylinder number shown.

    15. Enter
      p
      to list the partition table. You should now see your new logical partition.

    16. Enter
      w
      to write the changes to the hard disk and attempt to reload the new partition table into RAM.

    17. Reboot your computer.

    18. After the reboot, use mkfs to format the new logical partition using the ext4 filesystem as follows:
      mkfs -t ext4 /dev/sda5

    19. Now, create a directory you will use as a mount point for the new partition as follows:
      mkdir /data

    20. Make sure that /data has permissions for all users to access it:
      chmod a=rwx /data

    21. Mount the partition to the newly created mount point with the command:




mount -t ext4 /dev/sda5 /data

  1. Go back to your GUI with
    Ctrl+Alt+F1
    then from a terminal window display your mounted filesystems with the command:
    mount
    Do you see sda5? ______ Enter the
    df
    command. Do you see sda5? _______ Screenprint the mount and df commands’ output and insert it immediately below.

  2. Try creating some files in the new partition by storing them in /data. Can you do that? __________

  3. We won’t have the system automatically mount this new partition at boot time.



  1. Additional Project – Refer to pp. 50-51 and pp. 208-209 in the text and to these sites:


http://www.pcguide.com/ref/hdd/file/structPartitions-c.html
http://www.tech-faq.com/hard-disk-partition.html
http://en.wikipedia.org/wiki/Serial_ATA
and possibly other websites to answer the following questions (your answers may be brief).

  1. Compare and contrast primary partitions, extended partitions, and logical partitions.

  2. Describe/compare PATA and SATA drives.



  1. Do Discovery Exercise 2, pg. 253.



Upload this document with your answers in
bold
and the screen shots included through Moodle.
Answered Same DayDec 21, 2021

Answer To: PART ONE: Textbook Answer each question posed in these projects and insert the answers in order into...

Robert answered on Dec 21 2021
132 Votes
1. Do Project 5-1, pg. 245.
In step 5, if you receive an SELinux error message just continue with step 6.
In step 8, recall that the units output for du are blocks unless one uses –h.
In this hands-o
n project, you view and create device files.
1. Turn on your computer.
After your Linux system is loaded, switch to a command-line terminal (tty2) by pressing Ctrl+Alt+F2 and
log in to the terminal using the user name of root and the password of secret.
2. At the command prompt, type ls –l /dev/tty6 and press Enter. - ls -l /dev/tty6
crw--w----. 1 root tty 4, 6 Oct 27 2012 /dev/tty6
What device does /dev/tty6 represent? Virtual terminal tty6
Is this file a block or character device file? Why? Character device file (Virtual terminal)
What are the major and minor numbers for this file? 4, 6
3. At the command prompt, type rm –f /dev/tty6 and press Enter.
Next, type ls –l /dev/tty6 at the command prompt and press Enter.
Was the file removed successfully? - Yes
4. Switch to the command-line terminal (tty6) by pressing Ctrl+Alt+F6 and
attempt to log in to the terminal using the user name of root and the password of secret.
Were you successful? No
5. Switch back to the command-line terminal (tty2) by pressing Ctrl+Alt+F2, type the
command mknod /dev/tty6 c 4 6 at the command prompt and press Enter.
What did this command do? - If one finds a corrupted device file, or accidentally delete a device file, the mknod command can be used to re-create the device file if one knows the type, major number,
and minor number.
What other command can be used to do the same function?
If one does not know the type, major number, or minor number of the device, one can use the /dev/MAKEDEV command to re-create the device based on the common name
Next, type ls –l /dev/tty6 at the command prompt and press Enter.
Was the file re-created successfully? - No
6. At the command prompt, type reboot and press Enter. After your Linux system has
loaded, switch to a command-line terminal (tty6) by pressing Ctrl+Alt+F6 and log
in...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here