I have a nice setup where my computers can back up with Time Machine to an AFP share over IPv6. Unfortunately I have to travel to locations that don't provide IPv6 connectivity, which means that my computer doesn't always back itself up.
To prevent this from happening I've tried to change my backup location to an AFP share with an IPv4 address but on a custom port so it can be NATted. This does not seem to be well supported as out of the box as Time Machine will fail to mount the AFP share.
You can set up Time Machine with a custom port as follows:
- Go to Finder.
- Mount your AFP fileshare with Command+K.
- Go to Time Machine properties.
- Click on your mounted file share.
- (optional but recommended) Check 'Encrypt backups'
- Press Ok
- Enter your password
- Open the Keychain Access application
- Search for an entry for your file share with
Time Machine Passwordas type.
- Double click on it to edit it.
- Name should be something like:
- Where should be something like:
- Change name to:
- Change where to:
- Tail the time machine log:
log stream --style syslog --predicate 'senderImagePath contains[cd] "TimeMachine"' --info
- Command line interface:
- Time Machine manpage: