Commit Graph
1687 Commits
Author SHA1 Message Date
Alastair Tse 515db7a43a [XEND] Fix missing serial and localtime args in device model for HVM
Signed-off-by: Alastair Tse <atse@xensource.com>
2006-12-01 10:47:57 +00:00
Ewan Mellor 6a7c1b4ee0 Fix default for the authentication on the Xen-API server -- the default should
be PAM, not none!

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-30 20:16:54 +00:00
Ewan Mellor f99727ee65 Fix managed domain rebooting by only complaining about a VM name conflict if
the VM UUID conflicts as well.

Also, remove the previous_restart_time node when explicitly rebooting a guest --
the user ought to be able to drive reboots faster than the safety catch.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-30 20:07:58 +00:00
Ewan Mellor be61b6ee05 Fix registration on managed domains on xend restart.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-30 19:11:51 +00:00
Ewan Mellor 69f4bf70a0 Fix HVM shutdown when xend is restarted.
Added a recreate call to ImageHandler, allowing the subclasses of that to
hook into the code that runs when xend restarts.  This allows us in particular
to reregister the watches for HVM shutdown, and read the PID of qemu-dm from
the store.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-30 18:08:34 +00:00
Ewan Mellor 9523b51469 Fix-up reference to name_label.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-30 18:05:19 +00:00
Ewan Mellor ac5ea23a6d Reinstate the reboot-feature code that was accidentally lost as part of the
merge in changeset 12189.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-30 17:28:51 +00:00
kfraser@localhost.localdomain 9cac7135b1 [LIBXC] Fix Solaris build: Use XC_PAGE_SIZE not PAGE_SIZE.
Signed-off-by: John Levon <john.levon@sun.com>
2006-11-30 17:36:03 +00:00
Alastair Tse c016f643db [XEND] Fix HVM configuration parsing typo for certain cfg values.
Signed-off-by: Alastair Tse <atse@xensource.com>
2006-11-30 15:41:35 +00:00
Alastair Tse 16651e108b [XEND] Catch TypeErrors when unexpected SXP is encountered.
Signed-off-by: Alastair Tse <atse@xensource.com>
2006-11-30 15:19:01 +00:00
Alastair Tse 50453c47bc [XEND] Fix Xen API attribute access to be robust to missing keys.
Signed-off-by: Alastair Tse <atse@xensource.com>
2006-11-30 14:53:14 +00:00
Alastair Tse 4b08ed154c [XEND] Checks to make sure the image type is valid in configuration
The 'builder' (eg. image type) should either be 'hvm' or 'linux' as
image.py only supports these at the moment.

Signed-off-by: Alastair Tse <atse@xensource.com>
2006-11-30 14:51:46 +00:00
Alastair Tse 3c8100f8d9 [XENAPI] Update debugging scripts to support vbd_list
Add function to list all vbds attached to a VM.
Update VM config builder to specify the default as 'linux'

Signed-off-by: Alastair Tse <atse@xensource.com>
2006-11-30 14:50:27 +00:00
Alastair Tse 75753a5ac9 [XEND] Rename Xen API methods to match case of the API documentation
Get rid of the case skewing in XendAPI.
Remove _to_xml methods because it has been removed from the latest API
docs.

Signed-off-by: Alastair Tse <atse@xensource.com>
2006-11-30 14:48:42 +00:00
Alastair Tse 71710a8321 [XEND] Fix hidden vcpu state when calling xm-list
Stores the vcpus number in xenstore so it is preserved on xend
restart.

Signed-off-by: Alastair Tse <atse@xensource.com>
2006-11-30 14:46:45 +00:00
Alastair Tse 7dc9afed06 [XEND] Remove SXP from most parts of Xend.
Attempt to get rid of most SXP dependency in Xend except in
configuration parsing and certain places where it is
required.

XendConfig now stores configuration options similar to Xen API VM
and devices attributes but exports an SXP version to certain things
like xm and XendCheckpoint. All access to VM and device attributes
should now use Python dictionaries rather than the SXP parser.

