Friday, July 17, 2015

So you want to actually restore from that Time Capsule backup? Do you feel lucky punk?

Yeah, I know he actually said “Do I feel lucky?”. But you get the point.

By now even the most hard core Apple apologist must have moments of existential doubt. Waking at 3am thinking, if only for a moment, that maybe Tim Cook really is the antichrist. 

The rest of us are moodily throwing darts at Apple stickers, wondering if Atari [3] might reconsider the personal computer market.

Time Capsule is typical of the 2015 Mac. The problems have been around for years, hope has all but vanished, and it’s possible things are even getting worse. On the other hand, there aren’t a lot of great choices for network Mac backup. Retrospect, which I loved in the days of DAT tapes and SCSI drives [1], effectively died years ago [2]. The best alternative may be Code 42’s Crashplan cloud backup, but that requires serious bandwidth (up and down) and a lot of confidence in a remote corporation. Also … java (ugh).

So I use Time Capsule for most of the machines in the house, but keep data on a server that’s also Carbon Copy Cloner cloned nightly [4]. 

This is what I do when I need to actually restore from Time Capsule [5]. If I don’t follow these steps restores will often hang and fail.

  1. Shut down every machine on my network.
  2. Power cycle my Time Capsule.
  3. Gbit ethernet connect the target machine to the Time Capsule and restart that machine.
  4. Log into my Admin account and start Time Machine.
  5. Choose a date/time as needed. Set an 5 minute time and walk away. (Trying to interact immediately will be immensely frustrating.)
  6. Navigate as desired until UI stops responding. Set an 8 minute timer and walk away.
  7. Return, select a file, and complete the Restore.

Yeah, Time Capsule has a scaling problem — restore times seem to have a non-linear relationship to the number of files on the source machine and the number of backup versions.

It’s good to have a way to proceed though. Just in case Carbon Copy Cloner isn’t enough.

Update 7/19/2015

app.net@martinsteiger writes: “Time Capsule NAS is slow and unreliable, it shouldn't be used for backup. With a NAS up to par, even with a 2-drive model from Synology like the DS21n+ models, Time Machine works fairly well.” Installing and configuring a Synology NAS isn’t terribly hard, but it’s definitely geek-realm. I agree that whatever scaling and reliability issues Time Machine has, the root problem here is mostly likely that Time Capsule is grossly underpowered for its primary function.

Update 10/20/2015

My Time Capsule’s WiFi function died, so I took the opportunity to buy a Synology and I’m testing Time Machine backup. There I read that enabling Synology’s native encryption will dramatically reduce performance. I have been using Time Machine’s native encryption for the backup of my 2009 iMac — a machine that probably lacks dedicated encryption hardware. I wonder if the awful restore performance is encryption related...

- fn -

[1] Ok, so SCSI is a good reminder that the golden age had nightmares too.

[2] I tried Retrospect again a few months ago. Wasn’t pleased. My guess is that it’s architecturally a poor fit to OS X.

[3] Atari died in 1983. They were an early competitor to the Mac and Amiga, pre-Windows.

[4] With CCC versions are archived separately. A pain to recover but it can be done. CCC can backup to a network image, but OS X Mavericks and beyond use SMB2, and SMB2 doesn’t support sparsebundle mounts. You have go through some gyrations to do an AFP mount instead. I am trying this out. I rotate my CCC backups off site across 4 encrypted drives, so I always have at least 5 backups of my data using two different technologies.

Actually, I also do Aperture backups to a local high capacity drive using Aperture’s build in backup tech. So for Aperture images I have 6 backups using three different technologies. And I know that won’t be enough ...

[5] I’ve never had to use Time Capsule for a real emergency. I’ve always been able to use my CCC clone, but I periodically test Time Capsule to see if I can make it work.

Thursday, July 16, 2015

How to view OS X hidden (unix) folders using TextWrangler

I thought there was a way to view hidden OS X Unix folders like bin, etc, home, Network, private, sbin .vol etc using Bare Bones Software's free TextWrangler but I couldn’t figure out how to do it. I wondered if this now required BBEdit, but the comparison chart didn’t mention anything.

It’s in the manual. Yeah, TextWranger, which is free, not only has Help file, it also has a (superb) manual:

Opening Hidden Files Turn on the “Show Hidden Items” option in the Open dialog to display hidden files (including both files whose invisible attribute has been set, and those whose names begin with a period) or files from a folder which is normally hidden by the system.

Screen Shot 2015 07 16 at 11 28 17 AM

When I turned it on I had to navigate the folders to force a refresh, but then they all showed.

I’d been hunting around for a preference settings, but it’s part of the Open dialog. I’ve gotten so used to utterly undocumented applications that I didn’t think to look for a manual. Google was no help … but maybe it will be after I post this.

