Step 7 of 8 · lab · 25 min
Bring a directory mirror up to date (rsync)
A directory mirror has fallen behind its source. Make it an exact copy and leave both the source and the neighbouring data intact.
Situation
~/sync-lab/mirror is a mirror of the ~/sync-lab/source directory that nobody has refreshed in
a while. Tomorrow the data moves from the mirror to a standby server, so the mirror has to match
the source byte for byte. Next to them, ~/sync-lab/keep holds data that has nothing to do with
the mirror.
Task
Make mirror an exact copy of the contents of source:
mirrorhas the same files and directories assource, hidden ones included, and nothing extra;- every file's contents, mode, owner and modification time match
source; - a dry-run sync from
sourceintomirrorthat compares contents finds no differences; sourceandkeepare left as they were.
Constraints
- You may delete things only inside
mirror. - Work as your own user; this task needs no
sudo.
Lab · on your own
No commands are given in this lab: type them in the terminal yourself. Goals are checked on the machine after every command.
Goals
0 of 4-
mirror has the same files and directories as source, hidden ones included, and nothing extra — not done yet
-
File contents, modes, owners and modification times match source — not done yet
-
A dry-run sync from source into mirror that compares contents finds no differences — not done yet
-
source and keep are left as they were — not done yet
Ctrl+Enter
Starts the machine node1 · Ubuntu 24.04
The machine is starting
Hints
0 of 3Lab goals
0 of 4-
mirror has the same files and directories as source, hidden ones included, and nothing extra — not done yet
-
File contents, modes, owners and modification times match source — not done yet
-
A dry-run sync from source into mirror that compares contents finds no differences — not done yet
-
source and keep are left as they were — not done yet
Goals are checked on the machine after every command.