Signed-off-by: Alastair Tse <atse@xensource.com>
2006-11-30 14:44:58 +00:00
Ewan Mellor 001bc372b4 Fix xm new -F -- this fix was recently introduced for xm create.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-29 12:16:19 +00:00
Ewan Mellor dcf51b3413 Move the assert under the protection of the in_transaction flag.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-29 12:15:45 +00:00
Ewan Mellor 26c7d28635 Silence log message when trying to unregister a watch that's already been
unregistered -- this is not a problem.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-29 12:14:45 +00:00
Ewan Mellor bf9423a1fd Diagnose a failure to open the xend-debug.log, and make the /var/log/xen
directory on startup, which was the most common reason to fail.
Closes bug #823.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-29 10:56:02 +00:00
Ewan Mellor b496644a2b A trivial fix. login_unconditionally needs to be called with
self.login_unconditionally to avoid  "global name
'login_unconditionally' is not defined"

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2006-11-28 18:41:42 +00:00
Ewan Mellor ea3b5838d8 Wait for device-bringup inside domain_start, outside the scope of the
domains_lock.  This makes the VM.start call blocking, but allows xm list to
work while it is blocked.  Move the handling of start_paused out of
XendDomainInfo.start as part of this.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 18:00:45 +00:00
Ewan Mellor 592da6d9ee Plumb the "start_paused" flag through for VM.start and VM.resume. Do not
unpause the VM on start by default.  This should fix problems seen recently
whereby devices are not attached to the VM by the time they boot, as
xm create was expecting to be able to wait for the devices before unpausing.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 17:28:43 +00:00
jfehlig@jfehlig2.provo.novell.com f7bd1801f8 Fix casing of various functions in XendAPI class.
Signed-off-by: Jim Fehlig <jfehlig@novell.com>
2006-11-14 15:36:41 -07:00
Ewan Mellor caf550ed59 Dummy implementation of get_platform_keymap, so that the API layer doesn't
complain.  This is going to change soon, I expect.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 16:23:05 +00:00
Ewan Mellor 44755869f7 Bump xend_config_format to 3, to indicate that the lifecycle patches are
available.

Better version mechanisms will be forthcoming!

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 14:24:20 +00:00
Ewan Mellor a6878f4ab4 Added xm list --state option, to select VMs with a particular state. Make
this handled by a new message (xend.domains_with_state) and make xend.domains
equivalent to xend.domains_with_state(running).  This restores the Xen 3.0.3
semantics of xend.domains.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 13:34:15 +00:00
Ewan Mellor 8cff4a9583 Do not display -1 as the domid when a VM is not running -- simply leave the
column blank.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 13:32:07 +00:00
Ewan Mellor dcce57e533 Fix missing import.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 11:43:43 +00:00
Ewan Mellor 8e37e2b661 Don't bail if the VM renaming at the end of saving doesn't succeed -- we
expect a failure if this is a localhost migration.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 11:35:10 +00:00
Ewan Mellor 2e873d3d17 Added configuration for authentication through Xen-API -- it can now be set
to use PAM, or to be turned off entirely, on a listener by listener basis.

Listen on a different unix domain socket for the Xen-API server, so that it
can co-exist with the others.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 11:31:46 +00:00
Ewan Mellor 46873848fb Fix log message.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 10:24:52 +00:00
Ewan Mellor 027a790317 Implement an "allowed hosts" mechanism for the XML-RPC server layer, using
code from the relocation protocol handling and some plumbing.  Add a new
configuration entry for the Xen-API server, including use of this mechanism.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-28 10:23:34 +00:00
Ewan Mellor 1c06df3dbb Cope with non-integer domids (i.e. None) in the error message surrounding
save/restore.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-27 20:04:20 +00:00
kfraser@localhost.localdomain da38d1f64b [HVM] Re-introduce the 'apic' configuration option, default to 1.
Also simplify the HVM builder interface by doing more work in
the python wrapper, and fix mapping of shared_info page after the
change to map foreign pages by GMFN rather than MFN.

