Showing posts with label backup. Show all posts
Showing posts with label backup. Show all posts

Time Machine hangs? Spotlight responsible?

Time Machine and Spotlight run slowly over wireless...

So slowly, that it appears that the system has hung.

Time Machine is great — but ...

Making the first backup of a 60GB of data takes a very long time over wireless.

Making a large incremental backup, after being away for a week, or more takes a very long time over wireless. Even over 802.11n I find Time Machine, backing up over my WDS, manages about 1MB/sec. Say 1GB takes 16 minutes, then 60GB takes 16 hours!

If Spotlight is indexing the backup while the backup is changing, things go even slower.

Solution: For the first backup, or for an incremental backup after you've been on the road, first turn of Spotlight indexing for the backup. Then connect your Mac by ethernet cable directly to the LAN port on the Time Capsule, and leave it to chunter away overnight. Finally, turn indexing on to let Spotlight digest the backup.

To see what Time machine and Spotlight are up to, use the console to inspect the logs. Set the filter so you see messages from backupd. You should see a sequence of messages appear slowly (but no longer very slowly), like this:

 Starting standard backup  Network volume mounted at: /Volumes/Data  Disk image /Volumes/Data/myMacBook0016cb896cb9.sparsebundle mounted at: /Volumes/Backup of myMacBook  Backing up to: /Volumes/Backup of myMacBook/Backups.backupdb  No pre-backup thinning needed: 2.21 GB requested (including padding), 801.41 GB available  Copied 22 files (24.4 MB) from volume Macintosh HD.  Starting post-backup thinning  No post-back up thinning needed: no expired backups exist  Backup completed successfully. 

Each line starts with date and time and the label /System/Library/CoreServices/backupd[22205]

Note:

Spotlight should be allowed to index your backup — so that you can find valuable nuggets of information lost in the past. Spotlight is also very slow if it has to index 60GB over wireless — if you do this, your log may also include lines like:

 Waiting for Spotlight to finish indexing /Volumes/Backup of myMacBook/Backups.backupdb 

The solution is the same — when Spotlight has lots of changed stuff to index in the backup, let it work over ethernet. If you unplug and go wireless immediately your big backup is done, Spotlight will spend a long time catching up — and it won't let the next hourly backup begin until it has caught up.

Spotlight crashes

In addition, spotlight crashes: mdworker does the Spotlight indexing — you may find messages like this:

 Formulating crash report for process mdworker[22921]  (0x10c720.mdworker[22921]) Exited abnormally: Bus error  

When this happens, it slows things down even more. It's a bug — every crash is a bug. Some discussions suggest that it may by triggered when Spotlight attempts to index ill-formatted emails.

You can tell Spotlight not to index emails — and it may have some effect. Waiting patiently also seems to work — and I need to be able to search for mail by content, so I have to let Spotlight index my mail.

Wireless again

As long-time readers of this blog will know, I have an extended wireless network. It now includes two daisy-chains and one spur: a daisy-chain on 802.11n (5GHz) with a TimeCapsule (which has internet connection from my ADSL modem/router) and two Extremes; a daisy-chain on 802.11g (2.5GHz) with older kit — two Extremes (one connected by ethernet to the remote end of the 802.11n chain) and three Expresses.

Autoconfigure was a welcome feature of the 802.11n Express. It was great — when it worked — but it was always flakey.

With the 7.4.1 firmware update my setup became completely unstable. In particular, whenever Time Machine started a backup the network would auto-reconfigure, and break. I had to use an ethernet connection direct to the Time Capsule to make a backup. I've now reverted to a manual setup of the WDS with explicit MAC numbers. All appears stable, my iPhone is back on WiFi and backup over wireless is working again.

If you're having problems with an autoconfigured wireless network, try going back to manually configured WDS. Use Airport Utility. First make a note of the Airport ID (MAC number) for each of your devices. Then, one-by-one switch from Create a Wireless Network or Extend a Wireless Network to Participate in a WDS Network. A WDS tab will appear. Under this tab you can see (and manually adjust) the autoconfigured setup. In my case I found that two Extremes were trying to act as WDS main.

As usual, be careful to update the various access points in an order that doesn't leave you unable to access some device over wireless. If you do get into that sorry state, a direct ethernet connection can be used to reconfigure the lost device.