$ bosh vms
Acting as user 'admin' on 'Bosh Lite Director'
Deployment 'bui-warden'
Director task 17
Task 17 done
+----------------------------------------------+---------+-----+----------+--------------+
| VM | State | AZ | VM Type | IPs |
+----------------------------------------------+---------+-----+----------+--------------+
| bui/0 (8de8d039-40f5-44db-bc10-aba3c47b20db) | running | n/a | small_z1 | 10.244.66.61 |
+----------------------------------------------+---------+-----+----------+--------------+
$ bosh logs bui 0
Acting as user 'admin' on deployment 'bui-warden' on 'Bosh Lite Director'
Director task 14
Started fetching logs for bui/8de8d039-40f5-44db-bc10-aba3c47b20db (0) > Finding and packing log files. Done (00:00:01)
Task 14 done
Started 2017-03-13 01:55:13 UTC
Finished 2017-03-13 01:55:14 UTC
Duration 00:00:01
Downloading log bundle (2ee3018e-4246-4cb4-5dc7-db689a958cb7)...
Logs saved in '/bui-boshrelease/bui.0.2017-03-12-18-55-36.tgz'
Unpack the logs
$ tar -zxvf bui.0.2017-03-12-18-55-36.tgz
x ./
x ./bui/
x ./bui/bui.log
x ./monit/
x ./monit/monit_debugger.bui_ctl.log
x ./monit/bui.log
$ cat bui/bui.log
2017-03-13 01:50:30.94157007 +0000 UTC /var/vcap/packages/bui/bin/bui: INFO: starting bui api
$ cat monit/monit_debugger.bui_ctl.log
MONIT-DEBUG date
Mon Mar 13 01:50:30 UTC 2017
MONIT-DEBUG env
MONIT_PROCESS_PID=0
MONIT_HOST=localhost
MONIT_PROCESS_CPU_PERCENT=0
MONIT_DATE=Mon, 13 Mar 2017 01:50:30 +0000
MONIT_PROCESS_CHILDREN=0
MONIT_DESCRIPTION=Started
PATH=/bin:/usr/bin:/sbin:/usr/sbin
MONIT_PROCESS_MEMORY=0
MONIT_SERVICE=bui
PWD=/etc/sv/monit
MONIT_EVENT=Started
MONIT-DEBUG bui_ctl /var/vcap/jobs/bui/bin/ctl start
$ cat monit/bui.log
ls: cannot access /var/vcap/packages/*/lib: No such file or directory
ls: cannot access /var/vcap/packages/*/*/*.jar: No such file or directory
$PATH /var/vcap/packages/bui/bin:/bin:/usr/bin:/sbin:/usr/sbin
$ bosh logs --help
Usage: bosh [options]
--agent fetch agent logs
--job fetch job logs
--only filter1,filter2,... only fetch logs that satisfy
given filters (defined in job spec)
--dir destination_directory download directory
--all deprecated