Signed-off-by: Keir Fraser <keir@xensource.com>
2006-11-27 17:49:41 +00:00
Ewan Mellor 7a914ac673 When suspending and resuming, look up the managed path using the domain's UUID.
Add a resumed domain to the self.domains list after XendCheckpoint.restore,
to ensure that it does not get recreated immediately afterwards.

Perform domain_resume under the domains_lock, given that the domain needs to
be added.

These fixes together should fix xm suspend and xm resume.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-27 14:52:41 +00:00
Ewan Mellor 283b2fa4e8 Don't send the old state string for halted domains -- it doesn't make any
sense, and we don't want to see state flags linger.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-27 14:48:38 +00:00
Ewan Mellor b12b62c2fd Reset the domain name after the save completes. This is necessary, now that
we have persistent domains.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-27 14:47:23 +00:00
Ewan Mellor b05e41a16b Add xm resume to the commands list.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-27 14:45:44 +00:00
Ewan Mellor ba2055b085 Fix typo.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-27 12:53:40 +00:00
Ewan Mellor 168c198485 Do not bother waiting for the old HttpServer and UnixHttpServer threads when
shutting down -- they don't have exit handling themselves and ought to just
be made daemon threads.

Added some logging to dialog shutdown problems.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-27 12:50:30 +00:00
Ewan Mellor a057ff078b Fix vncdisplay handling.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-24 14:05:59 +00:00
Brendan Cully acc3cc66f7 Add -p/--paused flag to xm restore.
When --paused is specified, the domain is paused after it is loaded.

Signed-off-by: Brendan Cully <brendan@cs.ubc.ca>
2006-11-21 18:09:23 -08:00
jfehlig@jfehlig2.provo.novell.com 3206f975b8 The legacy apis return a value of None on success, which was being converted to a value of 'nil' in the xmlrpc response.
The Xen IPI spec states that destroy, hard_shutdown, pause, resume, start, suspend, and unpause return void.  This patch makes it so and permits proper parsing of the response by clients (libxen) that follow the spec.

Signed-off-by: Jim Fehlig <jfehlig@novell.com>
2006-11-17 16:21:14 -07:00
Ewan Mellor 7b0a6bf9f4 Stop the kernel and ramdisk from being nuked if the kernel_external bootloader
setting is being used.

From Jim Fehlig <jfehlig@novell.com>.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-22 14:01:51 +00:00
Ewan Mellor 3b724073d6 The legacy HTTP entry point for Xend remote access didn't hook the
dump operation for a domain, this patch adds it.

Signed-off-by: Daniel Veillard <veillard@redhat.com>
2006-11-21 17:34:17 +00:00
Ewan Mellor f90beca56e Added an xm console -q flag.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2006-11-21 11:21:20 +00:00
Ewan Mellor 50420def5b This is a refactored version of a previous patch that destroys external
devices' state when a VM configuration file is destroyed. Currently only
the vTPM device's state needs to be explicitly destroyed.
I am also surrounding the saving of the managed domain's configuration
with a try-catch.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2006-11-21 10:22:19 +00:00
Ewan Mellor 7443d72fde A small fix to the documentation to reflect recent changes to the
'cfgbootpolicy' command.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2006-11-21 10:21:00 +00:00
Ewan Mellor 32562d7bec There is a somewhat trivial issue with XendCheckpoint.py right now in
that it logs everything written to stderr by xc_save and xc_restore as
errors whereas in fact the vast majority of this output is
information/debug (and all actual errors are marked by the string ERROR:
at the start of the message) -- this is confusing to folks looking at
the logs and makes automated log analysis tricky.

Fix is to scan for the ERROR: string and log anything without it using
log.info instead.

Signed-off by: Simon Graham <Simon.Graham@stratus.com>
2006-11-21 10:19:01 +00:00