Better later than never, here is a hack to achieve this :
sudo ifconfig lo0 alias 127.0.0.2/32
Plug your usb drive, then via System Preferences
/ Sharing
add a smb share to a folder time-machine-macbook
in the drive time-machine-usb
Then, add a destination backup (Time Machine will see it as a network share)
sudo tmutil setdestination -a "smb://user:password@127.0.0.2/time-machine-macbook"
You can see if it's ok with:
tmutil destinationinfo
> ==================================================
Name : time-machine4
Kind : Network
URL : smb://kenji@realserver._smb._tcp.local./time-machine
ID : D820D053-C74A-4A06-A7E1-E60C8EA7934F
====================================================
Name : time-machine-macbook
Kind : Network
URL : smb://user@127.0.0.2/time-machine-macbook
Mount Point : /Volumes/time-machine-macbook
ID : F707BD0B-64DF-4DB6-A3B7-824470FB5EB2
Then start a backup with tmutil startbackup
and mount
will show:
/dev/disk3s1 on /Volumes/time-machine-usb (apfs, local, nodev, nosuid, journaled, noowners)
//user@127.0.0.2/time-machine-macbook on /Volumes/time-machine-macbook (smbfs, nobrowse)
You can see detailed progress with tmutil status
:
Backup session status:
{
BackupPhase = Copying;
ClientID = "com.apple.backupd";
DateOfStateChange = "2018-06-28 17:38:21 +0000";
DestinationID = "F707BD0B-57DC-4DB6-A3B7-824470FB5EB2";
DestinationMountPoint = "/Volumes/Time Machine Backups";
FirstBackup = 1;
Percent = "0.08711567546702646";
Progress = {
TimeRemaining = 32679;
"_raw_totalBytes" = 355694600192;
bytes = 34429528173;
files = 887351;
totalBytes = 391264060211;
totalFiles = 2922384;
};
Running = 1;
Stopping = 0;
"_raw_Percent" = "0.09679519496336274";
}
In my case, near 1000000 files were done in about two hours (USB2 disk penalty, versus more than 8 hours via Wi-Fi), I calculate percentages with a small script:
tm-progress.sh
Files : 918702 / 2922384 (31.43%) - Bytes : 32.21 GiB / 364.39 GiB (8.84%)
We can here that many files can make Time Machine to progress "slowly" in Bytes, but nearly 1/3 of files have been copied.
Next step, when backup is finished, plug the usb drive to your realserver and copy the sparsebundle over the "uncompleted one" (or in the shared folder). Of course, Time Machine should be disabled during this step to prevent mounting a partially copied sparsebundle (and maybe corrupting it)
I have used an apfs drive to benefit of snapshots (to be able to revert to a previous "backupdb" in case of sparsebundle corruption, not tested yet)
Please don't cross-post to multiple SE sites – Tetsujin – 2015-04-22T17:37:11.427
Just curious, is your laptop on Wi-Fi? What's your AP? What's your PHY rate? 7 minutes per GibiByte is like 20 megabits/sec, which would be great for 802.11g in 2003, but pretty terrible for 802.11n or 802.11ac, unless you're on a channel full of interference or a long way from the AP. – Spiff – 2015-04-22T18:48:10.127
yeah, my laptop is on Wi-Fi. I'm not sure what AP or PHY rate is. I'm in a house with 50 people who all have their own laptops, phones, etc., so there probably is quite a lot of interference. – mchen.ja – 2015-04-22T21:09:22.857