Re: [Libvir] [patch 4/7] Add autostart QEMU implementation

On Tue, Feb 20, 2007 at 07:26:31PM +0000, Mark McLoughlin wrote:
Actually implement the autostart API in qemud by saving autostart configs to a specific directory.
I think its desirable to keep all the master config files in the same directory, because it gives a sanity check of name uniqueness for files. Instead just create a symlink into the autostart directory in the same way the XenD recommendation works. So setting/getting autostart flag is just a matter of stat()'ing the symlink or using symlink()/unlink() to change it. Dan. -- |=- Red Hat, Engineering, Emerging Technologies, Boston. +1 978 392 2496 -=| |=- Perl modules: http://search.cpan.org/~danberr/ -=| |=- Projects: http://freshmeat.net/~danielpb/ -=| |=- GnuPG: 7D3B9505 F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 -=|

On Tue, 2007-02-20 at 19:36 +0000, Daniel P. Berrange wrote:
On Tue, Feb 20, 2007 at 07:26:31PM +0000, Mark McLoughlin wrote:
Actually implement the autostart API in qemud by saving autostart configs to a specific directory.
I think its desirable to keep all the master config files in the same directory, because it gives a sanity check of name uniqueness for files. Instead just create a symlink into the autostart directory in the same way the XenD recommendation works. So setting/getting autostart flag is just a matter of stat()'ing the symlink or using symlink()/unlink() to change it.
Yeah, I considered doing that but pretty much hated the idea ... but for no real concrete reason. One good reason to use symlinks might be the failure case in SetAutostart() - you don't have to worry about failing to delete the old config file. I'll hack it up tomorrow. Cheers, Mark.
participants (2)
-
Daniel P. Berrange
-
Mark McLoughlin