In my fit I don't have any primary CMB data (no TT/TE/EE measurements), however I do have the Planck 2015 CMB lensing phi-phi power spectrum, and am allowing some freedom in tau because I noticed it made some difference to this likelihood. I see tau is fixed in batch2/lensonly.ini, so I will rerun with fixed tau to see if that helps. But what's the reason this error comes up?

I'm not sure why you are seeing this with those parameters - usually this error means that tau was accidentally unconstrained. Or possibly some other parameter is in some crazy part of parameter space.

Hmm, in my fit the baryon density was not being well constrained. Maybe that was the problem.

Do you know why the Planck lensing likelihood depends on tau (i.e. the chi2 changes if I hold other params fixed but shift tau)? Is it because there's a bias subtraction that depends on the primary CMB fluctuations? I haven't touched any of the reionization assumptions.

The N1 bias and normalization of the estimator are corrected for deviations from the assumed fiducial model, so there is some dependence on all parameters. I'd have thought it should be a rather weak dependence on tau, at least within the usual posterior range.