Preview

It 250 Homework 4

Satisfactory Essays
Open Document
Open Document
769 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
It 250 Homework 4
1. What does the shell ordinarily do while a command is executing? What should you do if you do not want to wait for a command to finish before running another command?
Answer: The shell waits for the command to finish executing. You can send the command to the background by using "&".
2. What is a PID number? Why are these numbers useful when you run processes in the background? Which utility displays the PID numbers of the commands you are running?
Answer: A PID number is an identification number assigned to a command running in the background, which can be used to differentiate between commands. The PS (process status) utility.
3. Assume that the following files are in the working directory:
$ ls intro notesb ref2 section1 section3 section4b notesa ref1 ref3 section2 section4a sentrev
Give commands for each of the following, using wildcards to express filenames with as few characters as possible.
a. List all files that begin with section.
Answer: $ ls section*
b. List the section1, section2, and section3 files only.
Answer: $ ls section[1-3]
c. List the intro file only.
Answer: $ ls i*
d. List the section1, section3, ref1, and ref3 files.
Answer: $ ls *[13] 4. Give a command to
A. Redirect the standard output from a sort command into a file named phone_list. Assume that the input file is named numbers.
Answer: $ sort numbers > phone_list
B. Translate all occurrences of the characters [ and { to the character (, and all occurrences of the characters ] and } to the character ) in the file permdemos.c. Answer: $ cat permdemos.c | tr '[{}]' '(())'
C. Create a file named book that contains the contents of two other files: part1 and part2.
Answer: $ cat part[12] > book
5. In experimenting with shell variable, Alex accidentally deletes his PATH variable. He decides that he does not need the path variable. Discuss some of the problems he may soon encounter and explain the reasons for these problems. How could he easily return

