Lets assume that we have a guest VirtualBox machine called "xp". To start it in a headless mode we can use
VBoxHeadless --startvm "xp"
To stop it we can use
VBoxManage controlvm "xp" savestate
Since it is in a headless state we have to access it using a RDP viewer, e.g. rdesktop command in Linux:
desktop -u username -p password -a 16 serverIP
Of course, before we can use it in this way, we have to enable remote destkop for the "xp" machine and define authentication method. In my case, I used External method, since it uses the linux user account under which my VirtualBox is running.