Question

Please help with this linux lab. Please include screenshots as I keep getting errors when I...

Please help with this linux lab. Please include screenshots as I keep getting errors when I attempt this lab. Thank you in advance

Example 1

Enter the system root directory

cd /

pwd

[this command prints working directory]

Here is how to go back to your home directory:

cd ~

pwd

Example 2

Use the Change directory command

cd /labs/lab1/ohio

inside the ohio folder use the Touch command to create a file called

ohiostate.txt

/labs/lab1/ohio/touch ohiostate.txt

Use the pwd and ls to verify your work.

Example 3

Create the following directory structure:

1. Create directory colors off your home directory.

2. mkdir colors

3. inside the colors directory create four directories: blue, red, yellow, green.

4. mkdir blue

5. mkdir red

6. mkdir yellow

7. mkdir green

8. inside each directory (blue, red, yellow, green) create use the Touch command create the following files:

9. Inside the blue directory create files blue01.txt and blue02.txt.

10. Inside the red directory create files red01.txt and red02.txt

11. Inside the yellow directory create files yellow01.txt and yellow02.txt

12. Inside the green directory create files green01.txt and green02.txt

13. Create new files with the same names as in steps 9 through 12 but with sh extension example blue01.sh. So each folder will have 4 files two with txt extension and two with sh extension.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Please find the commands for each given example.

Answer# 1:

USER>
USER>
USER>cd /
USER>pwd
/
USER>cd ~
USER>pwd
/root
USER>

Screen Shot:

USER> USER> USER>cd USER>pwd USER>cd USER>pwd /root USER>

Answer# 2:

Note: I am creating a directory since I don't have. If you have then ignore "mkdir -p /labs/lab1/ohio"

USER>mkdir -p /labs/lab1/ohio
USER>cd /labs/lab1/ohio
USER>touch ohiostate.txt
USER>ls -l
total 0
-rw-r--r-- 1 root root 0 Jul 25 19:55 ohiostate.txt
USER>ls
ohiostate.txt
USER>pwd
/labs/lab1/ohio
USER>

Screen SHot:

USER>cd labs/labl/ohio USER>touch ohiostate.txt USER 1s -1 total 0 -rw-r--r-- 1 root root 0 Jull 25 19:55 ohiostate.txt USER

Answer# 3:

USER>
USER>
USER>cd /
USER>mkdir colors
USER>mkdir colors/red colors/blue colors/green colors/yellow
USER>
USER>touch colors/red/red01.txt
USER>touch colors/red/red02.txt
USER>
USER>touch colors/blue/blue01.txt
USER>touch colors/blue/blue02.txt
USER>
USER>touch colors/green/green01.txt
USER>touch colors/green/green02.txt
USER>
USER>touch colors/yellow/yellow01.txt
USER>touch colors/yellow/yellow02.txt
USER>
USER>touch colors/red/red01.sh
USER>touch colors/red/red02.sh
USER>
USER>
USER>touch colors/blue/blue01.sh
USER>touch colors/blue/blue02.sh
USER>
USER>touch colors/green/green01.sh
USER>touch colors/green/green02.sh
USER>
USER>
USER>touch colors/yellow/yellow01.sh
USER>touch colors/yellow/yellow02.sh
USER>
USER>ls -l
total 16
drwxr-xr-x   6 root root 4096 Jul 25 19:58 colors

USER>ls -l colors/
total 16
drwxr-xr-x 2 root root 4096 Jul 25 20:01 blue
drwxr-xr-x 2 root root 4096 Jul 25 20:01 green
drwxr-xr-x 2 root root 4096 Jul 25 20:00 red
drwxr-xr-x 2 root root 4096 Jul 25 20:01 yellow
USER>
USER>ls -lR colors/
colors/:
total 16
drwxr-xr-x 2 root root 4096 Jul 25 20:01 blue
drwxr-xr-x 2 root root 4096 Jul 25 20:01 green
drwxr-xr-x 2 root root 4096 Jul 25 20:00 red
drwxr-xr-x 2 root root 4096 Jul 25 20:01 yellow

colors/blue:
total 0
-rw-r--r-- 1 root root 0 Jul 25 20:01 blue01.sh
-rw-r--r-- 1 root root 0 Jul 25 19:59 blue01.txt
-rw-r--r-- 1 root root 0 Jul 25 20:01 blue02.sh
-rw-r--r-- 1 root root 0 Jul 25 19:59 blue02.txt

colors/green:
total 0
-rw-r--r-- 1 root root 0 Jul 25 20:01 green01.sh
-rw-r--r-- 1 root root 0 Jul 25 19:59 green01.txt
-rw-r--r-- 1 root root 0 Jul 25 20:01 green02.sh
-rw-r--r-- 1 root root 0 Jul 25 20:00 green02.txt

colors/red:
total 0
-rw-r--r-- 1 root root 0 Jul 25 20:00 red01.sh
-rw-r--r-- 1 root root 0 Jul 25 19:59 red01.txt
-rw-r--r-- 1 root root 0 Jul 25 20:00 red02.sh
-rw-r--r-- 1 root root 0 Jul 25 19:59 red02.txt

colors/yellow:
total 0
-rw-r--r-- 1 root root 0 Jul 25 20:01 yellow01.sh
-rw-r--r-- 1 root root 0 Jul 25 20:00 yellow01.txt
-rw-r--r-- 1 root root 0 Jul 25 20:01 yellow02.sh
-rw-r--r-- 1 root root 0 Jul 25 20:00 yellow02.txt
USER>

Screen shot:

