#!/bin/bash ( sleep 1 echo '{"execute": "qmp_capabilities"}' echo '{"execute":"query-spice"}' echo '{ "execute": "quit" }') | qemu-system-x86_64 -spice port=9999 -qmp stdio