nerdexam
CompTIA

XK0-005 · Question #343

A system administrator is setting up a cron job that will copy thousands files from a remote directory on a scheduled basic. The file contents should retain their original permissions, including and…

The correct answer is A. Rsync. The question requires identifying the most efficient tool for scheduled remote file synchronization that preserves metadata.

Scripting, Containers, and Automation

Question

A system administrator is setting up a cron job that will copy thousands files from a remote directory on a scheduled basic. The file contents should retain their original permissions, including and group ownership, and the cron job should run for the least amount of the possible. Which of the following is the BEST program to use in this situation?

Options

  • ARsync
  • BCurl
  • CScp
  • DWget
  • Esftp

How the community answered

(20 responses)
  • A
    75% (15)
  • B
    5% (1)
  • C
    5% (1)
  • E
    15% (3)

Why each option

The question requires identifying the most efficient tool for scheduled remote file synchronization that preserves metadata.

ARsyncCorrect

Rsync is the best tool for this scenario because it efficiently transfers files, only copying changes between source and destination, and crucially preserves file permissions, ownership, and timestamps. This minimizes transfer time and ensures data integrity during scheduled synchronizations.

BCurl

Curl is primarily used for transferring data with URLs and retrieving content from web servers, not for efficient file synchronization with metadata preservation.

CScp

Scp (secure copy) is suitable for copying files securely, but it copies entire files even if only small changes exist, making it less efficient than rsync for synchronization.

DWget

Wget is a non-interactive network downloader that retrieves files from web and FTP servers, but it lacks the synchronization capabilities and metadata preservation of rsync.

Esftp

Sftp (SSH File Transfer Protocol) provides secure file transfer capabilities, but it typically transfers whole files and lacks the delta-transfer efficiency and comprehensive metadata preservation features of rsync.

Concept tested: Efficient remote file synchronization with metadata preservation

Source: https://rsync.samba.org/documentation.html

Topics

#File synchronization#Rsync#Cron jobs#File permissions

Community Discussion

No community discussion yet for this question.

Full XK0-005 Practice