Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1. [ BACKUP.cpio] Which of the following statement about CPIO is correct? cpio’s

ID: 3903263 • Letter: 1

Question

1. [BACKUP.cpio] Which of the following statement about CPIO is correct?

cpio’s name is derived from the phrase copy in and out, it compresses the file, and the resulting archives are compressed.

Cpio reads file and directory path names from its standard input and writes the resulting archive byte stream to its standard output.

the resulting cpio archive is a sequence of files and directories concatenated into multiple archive.

the file name of an archive is usually given the file extension gz

2. [BACKUP.cpio] Suppose your current directory is /bin, you want to put all commands starting with d to an archive file under your home directory (suppose it is /home/CSI3660).

To achieve this goal,your command should be like:

$ find d* | cpio –i > /home/CSI3660/archive.cpio

$ find d* | cpio –o > /home/CSI3660/archive.cpio

$ find d* | cp–o > /home/CSI3660/archive

$ find d* | cpio –o > /home/CSI3660/archive.gz

3. [BACKUP.cpio] In the scenario of above question, suppose you want to read the archive from its standard input and recreate the archived files under your home directory, the command should be:

cpio –o–v < archive.cpio

cp –i–v < archive.cpio

cpio –i–v < archive

cpio –i–v < archive.cpio

Explanation / Answer

1. Following are valid

cpio’s name is derived from the phrase copy in and out, it compresses the file, and the resulting archives are compressed.

Cpio reads file and directory path names from its standard input and writes the resulting archive byte stream to its standard output.

2. Option #2
$ find d* | cpio –o > /home/CSI3660/archive.cpio

3. Option #4
cpio –i –v < archive.cpio