USER>cd / USER>mkdir colors USER>mkdir colors/red colors/blue colors/green colors/yellow USER> USER>touch colors/red/red01.tx

USER> USER 1s -1 colors/ total 16 drwxr-xr-x 2 root root 4096 Jul 25 20:01 blue drwxr-xr-x 2 root root 4096 Jul 25 20:01 qree

Add a comment
Know the answer?
Add Answer to:
Please help with this linux lab. Please include screenshots as I keep getting errors when I...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Boot into your Linux partition (or open Linux in a VirtualBox VM). You will create a...

    Boot into your Linux partition (or open Linux in a VirtualBox VM). You will create a new directory in your home directory called csci2020u/lab02. We’ll add this folder to the Git repositories. Use the following steps to complete this lab: 1. Change into the csci2020u directory 2. Make a new directory, called lab02 3. Add the lab02 directory to Git 4. In the lab02 directory, create the directory structure used by Gradle (the files will be initially empty, you can...

  • 2. Answer the correct command instructions to complete the following: a. What is the admin account...

    2. Answer the correct command instructions to complete the following: a. What is the admin account (username) you created in Lab 1 and write down its home directory (full folder name)? [0.5 pts) b. Assume the following directory structures in your home directory: • /home/(username)/ — use your own (home directory) • /home/(username) /Dir1.0/Dir1.1/ • /home/(username) /Dir2.0/Dir2.1/ in your home directory, create directories Dir1.0 & Dir 2.0, then create directories Dirl.1 & Dir2.1 inside other directories according to above. [1...

  • give notes to what each look like and description in text form Lab#1 –Learning Some Basics...

    give notes to what each look like and description in text form Lab#1 –Learning Some Basics applied Skills We have completed our initial install of Ubuntu and begun to feel our way around our new system. The following assignment will help you familiarize yourself with your new environment. Please use your system to test answer the following questions. After you have logged in and opened a term window... SECTION I: Simple Navigation of the file system 1. Use df command...

  • Cybersecurity Fundamentals Lab #9: Access ControlName: ____________________ If your Kali VM is already up and running,...

    Cybersecurity Fundamentals Lab #9: Access ControlName: ____________________ If your Kali VM is already up and running, login to the root account on the VM via ssh. It does not matter whether you use a command line or GUI sshclient. If your VM is not currently up, use the vSphere web client to start your VM before logging into it via ssh.1: Create an Unprivileged User For some labs, including this one, we will need a non-root user account on the...

  • UNIX File Permission help, please answer the questions in the green boxes. Thank you Lab 03...

    UNIX File Permission help, please answer the questions in the green boxes. Thank you Lab 03 File Permissions In this lab we will: learn about file permissions learn to create symbolic links and hard links Utilities that will be utilized in this Lab: us, cd, less, cat touch, chmod id umask, mkdir, In, echo and redirection Users and Groups Linux supports several methods of controlling access to files an directories. In this lab we are going to learn the traditional...

  • I need the graph exactly as shown in the lab manual please 104 Biology 101L -...

    I need the graph exactly as shown in the lab manual please 104 Biology 101L - LAB 9 Paper Chromatography Schalthe n the strip Carones • • chlorophylla chlorophyll. 2. What three factors abied the pigments in the extract to move at different rates! Absorption Spectrum WAVELENGTH ABSORPTION APPROXIMATE COLOR WAVELLINGTM APPROXIMATE COLOR 400 0.399 Violet 560 Yellow LOSS Violet Yellow .02 .05 05 108 440 Violet 450 que Orange Orange Red 480 Blue 163 500 Green Red Red Green...

  • please help!! In-lab Activity on DNA, DNA Replication and Pro Directions: Complete the color key belowing...

    please help!! In-lab Activity on DNA, DNA Replication and Pro Directions: Complete the color key belowing the Key to colors Adenine - blue Replication and Protein Synthesis Name the DNA modelin class. then awer the questions about the mode ThymineONOMI Deoxyribose Oangcor Red 1. Using the nitrogen base letters to repre your color key and this sequence of colors for the sen blue-blue-orange-yellow-orange-yello Cytosine yellow Guanine - Green COLOR CHOICES Yellow Purple Red Green Orange u to represent nucleotides, wide...

  • Python Help Please! This is a problem that I have been stuck on.I am only suppose...

    Python Help Please! This is a problem that I have been stuck on.I am only suppose to use the basic python coding principles, including for loops, if statements, elif statements, lists, counters, functions, nested statements, .read, .write, while, local variables or global variables, etc. Thank you! I am using python 3.4.1. ***( The bottom photo is a continuation of the first one)**** Problem statement For this program, you are to design and implement text search engine, similar to the one...

  • LINUX QUESTIONS (dont have to display output, I will be running these commands myself to check...

    LINUX QUESTIONS (dont have to display output, I will be running these commands myself to check the output) Display the command(s) used to do the following: create an empty file called history by using just a redirection operator. Verify and show. Show/verify all results (i.e., all commands and their corresponding outputs). Wait 1 minute or more and then display the command(s) used to do the following: change the timestamp on the history file you just created. Verify/display the change. Show/verify...

  • Unix/Linux The purpose of this lab is to practice the commands to manage and organize files...

    Unix/Linux The purpose of this lab is to practice the commands to manage and organize files and directories: How would one go about this? Thanks. Task 1: Preliminaries: 1) If you have not already done so, create a directory called bin under your HOME directory. 2) If you have not already made a copy (using ftp) of the file called famous.dat from the Assignment#1, do that now. 3) Make bin the active/working directory. Task 2: Perform all of the following...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
Active Questions
ADVERTISEMENT