Wednesday, July 15, 2015

Photo slide show screensaver on Mac - network share and Yosemite's reversion to default. A workaround.

I have never been happy with how OS X handles anything to do with file shares, I think Windows does a much better job.

Which, if you know anything about Windows network services, must mean I’m a raving loon. How could OS X be worse than that?

I can’t explain it. My experience is that, for no good reason, when requesting a file or folder from an OS X server, things often fail. Disabling sleep and hard drive rest helps. [4]

So it’s not surprising that using a server based photo collection with the OS X Photo Slideshow screensaver has always been problematic. I’ve really only had good success with local stores, or using local Aperture or iPhoto as the source.  I assume something hangs and OS X switches to the default photo slideshow (national geographic) screensaver, losing all memory of the screensaver you want to use.

This isn’t new, but with Yosemite it’s seems to have gotten worse [1].  Every time I opened my brand new MacBook Air on 10.10.4 I was back to National Geographic. Which is pretty, but I’ve come to hate it.

Happily, this problem is aggravating enough that there’s now a fix, which is best described in an AskDifferent post by “Flavin” (he found bug in 10.10.1, he both asks questions and answers it. I love when people return to add their answers.) The process goes like this:

  1. Set up your screensaver as desired.
  2. Run a terminal command to see the preference file values:
    defaults -currentHost read com.apple.ScreenSaverPhotoChooser
  3. Copy values into a script to write them back, where script is of the form
    defaults -currentHost write com.apple.ScreenSaverPhotoChooser … 

This is what my script looked like based on Flavi (emphases mine):

#!/bin/bash
defaults -currentHost write com.apple.ScreenSaverPhotoChooser CustomFolderDict -dict identifier \"/Volumes/ss/ss\" name ss
defaults -currentHost write com.apple.ScreenSaverPhotoChooser SelectedFolderPath \"/Volumes/ss/ss\"
defaults -currentHost write com.apple.ScreenSaverPhotoChooser SelectedSource -int 4
defaults -currentHost write com.apple.ScreenSaverPhotoChooser ShufflesPhotos -bool true

My images are in a network share /ss/ss [2]. Note in a Bash script like this quotes are escaped with slashes, hence \” to contain the string.

At this point I had the fix, but I got stuck with following the usual practice of storing it in OS X’s hidden unix file structure. TextWrangler wouldn’t show them to me [3]. So instead I put the script into a standard OS X Folder (Documents\Bash is my name) and used my favorite tip of the year: How to run a Unix shell script from the Mac Finder | alvinalexander.com. I changed the .sh extension to .command and now it’s double-clickable. No need to wrap it in AppleScript or death with BSD Unix PATH, etc.

THEN I discovered my script only worked when the remote network share was mounted. If it wasn’t mounted OS X wouldn’t mount it for me; the script would run as above but OS would fail to find the volume (“ss”) and would return to the dreaded Nat Geo. So I revised the script to mount as needed (I had a devil of a time getting mount_afp working because I didn’t understand I had to create a directory first in Volumes to be the mount point/node), and I added code to set Screensaver to Photo Slideshow borrowed from another reference.

#!/bin/bash

## Mount remote volume if not already mounted
if [ ! -d /Volumes/ss ]; then
mkdir /Volumes/ss
mount_afp afp://Thunderpaws._afpovertcp._tcp.local/ss /Volumes/ss
fi

## Set Screensaver to Photo Slideshow
/usr/bin/defaults -currentHost write com.apple.screensaver 'CleanExit' -string "YES"
/usr/bin/defaults -currentHost write com.apple.screensaver 'PrefsVersion' -int "100"
/usr/bin/defaults -currentHost write com.apple.screensaver 'idleTime' -int "300"
/usr/bin/defaults -currentHost write com.apple.screensaver "moduleDict" -dict-add "path" -string "/System/Library/Frameworks/ScreenSaver.framework/Resources/iLifeSlideshows.saver"
/usr/bin/defaults -currentHost write com.apple.screensaver "moduleDict" -dict-add "type" -int "0"
/usr/bin/defaults -currentHost write com.apple.screensaver 'ShowClock' -bool "false"
/usr/bin/defaults -currentHost write com.apple.screensaver 'tokenRemovalAction' -int "0"

## Set location of photos
defaults -currentHost write com.apple.ScreenSaverPhotoChooser CustomFolderDict -dict identifier \"/Volumes/ss/ss\" name ss
defaults -currentHost write com.apple.ScreenSaverPhotoChooser SelectedFolderPath \"/Volumes/ss/ss\"
defaults -currentHost write com.apple.ScreenSaverPhotoChooser LastViewedPhotoPath \"\"
defaults -currentHost write com.apple.ScreenSaverPhotoChooser SelectedSource -int 4
defaults -currentHost write com.apple.ScreenSaverPhotoChooser ShufflesPhotos -bool true

