Can I see the full command line arguments used by the qemu driver?

Hey folks,

I’m trying to boot a VM with the following configuration:

        task "runner" {
            driver = "qemu"
            config {
                image_path        = "local/ci.qcow2"
                graceful_shutdown = true
                args              = ["-no-user-config"]
            artifact {
                source = "s3::http://lightsoutgames-minio-minio-minio.service.consul:9000/vms/ci.qcow2.bz2"
                destination = "local/ci.qcow2"
                mode = "file"
                options {
            resources {
                cpu    = 2000
                memory = 4000

The VM downloads and qemu-system-x86_64 tries to launch it, but complains that no bootable devices were found.

There’s a lot that could be going on here, but to start troubleshooting, I’d really like to see the full command line Nomad is trying to run this VM with. I poked around in the cmdline file for the relevant process in /proc, but either it is incomplete or isn’t displaying fully on the console.

Is there any way I can get the full command line so I can tweak it until it works? Or additionally, is anything obviously wrong with my config? I did convert this VM image from VMWare, so it’s possible I messed something up with that. But Nomad is definitely passing in more command line args than I’ve specified, so I think my first step is to figure out exactly what it sends along.


Howdy @nolan :wave: When the QEMU driver starts up it will emit a DEBUG-level log event that contains the command in the args value.

2021-05-14T14:33:52.865-0400 [DEBUG] client.driver_mgr.qemu: starting QemuVM command : driver=qemu args="/usr/bin/qemu-system-x86_64 -machine type=pc,accel=tcg -name tinycore.qcow2 -m 300M -drive file=local/tinycore.qcow2 -nographic -device e1000,netdev=user.0 -netdev user,id=user.0,hostfwd=tcp::23867-:80,hostfwd=tcp::24639-:22"
2021-05-14T14:33:52.865-0400 [DEBUG] client.driver_mgr.qemu.executor: starting plugin: alloc_id=0724b819-2947-940a-f504-0198a7ecf63d driver=qemu task_name=t1 path=/opt/nomad/bin/nomad-v0.12.8 args=[/opt/nomad/bin/nomad-v0.12.8, executor, {"LogFile":"/opt/nomad/data/alloc/0724b819-2947-940a-f504-0198a7ecf63d/t1/t1-executor.out","LogLevel":"debug","FSIsolation":false}]

You can use the nomad monitor -log-level=DEBUG command to watch the log at DEBUG level if your configuration uses a higher log level for normal logging.

Hopefully that helps!