Is there a Log file with the log entries I can just grab?
No. The native log format is not a log file but rather a .logarchive
package. Run log collect
on your Mac to generate an example. And the OSLog framework does not give you access to such a package, nor does it let you create one (although you can read one using +[OSLogStore storeWithURL:error:]
, but that’s not terribly useful on iOS).
what is the recommended way of getting the logs off the device?
I don’t think we have a recommended way. The folks who’ve been asking for this feature generally have an existing log infrastructure and they want to integrate system log entries with that. If you don’t have existing infrastructure, you’ll have to create that first, and how you do that is very much up to you.
If I were in your shoes I’d look at the various log styles supported by the --style
argument in the log show
command on the Mac. Using one of those formats seems like a good way to foster commonality between your in-the-field logging and your day-to-day debug logging. For more info on this, see the log
man page.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"