Is there a way to boot Ubuntu 16.04 into command line only (do not start GUI)?

I haven’t tried this on a TX2 yet, but see if this works:

sudo systemctl disable lightdm.service
sudo systemctl stop lightdm.service
sudo chmod -x /usr/sbin/lightdm