XK0-005 · Question #95
A Linux administrator needs to back up the folder /usr/domain, and the output must be a gzip compressed tar. Which of the following commands should be used?
The correct answer is C. tar -czvf domain.tar.gz /usr/domain. https://help.ubuntu.com/community/BackupYourSystem/TAR The key is passing the -z for compression. then the name of the compress file, then the path of what you want compressed. tar - is the command that creates the archive. It is modified by each letter immediately following…
Question
A Linux administrator needs to back up the folder /usr/domain, and the output must be a gzip compressed tar. Which of the following commands should be used?
Options
- Atar -cv domain.tar.gz /usr/domain
- Btar -cvf /usr/domain domain.tar.gz
- Ctar -czvf domain.tar.gz /usr/domain
- Dtar -cxzv /usr/domain domain.tar.gz
How the community answered
(28 responses)- A7% (2)
- B18% (5)
- C71% (20)
- D4% (1)
Explanation
https://help.ubuntu.com/community/BackupYourSystem/TAR The key is passing the -z for compression. then the name of the compress file, then the path of what you want compressed. tar - is the command that creates the archive. It is modified by each letter immediately following, each is explained bellow. c - create a new backup archive. v - verbose mode, tar will print what it's doing to the screen. p - preserves the permissions of the files put in the archive for restoration later. z - compress the backup file with 'gzip' to make it smaller. f <filename> - specifies where to store the backup, backup.tar.gz is the filename used in this example. It will be stored in the current working directory, the one you set when you used the cd
Topics
Community Discussion
No community discussion yet for this question.