Separate out all files into a new file called onlyfiles


Assignment

Scenario:

You must perform the following tasks on the VMware virtual machine assigned to you at the school.

Required Resources

Virtual computer on the VMware server.

Part 1:

1. Install CentOS6.x operating system on the VMware virtual machine and name it: midterm.

2. Create the following user account: user name Midterm18, password: Password18, set the root password to RootPassword.

3. Create a document in your Documents directory with your name and "midterm" as text in it.

Part 2:

1. Login as the user Midterm18, and perform the following tasks as this user.

2. Create a new directory in Midterm18 user ‘s home folder called: midterm.

3. Navigate to the midterm directory. Perform all work in the midterm directory.

4. Create a file called "etcdir" by listing the detailed content of the "etc" directory (include all hidden files in the listing), and redirect it into the "etcdir" file.

5. Separate out the directories into a new file called "onlydirectories".

6. Separate out all files into a new file called "onlyfiles".

7. Sort the content of "onlyfiles" in reverse order based on the names, and name the output as "sortedfiles".

8. Sort the content of "onlydirectories" in reverse order based on the names, and name the output as "sorteddirectories".

9. Combine the "sortedfiles", and "sorteddirectories" files into a new file called "combined" where the files are listed first, and directories listed second.

10. Change the permissions on all the files in the midterm directory so only the owner of the file can read, and write the files (all other permissions are denied).

Note: You should have 6 files once you finished in the midterm directory. Your file sizes and dates will be different, but all other information should match with the following display:

-rw-------. 1 Midterm18 Midterm18 12865 Jun 4 19:01 combined
-rw-------. 1 Midterm18 Midterm18 6390 Jun 4 18:35 onlydirectories
-rw-------. 1 Midterm18 Midterm18 14291 Jun 4 18:26 etcdir
-rw-------. 1 Midterm18 Midterm18 6475 Jun 4 18:52 onlyfiles
-rw-------. 1 Midterm18 Midterm18 6390 Jun 4 18:59 sorteddirectories
-rw-------. 1 Midterm18 Midterm18 6475 Jun 4 18:58 sortedfiles.

Format your assignment according to the following formatting requirements:

1. The answer should be typed, double spaced, using Times New Roman font (size 12), with one-inch margins on all sides.

2. The response also includes a cover page containing the title of the assignment, the student's name, the course title, and the date. The cover page is not included in the required page length.

3. Also include a reference page. The Citations and references should follow APA format. The reference page is not included in the required page length.

Solution Preview :

Prepared by a verified Expert
Computer Engineering: Separate out all files into a new file called onlyfiles
Reference No:- TGS02977831

Now Priced at $35 (50% Discount)

Recommended (99%)

Rated (4.3/5)