## Removes the .plist LaunchAgent from inside the User Launch Agent Folder.
## rm -f ~/Library/LaunchAgents/set-screensaver.plist
## killall cfprefsd

exit

Eventually I may take app.net@jws’s advice and use Watchman to fully automate a fix, but I kind of like firing this script off every time Yosemite zaps my slideshow of 100 years of family pictures.

- fn -

[1] Maybe related to this Mavericks change? It’s not the only thing that’s gotten worse over the past 1-2 years of course. My current explanation for the Hot Mess that is Apple software 2015 is that during the Jobs era and shortly thereafter Apple incurred massive technical debt and they are slowly and painfully trying to fix it, while shedding expertise like water off the proverbial duck’s back. An even more worrisome possibility is that Apple is now a typical corporation.

[2] Why the redundant ss? Historic reasons. The network share is a thumb drive sticking out of the back of a Time Capsule, so there’s no authentication needed.

To get the path of a folder just drag the finder icon into Terminal and the path will render.

[3] I’ve run into this before I think, but I can’t remember if there’s a setting I’ve missed or … what. Maybe it’s a BBEdit only feature, but it doesn’t show up in the TextWranger vs. Bbedit comparison page. Google was no help at all.

[4] I wonder if it’s because OS X often stores references to “mount points” (Volumes/…) but mount points have to be associated with network addresses, and those are not stored. Note my script should really check for the network access, not the existence of the Mount directory, but I don’t yet know how to do the former.

References

 

iOS 8.4: Spotlight not showing Bing results? Your email index may be corrupted.

Recently Spotlight stopped offering me Bing results (or Wikipedia). Power cycling the phone didn’t help. I tried the usual Spotlight fix in Settings:General:Spotlight of turning off all search results, exiting settings, confirming searches return nothing, then turning them back on. Didn’t work this time.

After a bit of experimentation I found Spotlight worked as long as I didn’t include mail search. Not unexpectedly, when I tried searching within Mail.app search would hang for at least 30 seconds (when I gave up). 

The fix was to remove all of my email accounts entirely - it wasn’t enough to simply turn mail off. I then restored them [1] and now search works within Mail.app and also within the Spotlight UI — including Bing results.

I assume Spotlight performs searches in sets, and when it got to the set containing Mail it got hung up, returning nothing and blocking returns from later sets in the execution pipeline.

I decided I don’t like getting Mail results back in search anyway, so I turned them off. I do like being able to search Mail, so the fix was important.

My spotlight enabled searches are, in order:

  • Applications
  • Contacts
  • Events (I use Calendars 5.app primarily, but I enabled Google Calendars in Calendar.app to support Event search. Sadly iOS still needs Google’s ugly SyncSelect hack. OS X doesn’t need it, so I blame this one on Apple and their (assumed) monstrous technical debt problem.)
  • Spotlight Suggestions
  • Bing Web Results (also Wikipedia)

