A file system has a root directory containing two entries: homestar and strong, both directories. The homestar directory contains an entry for a regular file named txt. We can represent the current state of the system as follows: file #     type           contents------     ----           --------1         directory     . -> 1                              .. -> 1                              homestar -> 2                              strong -> 32         directory     . -> 2                               .. -> 1                              txt -> 43         directory     . -> 3                              .. -> 14         regular file   (contents of file)   The symlink system call creates a directory entry that contains the path name of the file being linked to, rather than a file number. For example, after executing symlink(/homestar, /strong/mad), The contents of directory 3 would look like this: 3        directory     . -> 3                              .. -> 1                              mad -> /homestar Show the changes to the state of the file system after each of the following operations is executed in succession. link(/homestar/runner.txt, /strong/bad.txt) symlink(/homestar/runner.txt, /strong/sad.txt) unlink(/homestar/runner.txt) mkdir(/trogdor) create(/trogdor/burninator.txt)

Question
  1. A file system has a root directory containing two entries: homestar and strong, both directories. The homestar directory contains an entry for a regular file named txt. We can represent the current state of the system as follows:
  • file #     type           contents
    ------     ----           --------
    1         directory     . -> 1
                                  .. -> 1
                                  homestar -> 2
                                  strong -> 3

    2         directory     . -> 2
                                   .. -> 1
                                  txt -> 4

    3         directory     . -> 3
                                  .. -> 1

    4         regular file   (contents of file)

 

  • The symlink system call creates a directory entry that contains the path name of the file being linked to, rather than a file number. For example, after executing symlink(/homestar, /strong/mad), The contents of directory 3 would look like this:
  • 3        directory     . -> 3
                                  .. -> 1
                                  mad -> /homestar
  • Show the changes to the state of the file system after each of the following operations is executed in succession.
    • link(/homestar/runner.txt, /strong/bad.txt)
    • symlink(/homestar/runner.txt, /strong/sad.txt)
    • unlink(/homestar/runner.txt)
    • mkdir(/trogdor)
    • create(/trogdor/burninator.txt)

Expert Answer

Want to see the step-by-step answer?

Check out a sample Q&A here.

Want to see this answer and more?

Experts are waiting 24/7 to provide step-by-step solutions in as fast as 30 minutes!*

*Response times vary by subject and question complexity. Median response time is 34 minutes and may be longer for new subjects.

Related Computer Science Q&A

Find answers to questions asked by students like you.

Q: Suppose you want to build a program using WebGL that draws two kinds of objects - shiny billiard bal...

A: Drawing multiple objects in WebGLIn order to draw two kinds of objects in WebGL, first call function...

Q: ABC Accounting Company is a company that manages the financials for various small companies on a nat...

A: 1) To prevent remote employees from being hacked, the following steps can be taken:A Virtual private...

Q: Forest and domain functional level means Windows Operating System version. which one applies? Member...

A: Explanation:A Windows Server 2008 functional level requires that all the Domain Controller (DC)s mus...

Q: Excel Project How do create a formula to calculate daily totals in dollars. Multipy the value in the...

A: Excel is a software program developed by Microsoft. Excel has an electronic spreadsheet to organize ...

Q: DISCUSS THE BLOCKCHAIN TECHNOLOGY?

A: What is BLOCKCHAIN: ⦁ As its name suggests, its a chain of blocks or a growing list of records (reco...

Q: "Simon Says" is a memory game where "Simon" outputs a sequence of 10 characters (R, G, B, Y) and the...

A: Program Algorithm-STARTStep1:Import the essential headers.Step2: Declare the main function.Step3: De...

Q: 3. Write a program that deliberately contains an endless or infinite while loop. The loop should gen...

A: Following is the java program:variables used:z is used to store the result of the multiplication of ...

Q: For the following problems assume 1 kilobyte (KB) 1024 kilobytes. 1024 bytes and 1 megabyte (MB) For...

A: a) Bits in offset = log2(page size)Given, every byte in the page have a unique address so we have co...

Q: Using the code in part I of this lab (included below): 1. Create a function to INPUT the information...

A:  Create a function INPUT which takes a structure variable as parameter.Pass structure variable using...