Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

LPI 010-160 Exam - Topic 1 Question 66 Discussion

Actual exam question for LPI's 010-160 exam
Question #: 66
Topic #: 1
[All 010-160 Questions]

Which of the following commands extracts the contents of the compressed archive file1.tar.gz?

Show Suggested Answer Hide Answer
Suggested Answer: C

The correct command to extract the contents of the compressed archive file1.tar.gz istar -xzf file1.tar.gz. This command uses the following options:

-xmeans extract files from an archive.

-zmeans filter the archive through gzip, which is a compression program that reduces the size of files.

-fmeans use the following archive file name, which is file1.tar.gz in this case.

The other commands are incorrect for the following reasons:

tar -czf file1.tar.gzcreates a compressed archive file1.tar.gz from the files specified after the command, not extract it.

ztar file1.tar.gzis not a valid command, as ztar is not a standard program or option for tar.

tar --extract file1.tar.gzis missing the-zoption to handle the gzip compression, and also the-foption to specify the file name.

detar file1.tar.gzis not a valid command, as detar is not a standard program or option for tar.


Linux Essentials - Topic 106: The Linux Operating System, section 106.2 Use single shell commands and one line command sequences to perform basic tasks on the command line.

LPI Linux Essentials Study Guide: Exam 010 v1.6, 3rd Edition, Chapter 5: Working with Files and Directories, section Compressing and Archiving Files.

Contribute your Thoughts:

0/2000 characters

Currently there are no comments in this discussion, be the first to comment!


Save Cancel