I only use iOS Reminders for short term things (use ToDo.app) so I omitted that. Similarly I only use iOS Notes for transient items, so I omit that too (use Simplenote.app, despite it’s #$@$@ tag limitations). Messages, Voice Memos, Music, Podcasts, Videos and Audiobooks never made sense to me as items to include in Spotlight search.

[1] I had to redo my settings of course, including digging into preferences to make Google Delete when it damned well should Delete. I set it only save the last two weeks of email to reduce burden on the evidently unreliable indexing engine.

Sunday, July 12, 2015

Facebook event sharing - July 2015

Facebook Events (calendar items) exist in some sort of Facebook twilight zone. Neither completely abandoned, nor entirely useful. You can, for example, subscribe to an Event stream in Google Calendar. That’s a useful move.

Even public events are rather hard to share however. Facebook’s limited (usually obsolete) official documentation suggests copy and paste the URL. As of today this also works...

  1. View Event and choose Join.
  2. Look for the (mislabeled) Invite drop down - select it.
  3. Choose Share Event.

Monday, July 06, 2015

iOS - apps showing multiple times in search?

This is an easy one.

Do an iOS Spotlight search, see an app multiple times… means Spotlight needs to be rebuilt.

Go to Settings for Spotlight, uncheck all. Exit. Try search - nothing happens. Now add back applications, etc.

Wednesday, June 24, 2015

Porting an H2O Wireless (AT&T MVNO) to AT&T

(Original 6/24/2015, updated 64/28/2019 when ported last number to AT&T)

When I last wrote about H2O Wireless, our kids dirt cheap mobile carrier, I mentioned that our daughter’s texting costs were bringing the monthly H2O fee close to the $25/month device fee on Emily and my AT&T account. 

The move has come sooner than I’d expected, because in the process of debugging her iPhone [1] with some SIM swaps we lost all data access. I tried contacting H2O wireless to see if they had a fix, but I couldn’t get through. I didn’t try too hard — the H2O web site is increasingly clear that prepaid plans aren’t supposed to have data access. I figured we were living on borrowed time.

Our first attempt at porting failed though. I did it at an AT&T retail store; they had the impression we couldn’t port an AT&T MVNO number to AT&T because the porting software wasn’t designed for that use case.

i was going to let things lie for a bit, but then my daughter started getting 2-3 AT&T texts a day demanding she finish her porting. When I called up to stop the bloody things I was transferred to the “porting department’, where I ran into one of those miraculous people who actually know how things work.

Turns out the problem was not the MVNO to AT&T port. The problem is that nobody knows what the account number is for an H2O Wireless prepaid account. H2O’s correspondence and web site imply it’s either the phone number for the H2O phone or my phone number associated with the master account and credit cards.

Wrong. The account number is the SIM Card number, known to iOS settings or iTunes as the ICCID number. In addition you need to know a “passcode”, which is typically the last 4 digits of the ICCID number (supposedly customers can change this, perhaps from an H2O SIMd phone).

An AT&T porting center expert told me when the port was authorized, then I went back to an  the AT&T store to complete the process (create a database relationship between IEMI (phone ID) and ICCID (SIM card ID)) and pick up a new SIM. Our daughter’s phone service continued until the AT&T rep complete the process. There are a few things you need to do before completion:

  • Delete the H2O profile if you have one. This is hard to find in iOS 8; it’s in Settings:General then “Profiles”. You need the H2O profile to get data on an H2O SIMd phone, but if you don’t remove it you won’t have data posts transfer to AT&T. (You can remove it after transfer and you’ll get data.)
  • Log out of Message and FaceTime — these have their own authentication mechanism and they may get confused by the SIM swap.
  • If you’re using Google Voice for voicemail remove it. (Restore post switch or just use iPhone Visual voicemail — if Google’s directions don’t work see this page.)

On our no-contract mobile share account we were charged $15 $30 for adding the phone [Update: cost doubled between 2015 and 2019]

After you confirm voice and data services on the newly activated time enable Message, FaceTime and setup visual voicemail.

[1] An old 32GB iPhone 4S we fondly call the “DemonPhone”. It has been my primary tech support pain for years — possibly due to occult hardware issues, but also due to Apple’s bugs, DRM flaws, and hacked together online services. H2O hasn’t necessarily helped; adding a low quality and low service mobile carrier to a buggy phone puts the D in Demon.

Update 8/3/2015

Ting.com has a priceless resource on phone number porting, including H2O wireless.

  • account number is the ICCID of the SIM card
  • To find account number you need to call H2O wireless. Try 800-643-4296. They will provide you with the secret account number, it’s not available otherwise. You’ll need to provide the last 3 numbers dialed.
  • PIN is the last 4 digits of the SIM card ID/ ICCID

Because AT&T usual porting tool doesn’t work with MVNOs, or perhaps because I’m on a corporate discount account, I needed to do this at an AT&T store. It took at least 30 minutes of rep time.

Incidentally, I’m separately looking at porting a CenturyLink number to a burner phone then to Google Voice — hoping that will also kill my CenturyLink service (really, Comcast may be better, if only because more people hate them). That information is harder to find. I’ve read two theories on the CenturyLink number porting (number security) PIN both from a single source (the lack of information is a rather strong hint that CenturyLink is quite dead).

  • last four digits of account holder’s SSN
  • the 3 digits that follow the CenturyLink phone number on a billing statement (not including a letter that may follow those digits).

My guess is the SSN, but I’ll write a post about what happens.

Update 9/4/2015: What happens when you screw up a port and the number gets stuck.

Months after I wrote this I had to port another number. Unfortunately I relied on memory rather than reading my old notes; I tried the port at the store and messed it up. I should have done it through my AT&T account and just gone to the store to get a new SIM. This resulted in a stranded phone number — H2O’s account system couldn’t work with it but AT&T’s port eligibility page said it could’t be ported.

I knew H2O couldn’t fix the problem (their support staff is hapless), so I called AT&T’s porting service directly (888-898-7685) and “Darlene” fixed it. She spent about 30 minutes on hold with H2O then called me back.

I took the phone to the AT&T store, but ran into a confused rep. He didn’t understand how to finish the process. The clue was to say something like “check port status”, from that he found the right screen and quickly completed the port.