You May Also Find These Documents Helpful

  • Powerful Essays

    Unit 3 network discovery

    • 1031 Words
    • 5 Pages

    What does the shell do while a command is executing? What should you do if you do not want to wait for a command to finish before running another command?…

    • 1031 Words
    • 5 Pages
    Powerful Essays
  • Satisfactory Essays

    What UID and PID have the highest amount of physical memory a process has used and is not swapped out? Show all processes and full output.…

    • 385 Words
    • 2 Pages
    Satisfactory Essays
  • Powerful Essays

    Hw3 7

    • 1263 Words
    • 5 Pages

    A PID number is an identification number assigned to a command running in the background, which can be used to differentiate between commands. The PS (process status) utility…

    • 1263 Words
    • 5 Pages
    Powerful Essays
  • Satisfactory Essays

    POS 420 Week 5 UNIX Paper

    • 541 Words
    • 4 Pages

    Complete the University of Phoenix Material: File Processing Commands Worksheet located on your student website.…

    • 541 Words
    • 4 Pages
    Satisfactory Essays
  • Satisfactory Essays

    Intro to Unix Project 2

    • 636 Words
    • 3 Pages

    * In the first step, I typed this command ls /etc then hit enter. A huge list of all the files in alphabetical order popped out. when I typed ls, I asked to give me the lists of the files in the current directory.…

    • 636 Words
    • 3 Pages
    Satisfactory Essays
  • Satisfactory Essays

    Unit 2 Linux Fedora

    • 560 Words
    • 3 Pages

    Unit 2 Chapter 5 1) who 3 }cp - copy files and directories mv - move (rename) files you would just basically overwrite the file 4) apropos edit Typical editors are vim, ex, ed and gedit. 8) The which utility displays a message saying that the command you are looking for is not in the list of directories in your search path. For example, $ which me /usr/bin/which: no me in (/usr/bin/which: no me in (/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/sam/bin) 10) Approximately 20 Unit 2 Chapter 6 1) 1.Is each of the following an absolute pathname, a relative pathname, or a simple filename? a. milk_co b. correspond/business/milk_co c. /home/max d. /home/max/literature/promo e. .. f. letter.0210…

    • 560 Words
    • 3 Pages
    Satisfactory Essays
  • Satisfactory Essays

    Navigating Early

    • 1990 Words
    • 8 Pages

    It is an irrational number, which means that its value cannot be expressed exactly as a fraction (when the numerator and denominator are integers). Nobody knows its exact value, because no matter how many digits you calculate it to, the number never ends. In math it’s obvious that we use PI in calculations for finding the circumference of a circle and finding areas of circles, cylinders, cones, and spheres. What most people don’t know is that PI is also used to calculate numbers that are used in different jobs: for example electrical engineers used pi to solve problems for electrical applications, statisticians use pi to track population…

    • 1990 Words
    • 8 Pages
    Satisfactory Essays
  • Satisfactory Essays

    One uses a decimal place and also one is command prompt the other is gui interface.…

    • 435 Words
    • 5 Pages
    Satisfactory Essays
  • Satisfactory Essays

    File Processing Commands

    • 354 Words
    • 2 Pages

    What UID and PID have the highest amount of physical memory a process has used and is not swapped out? Show all processes and full output.…

    • 354 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Pi's Narrative Threads

    • 550 Words
    • 3 Pages

    In the novel Pi's actual name is Piscine Molitor Patel. His gets his name from the French word for pool, which specifically is the pool in which his friend Adirubasamy used to swim in. His name itself connects to the concept of water or ocean from the onset. This connection to water is used to exemplify the theme of surviving which could be a reason he is named Pi since he survived in an ocean for 227 days. Moving on Piscline's nickname is Pi which a mathematical expression for an irrational continuous number that starts with 3.14 and then continues with a repetition of words. This repetition basically exemplifies the repetition of Pi's routine to survive on the boat. Every day he woke with one goal which was to survive, and his name adds to the theme of persistence because with the repetition and persistence he might have not survived 227 days. Moreover the mathematical expression pi is used to calculate a circumference of a circle. A circle represents unity and I think the author used to this to add to theme of unity. On the boat Pi needed to befriend Richard Parker in order to survive and maybe without him he would have not survived. More specifically I think this connection to a circle represents the Chinese symbol for Yin and Yang which cannot exist without each other. Yin represents the negative side while Yang represents the positive, in connection to the positive represents Pi who is hopeful…

    • 550 Words
    • 3 Pages
    Good Essays
  • Powerful Essays

    Caller ID allows your phone number to be sent when you make phone calls and receive a phone number when called from a service which has the facility to send CLI. Your phone number will be sent with each call you make using the Optus Mobile Digital Service or Optus Thuraya Service unless you block the…

    • 4072 Words
    • 17 Pages
    Powerful Essays
  • Satisfactory Essays

    Beginner

    • 466 Words
    • 2 Pages

    1. Is each of the following an absolute pathname, a relative pathname, or a simple filename?…

    • 466 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Study Guide GB 310

    • 5424 Words
    • 22 Pages

    is a graphic description of a process, showing the sequence of process tasks, which is developed for a specific purpose and from a selected viewpoint…

    • 5424 Words
    • 22 Pages
    Good Essays
  • Good Essays

    Process Management in Linux

    • 4243 Words
    • 17 Pages

    In Linux processes communicate with each other and with the kernel to coordinate their activities. Linux supports a number of Inter-Process Communication (IPC) mechanisms. Signals and pipes are two of them but Linux also supports the System V IPC mechanisms named after the Unix TM release in which they first appeared. Signals are one of the oldest inter-process communication methods used by Unix TM systems. The common Linux shells all allow redirection. For example $ ls | pr | lpr pipes the output from the ls command listing the directory's files into the standard input of the pr command which paginates them. Finally the standard output from the pr command is piped into the standard input of the lpr command which prints the results on the default printer. (2005,www.tldp.org)…

    • 4243 Words
    • 17 Pages
    Good Essays
  • Powerful Essays

    Horses

    • 1280 Words
    • 6 Pages

    As you can see- questions 1, 2 and 5 apply particularly well to this story…

    • 1280 Words
    • 6 Pages
    Powerful Essays

Related Topics