Green’s Dictionary of Slang

captain’s log n.

[rhy. sl. = bog n.1 ; presumably linked to the cult TV series Star Trek, each episode of which began with the intonation ‘Captain’s Log, Stardate…’]

a lavatory.

[UK]R. Puxley Fresh Rabbit.
[UK]B. Dark Dirty Cockney Rhy. Sl. 33: Constipation? I’ve been sitting on the captain’s log for an hour and nothing’s happened.