History | View | Annotate | Download (72.1 kB)
Merge branch 'stable-2.9' into stable-2.10
Signed-off-by: Thomas Thrainer <thomasth@google.com>Reviewed-by: Helga Velroyen <helgav@google.com>
Add LC_ALL=en_US.UTF-8 before running check-man-warnings
It will be fail if LC_ALL was set to non-utf8 locale(e.g, 'C') byfollowing error.
col: Invalid or incomplete multibyte or wide character man: command exited with status 1: col -b -p -x
Signed-off-by: Yuto KAWAMURA <kawamuray.dadada@gmail.com>...
Conflicts: configure.ac # Taken both contributions
Signed-off-by: Hrvoje Ribicic <riba@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Add an example for node evacuation
The configuration shows an unbalanced cluster witha node being drained. The natural evacuation strategyincludes frf-moves.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Hrvoje Ribicic <riba@google.com>
Add configure option to pass GHC flags
Adding the HEXTRA option to make might not be practical for a changethat should be always applied, e.g., hiding a certain package. Thispatch allows the flags to be specified at the configure level.
Signed-off-by: Hrvoje Ribicic <riba@google.com>...
Add design doc for performance tests
This design doc describes which tests are added in order to test theperformance of Ganeti, specifically when handling multiple jobs inparallel.
Note that this design doc is submitted to stable-2.10 so performancechanges over different Ganeti versions can be captured....
Add a RunWithLocks QA utility function
This patch adds a QA utility function that acquires a set of locks, andattempts to run a given function with the locks in place. Should thegiven function block, this function does not detect this - laterpatches will address the issue....
Merge branch 'stable-2.8' into stable-2.9
Include qa/patch in Makefile
Fix the build by including the qa/patch directory in Makefile.am.
Move message formatting functions to separate file
The formatting functions in qa_utils.py cannot be used by modulesimported there, such as qa_config. This patch factors the functioncalls into a separate file. Also reorders imports in touched files.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Jose A. Lopes <jabolopes@google.com>
Fix execution group of NodeD
The Node deamon was executed with the wrong gid (gnt-daemons) instead of the oneassigned to it by configure.ac.
Fixes Issue 707.
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Add code style document to documentation
The Ganeti code style has been stored on the project wiki at:
https://code.google.com/p/ganeti/wiki/StyleGuide https://code.google.com/p/ganeti/wiki/HaskellStyleGuide
This commit combines the two pages into an .rst file with minimal...
Export docs from wiki to repo
Export documents about 'cluster keys replacement' and 'design filebased storage' from the wiki to the repository.
Signed-off-by: Jose A. Lopes <jabolopes@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Fix configure dirs
Fix overridable configure directories, namely, --bindir, --sbindir,and --mandir.
Variables 'bindir', 'sbindir', and 'mandir' are exported from'configure.ac' to 'Makefile.am'. At first, it would seem to bepossible to do the following:...
Add an empty post-upgrade hook
As 2.10 is the first version from which you can do automatic upgrades,there is nothing to do when going to any other version in the 2.10branch.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Petr Pudlak <pudlak@google.com>
Merge 'hs2py-constants' into 'hs2py'
Merge code of 'hs2py-constants' into 'hs2py', which requires addingflag '--constants', and merge target 'src/hs2py-constants' into'src/hs2py' in 'Makefile.am', also updating dependencies andvariables.
Signed-off-by: Jose A. Lopes <jabolopes@google.com>...
Add flag '--opcodes' to 'hs2py'
This is a transitional step before merging 'hs2py-constants' and'hs2py'.
Signed-off-by: Jose A. Lopes <jabolopes@google.com>Reviewed-by: Michele Tartara <mtartara@google.com>
Sort design docs alphabetically
Sort design docs alphabetically in Makefile.am and fix whitespace.
Signed-off-by: Jose A. Lopes <jabolopes@google.com>Reviewed-by: Hrvoje Ribicic <riba@google.com>
Missing design docs from distribution
Fixes issue 609.
Move Haskell constants to proper module
Move Haskell constants from module 'Ganeti.HsConstants', which was atransitional module part of the Haskell to Python constant generationinfrastructure, to module 'Ganeti.Constants'.
Tear down Py2Hs constant infrastructure
Tear down Python to Haskell constant conversion infrastructure, whichincludes eliminating the autotool 'convert-constants' and the Haskellmodule, namely 'Ganeti.PyConstants', which held the convertedcontants.
Add 'AF_INET*' constants to Haskell's 'AutoConf'
Add 'AF_INET*' constants to the Haskell 'AutoConf' module, whichrequires extending the 'm4' invocation with additional substitutions,in the 'Makefile' target for 'src/AutoConf.hs'.
Python autotool to print socket constants
Add Python script to autotools which prints socket related constants.These constants are a transitional solution for eliminating the Pythonto Haskell constant generation given that the final solution willrequire a change in the configuration and, therefore, postponed to...
Add unittests for Hotplug support
Try base InstanceSetParams tests that modify instance'sdevices with hotplug=True.
Add some unittests for kvm hypervisor regarding runtime filemanipulation. Based on a sample runtime file search forspecific disk and nic entries based on their UUID....
Create check-news Makefile target
Checking the correctness of the NEWS file syntax is an important part of thecheck process, but up to now it was only possible as part of a bigger set oftests. This commit creates a Makefile target to run that independently....
Prepare version numbers for 2.10 release cycle
- Bump version numbers to 2.10 in various files- Move implemented designs to design-2.10
Add unit tests for LUBackupPrepare
This patch adds unit tests for LUBackupPrepare.
Add unit tests for LUBackupQuery
This patch adds unit tests for LUBackupQuery.
Add test suite for some names in 'AutoConf'
Add test suite for some names in 'AutoConf' to test whether the valuesgenerated from 'configure' and the 'Makefile' are valid filepaths,user names, group names, among others. Fixes issue 601.
Fix several search path configure options
Fix several search path configure options to properly handleseparators.
Design document for hsqueeze
This design document describes a new htool, hsqueeze, tobe used to move the externally-mirrored instances in such away that as few nodes as possible host instances at all.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Martin Zobel-Helas <zobel@debian.org>...
Remove obsolete configure option for shared file storage
This patch removes an obsolete configure option relatedto shared file storage. It was remove a while ago, butaccidentally reintroduced through a merge.
Signed-off-by: Helga Velroyen <helgav@google.com>...
Make information about GNU ln available to programs
Propagate the information on whether we have the GNU version of lnto all programs by making it available as a constant.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Helga Velroyen <helgav@google.com>
Disregard comments in 'src/Ganeti/ListContants.hs' target
Update target 'src/Ganeti/ListContants.hs' to disregard comments in'src.Ganeti.HsContants' when extracting the names of the constantsthat need to be generated from Haskell to Python.
Add test cluster config for version 2.9
This adds a cluster config example for version 2.9 tothe test data collection. It will be used in subsequenttests.
Signed-off-by: Helga Velroyen <helgav@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Provide the DIRVERSION as a constant
Depending on configure options, the version string used in the nameof the version specific directory differs. Provide this string alsoas a constant, as it is needed for the upgrade procedure, in order tobe able to roll back....
Expose sharedir in pathutils
This path is needed to construct the link targetfor $(sysconfdir)/ganeti/share for a different version.The latter will happen in the automated upgrade procedure.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Jose Lopes <jabolopes@google.com>
Add utility function to parse version strings
The new 'gnt-cluster upgrade' command will get a Ganeti version asargument. So provide a function able to parse it.
Merge branch 'stable-2.9' into master
Add test for mond-data mock file
Test if the input file imported with the --mond-data option isparsed properly.
Signed-off-by: Spyros Trigazis <strigazi@gmail.com>Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Michele Tartara <mtartara@google.com>
Conflicts: Makefile.am NEWS configure.ac doc/design-draft.rst...
Add daemon split design doc
This describes the future planned structure of Ganeti daemons.
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Fix expansion in Makefile.am
Fix 'src/mon-collector.hs' source in dist
This patch fixes 'Makefile.am' to include the source file of'mon-collector' in the distribution tarball even if the monitoringdaemon has been disabled at configure time. Fixes issue 587.
Move 'BuildVersion' to 'lib/utils/version.py'
Functions 'BuildVersion' and 'SplitVersion' are no longer needed bythe constants and, given that they are not constants, they should bemoved elsewhere. Since they are only used by 'cfgupgrade' and tests,these functions are moved to 'lib/utils/version.py' and references to...
HUnit test for 'buildVersion'
Add 'HUnit' test for 'buildVersion'.
Signed-off-by: Jose A. Lopes <jabolopes@google.com>Reviewed-by: Thomas Thrainer <thomasth@google.com>
Remove '_autoconf'
The previous patch has made '_autoconf' obsolete. This patchcompletely removes '_autoconf' and the 'Makefile' targets for it.
Including missing RST files in packaging
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
The patch was released by the author into the public domain.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Disable parenthesis indentation check
More recent versions of pep8 check for the indentation level of closingparenthesis in a way that is incompatible with the way we use in our code. Ourstyle is still pep8 compliant, and was re-allowed in even more recent versions...
Handle $(python_scripts) and tools/burnin as python scripts
With the new private-module layout, python scripts using theganeti module must end up in $(versionedsharedir) in orderto see this private module.
Signed-off-by: Klaus Aehlig <aehlig@google.com>...
Export VERSIONEDSHAREDIR to _autoconf.py
Also install the version-dependent links forcefully
In this way, with default configuration options, runningmake install twice in a row succeeds. Fixes issue 567.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Thomas Thrainer <thomasth@google.com>
Fix 'TOOLSDIR' when passed to 'src/AutoConf.hs'
Remove trailing parenthesis in 'TOOLSDIR' 'configure' variable whenpassed to 'm4' to generate 'src/AutoConf.hs'.
Fix conflicting path values from 'configure'
Because the Hs2Py constant generation infrastructure is transitional,there are two generated 'autoconf' modules, namely, 'src/AutoConf.hs'and 'lib/_autoconf.py'. However, conflicting values were beinggenerated for Haskell and Python concerning the variables...
The $(gnt_python_sbin_SCRIPTS) are GENERATED_FILES
Before the layout change, the corresponding scripts used to bepart of PYTHON_BOOTSTRAP, hence were already considered asgenerated.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Thomas Thrainer <thomasth@google.com>...
For exported paths, use the canonical ones
Some paths set that are set at configure time are needed at runtime. These are exported by the Makefile. Change this to export the"canonical", unversioned, ones. This also has the advantage, thattools do not have to know which programs are python scripts (where,...
Adapt the version-dependent symlinks to the new design
With the latest change of our update design, there are only twosymbolic links left, that are specific to a particular version.Those are only installed, if requested.
Add the version-independent symbolic links
According to our new upgrade design, a couple of links areversion-independent, and should be installed always.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Michele Tartara <mtartara@google.com>
Make version granularity a configure option
From 2.10 onwards, all files are installed into versioneddirectories. As everything stays compatible between revisions,it is not technically necessary, to have revisions included inthe directories. Nevertheless, there are situations where this...
Adapt the base directories according to new layout
The file layout described in the upgrades design document has changed.Adapt the base directories accordingly.
Fix missing dependency on 'src/hs2py-constants'
Fix missing dependency on target 'src/hs2py-constants' in'Ganeti.ConstantUtils'.
Add unittests for OpenvSwitch in LUNodeAdd
This patch adds node_unittest.py containing the framework for unittesting LUNodeAdd.At this point, only test setup and tests for OpenvSwitch areimplemented.
Signed-off-by: Sebastian Gebhard <sege@fs.ei.tum.de>...
Add shelltest for the --ignore-dynu option of hbal
In the example, we have two nodes and 6 instances, all using externalstorage. There are four small instances on one node, and two biginstances, requiring twice the amount of resources of a small instance,...
Add unit test for LUInstanceQuery and -QueryData
This patch provides rudimentary unit test coverage for LUInstanceQueryand LUInstanceQueryData.
Signed-off-by: Thomas Thrainer <thomasth@google.com>Reviewed-by: Klaus Aehlig <aehlig@google.com>
Add unit tests for LUInstanceMigrate and -Failover
This patch adds rudimentary unit test coverage for LUInstanceMigrate andLUInstanceFailover.
Fix missing dependency in 'src/hs2py-constants'
Fix target 'src/hs2py-constants' because it must depend on'src/AutoConf.hs'. Fixes issue 573.
Make tools/users-setup explain its actions first
Before doing any changes, make tools/users-setup explain itsactions first, and ask the user for confirmation. If the firstargument is --yes-do-it, this step will be skipped.
Generate tools/users-setup from descriptions
Now that we have a machine readable description of the usersto be added to the system, use it to generate the tools/users-setupscript, so that we again have only one authoritative source ofthe user and group requirements. This also has the advantage of...
Provide ganeti user and group data in easy-to-parse form
Upon build time, also generate, in the directory doc/users, filescontaining the groups, the users with their primary group, and theadditional groupmemberships to be added. In this way, packages can use...
Add target 'AutoConf.hs'
Add Makefile target to generate 'AutoConf.hs' and add this file to'.gitignore'.
Also clean up top-level *.tix files
Add 'FrozenSet'
Add type 'FrozenSet' that wrap a Haskell 'Set', and a guardedconstructor for this type and a 'PyValue' instance.
Don't install dangling symlink for hail
hail is installed to the iallocators directory, not to the binarydirectory. Hence, if --enable-symlinks is given (the default), donot install a symbolic links there either.
Setup constant generation infrastructure
Setup a transitional Haskell to Python constant generationinfrastructure. This infrastructure is transitional and Pythonconstants will not be migrated to Haskell all at once. Instead, someconstants will be incrementally pulled from Python and moved to...
Rename 'Constants.hs' to 'PyConstants.hs'
Rename the generated 'Constants.hs' module, which contains the Haskellconstants generated from Python, to 'PyConstants.hs' in order toeliminate duplicated constants in Haskell, a problem introduced by theHaskell to Python constant generation, and to circumvent a problem...
Add Template Haskell code for constant generation
Add Template Haskell functions that generate a list in Haskellcontaining all the constants to be generated in Python. This list isan association list mapping the constant name to its Python value,which is stored as a string....
Move some 'PyValue' instances to a separate file
Move some 'PyValue' instances to a separate file so they can beavailable to other modules which need these instances but do not wantto depend on the constants module, which led to compilationconstraints....
Add design-2.9 to docinput
While design-2.9.rst was already created earlier, itwasn't registered in the Makefile. Fix this.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Provide symlinks for all myexeclib_SCRIPTS
As we also install the nodist_myexeclib_SCRIPTS, we also need toprovide symbolic links for them if symlink installation is desired.
In the manpages, use unversioned paths
Ganeti now installs all its files into a version-specific directoryand only adds symbolic links at the canonical installation places.Nevertheless, make documentation, in particular man pages, still containthe old places, i.e., the places where the symbolic links are added....
Change versiondir to adhere the changed design
Add unit test for GetLinuxNodeInfo
The function was not unit tested previously.
Signed-off-by: Michele Tartara <mtartara@google.com>Reviewed-by: Helga Velroyen <helgav@google.com>
Add configure option on whether to install symlinks
As of Ganeti 2.10, all files are installed into a single, versionspecific, directory. In this way, several Ganeti versions can beinstalled in parallel. Appropriate symbolic links in the search pathwill be added by the Ganeti upgrade procedure. For the initial...
Move installation to a single Ganeti specific directory
As first step of implementing the new upgrade procedure (see designdocument), make Ganeti install all files into a single directory,$(prefix)/opt/Ganeti-$(VERSION). Symbolic links outside to this directory...
Add unit tests for LUInstanceCreate and move tests
- Move instance related tests to instance_unittest.py- Adapt moved tests to the new test framework where appropriate- Add unit test coverage for LUInstanceCreate - Only instance creation is covered yet, no imports...
Design document for automatised upgrades
This design document describes how upgrade and downgradescan be made more automatic for future versions.
Move TestLUGroupAssignNodes to group_unittest.py
While moving the test, it is adapted to the new test framework.
Signed-off-by: Thomas Thrainer <thomasth@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Generate text report of Haskell coverage
In order to generate a coverage graph, we generate also the coveragedata as text format. This eases parsing on Buildbot.
Add unit test for LUClusterRename
Also mock the netutils and ssh module in order to test all code paths.
Signed-off-by: Thomas Thrainer <thomasth@google.com>Reviewed-by: Michele Tartara <mtartara@google.com>
Move cmdlib-related unittests to cmdlib/
ganeti.cmdlib_unittest.py andganeti.cmdlib.instance_storage_unittest.py are moved to thetest/py/cmdlib directory. Also, they are renamed to match the names inthis module.
Additionally, instance_storage_unittest.py was added to the makefile, so...
Add unit test for LUClusterActivateMasterIp
In order to properly assert the called RPC method, eq is implementedon ConfigObject as well.
Enable pylint and PEP8 for test support code
The test support code is mainly written from scratch, so in order toensure to keep the code quality high, enable pylint and PEP8 checksfor it.
Due to some specialities of the test code, a dedicate pylintrc-test file...
Initial version of cmdlib test framework
The initial version of the cmdlib test framework is able to execute LU'swith the following components mocked:
A base test class is provided which makes it easy to execute opcodes and...