aboutsummaryrefslogtreecommitdiffstats
path: root/tools/python/scripts
Commit message (Collapse)AuthorAgeFilesLines
* xend: Remove old vtpm support from xmMatthew Fioravante2012-11-191-20/+0
| | | | | | Signed-off-by: Matthew Fioravante <matthew.fioravante@jhuapl.edu> Acked-by: Ian Campbell <ian.campbell@citrix.com> Committed-by: Ian Campbell <ian.campbell@citrix.com>
* tools: Always use sane upstream (`native') python pathsKeir Fraser2009-04-083-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, by default we would install our python modules into /usr/lib/python/xen, for example /usr/lib/python/xen/__init__.py. Upstream python's standard install location (a) includes the Python version number and (b) puts things in site-packages by default. Our best conjecture for the reason for this was an attempt to make the installs portable between different python versions. However, that doesn't work because compiled python modules (.pyc), and C python extensions corresponding to one version of python, are not compatible across different versions of python. This is why upstream include the version number. site-packages is the standard location for locally-installed packages and is automatically included on the python search path. In this change, we abandon our own unusual python path setup: * Invoke setup.py in an entirely standard manner. We pass PREFIX and DESTDIR using the appropriate options provided by setup.py for those purposes (adding them to setup.py calls which were previously lacking them). * Since the installation locations are now on the standard python path, we no longer need to add anything to the path in any of our python utilities. Therefore remove all that code from every python script. (Many of these scripts unconditionally added /usr/lib/python and /usr/lib64/python which is wrong even in the old world.) * There is no longer any special `Xen python path'. xen-python-path is no longer needed. It is no longer called by anything in our tree. However since out-of-tree callers may still invoke it, we retain it. It now prints a fixed string referring to a directory which does not to exist; callers (who use it to augment their python path) will thus add a nonexistent directory to their python path which is harmless. * Remove various workarounds including use of setup.py --home (which is intended for something completely different). * Remove tests for the XEN_PYTHON_NATIVE_INSTALL build-time environment variable. The new behaviour is the behaviour which we should have had if this variable had been set. That is, it is now as if this variable was always set but also bugs in the resulting install have been fixed. This should be a proper fix for the bug addressed by c/s 19515. Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
* Replace VDI.location with a more generic VDI.other_config map. RemoveEwan Mellor2007-03-174-16/+7
| | | | | | | | VDI.sector_size. Xend work by Tom Wilkie <tom.wilkie@gmail.com>. Signed-off-by: Ewan Mellor <ewan@xensource.com>
* Redefine units of VDI.virtual_size to be bytes, not sectors.Ewan Mellor2007-02-253-4/+4
| | | | Signed-off-by: Ewan Mellor <ewan@xensource.com>
* [XENAPI] Remove some deprecated fields from the Xen API test script.Alastair Tse2007-01-312-15/+5
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Merge VFB support for PV and HVM guests.Alastair Tse2007-01-313-3/+26
| | | | | | | | | | | | | | | | | | | | | | This patch merges the way VFB are represented inside Xend by making HVM VNC consoles use the VFB as its configuration object. It preserves the way options are specified through xm but will create a new VFB device that is used by image.py to put vnc config into qemu-dm's command line. The parsing is moved into image.py's parseDeviceModel() rather than in configVNC(). Through the Xen API, you can create a 'console' of protocol 'rfb' and end up with a VNC console, on both HVM and PV guests. The location of the connecting port is stored in the location attribute of the console object. This is updated on each XendDomainInfo.update() if it changes. Also fixes missing read of the vnclisten and HVM_boot from the config when initialised via xm. Makes sure bootable attribute for VBD is store as an int when making SXP config. Signed-off-by: Alastair Tse <atse@xensource.com>
* Align vTPM support in the Xen-API, documentation and lib-xenkaf24@localhost.localdomain2007-01-301-8/+0
| | | | | | (after the recent changes). Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
* [XENAPI] Add an example to start HVM guests via the Xen API.Alastair Tse2007-01-261-0/+173
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Make server uri easily configurable via ENV or CLI opts.Alastair Tse2007-01-261-11/+84
| | | | | | Add a vm-stat command that just polls a vm for instantaneous statistics. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Preliminary console support in Xen APIAlastair Tse2007-01-251-1/+28
| | | | | | | Made serial/vnc consoles a 'fake' device so that we can take advantage of storing state information in xenstore. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Add debug class to Xen API plus non-standard debug.wait().Alastair Tse2007-01-241-1/+1
| | | | | | | debug.wait(seconds) will just do a time.sleep() so the task progress support can be tested. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Make test script attempt to login with blank credentialsAlastair Tse2007-01-241-5/+23
| | | | | | before prompting for passwords. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Add vif-list to xapi.py scriptAlastair Tse2007-01-241-10/+23
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Update test scripts to move from VBD.image to creating VDI'sAlastair Tse2007-01-242-22/+60
| | | | | | with the uri attribute. Signed-off-by: Alastair Tse <atse@xensource.com>
* Test scripts for Xen API updated to support Async supportAlastair Tse2007-01-242-108/+423
|
* [XEND] Add simple VCPUs, VBDs, VIFs statistics monitoringAlastair Tse2007-01-241-0/+6
| | | | | | Keep track of xentop like statistics to expose through the Xen API Signed-off-by: Alastair Tse <atse@xensource.com>
* Add support to list VDIs and SRs in xapi.pyAlastair Tse2007-01-051-25/+70
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Re-add vtpm device support in XendConfigAlastair Tse2006-12-011-2/+0
| | | | | | | | This patch re-adds a recently removed vTPM device handling code. I am also removing that one code part in the test script that does not work. Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
* [XENAPI] Add extra param for VM.start and fix case for printing outAlastair Tse2006-12-011-3/+3
| | | | | | the output of VM.get_record. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Update debugging scripts to support vbd_listAlastair Tse2006-11-302-7/+33
| | | | | | | 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>
* [XENAPI] Make xapi.py work with modules in /usr/lib/python.Alastair Tse2006-11-101-1/+17
| | | | | | Also Add host_set_name command. Signed-off-by: Alastair Tse <atse@xensource.com>
* The attached patch implements more of the Xen-API functionality relatedEwan Mellor2006-11-093-4/+34
| | | | | | to the vTPM. Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
* Import 83:b569bb25a8f08a15381b022ee143d7f205976604 from xen-api.hg, minus theEwan Mellor2006-11-011-11/+21
| | | | | | | | | | | | | | Makefile patch. [XEND] Remove blank image file generation for QCOW images. There is no need for a blank backing store, although this means we have to find a new way to determine how much virtual disk space is free in the StorageRepository. Beginnings to attempt to supoprt HVM guests. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Add shell option for xapi.py so it can remember sessions.Alastair Tse2006-10-203-20/+81
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Switch to PAM authentication for login sessionsAlastair Tse2006-10-191-5/+8
| | | | | | [XENAPI] Fix case difference in API for Host.* functions Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Make vm-destroy consistent with API naming. Moved what isAlastair Tse2006-10-131-25/+22
| | | | | | known as xm destroy to vm-shutdown --force. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Fix bugs in vbd_create logic when handling VDIsAlastair Tse2006-10-131-9/+63
| | | | | | | | | | Attempt to handle 'tap' devices as 'vbd' devices even though the internal configuration has no idea that 'tap' is a subclass of 'vbd'. Add option parsing to vbd-create and vdi-create so you can override the configuration file options. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] XendVDI saves configuration on change.Alastair Tse2006-10-131-0/+12
| | | | | | | | Added a base class called AutoSaveObject that will attempt to call save_config() if any attribute in the object changes. It isn't particularly efficient, but we do not expect VDI to change much. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Updates to SR and VDI implementationsAlastair Tse2006-10-132-4/+66
| | | | | | | | | | | * Moved xenapi transport util method, stringify to xen.util.xmlrpclib2 * XenVDI now preserves configuration to an XML-ish file * Update Xen API's class names to be all lowercase * Update get_by_label to get_by_name_label and return sets as the API expects. * Add support for VBD creation with a VDI reference. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Adding API stub generation to XendAPI + SR implementation forAlastair Tse2006-10-121-6/+13
| | | | | | | | | Xen API. Fixed *get_by_label functions to return a Set rather than only one result. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XEND] Conform to Xen API XMLRPC Wire Protocol CustomisationAlastair Tse2006-10-061-2/+2
| | | | | | | 1. Int(s) all have to be String(s). 2. Enums are not transmitted as Ints, but as Descriptive Strings. Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Adding some rudimentary documentation about what has changed.Alastair Tse2006-10-061-0/+136
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Support for VBD/VIF info listing in vm-list --longAlastair Tse2006-10-062-15/+81
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Add missing function names. Proper sub command help messages.Alastair Tse2006-10-061-9/+33
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Pretty print error messages, insert simple argument parsingAlastair Tse2006-10-061-15/+49
| | | | | | framework Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Fix wrong vars being extracted from reading python cfgAlastair Tse2006-10-061-3/+3
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Added hard shutdown (aka. vm-destroy)Alastair Tse2006-10-061-0/+11
| | | | Signed-off-by: Alastair Tse <atse@xensource.com>
* [XENAPI] Example tools to create/destroy/shutdown VMsAlastair Tse2006-10-064-0/+268
Example Session: xapi.py vm-list xapi.py host-info xapi.py vm-create xapi.domcfg.py xapi.py vbd-create GentooAPI xapi.vbdcfg.py xapi.py vif-create GentooAPI xapi.vifcfg.py xapi.py vm-start GentooAPI xapi.py vm-shutdown GentooAPI xapi.py vm-delete xapi.py signed-off-by: Alastair Tse <atse@xensource.com>