diff -Nru maas-2.0.0+bzr5189/acceptance/Makefile maas-2.1.1+bzr5544/acceptance/Makefile --- maas-2.0.0+bzr5189/acceptance/Makefile 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/acceptance/Makefile 1970-01-01 00:00:00.000000000 +0000 @@ -1,152 +0,0 @@ -# -# Build and test everything in ephemeral containers: -# -# $ make -# -# Use a different packaging branch: -# -# $ make packaging=/path/to/branch -# -# Note: /path/to/branch can be anything that bzr recognises, so an lp: -# link, or bzr+ssh, and so on. -# -# Build and test with a different Ubuntu series: -# -# $ make series=randy -# - -include /etc/lsb-release - -# Default to the newer of Quantal or the local series. -series := $(lastword $(sort quantal $(DISTRIB_CODENAME))) - -# Default to the main packaging branch on Launchpad, but treat Precise -# specially. -ifeq ($(series),precise) -packaging := lp:~maas-maintainers/maas/packaging.precise -else -packaging := lp:~maas-maintainers/maas/packaging -endif - -# Assume we're testing this branch. -upstream := $(abspath ..) - -# The container on which to base ephemerals. -container := maas-$(series) - -## Convenience definitions. - -define ephexec -sudo LC_ALL=C SSH_ASKPASS=$(abspath ubuntupass) setsid \ - lxc-start-ephemeral -b $(upstream) -o $(container) -u ubuntu -- \ - env DEBIAN_FRONTEND=noninteractive SUDO_ASKPASS=$(abspath ubuntupass) -endef - -define ephexec-make -$(ephexec) $(abspath with-make) make -C $(abspath .) -endef - -define check-service -test $(2) = $(wordlist 2,2,$(shell initctl --system status $(1))) # $(1) -endef - -## Top-level targets. - -test: build | services sudo container-updated - $(ephexec-make) $@-inner - -# lxc-start-ephemeral does not return the exit code of any command it -# runs, so we delete any existing packages before building and check -# for their presence afterwards instead. -build: source source/debian | services sudo container - @$(RM) *.deb - $(ephexec-make) $@-inner - @ls -1 *.deb - @touch $@ - -container: | services sudo - test -n "$$(sudo lxc-ls -1 $(container))" || \ - sudo lxc-create -n $(container) -f /etc/lxc/default.conf \ - -t ubuntu -- --release $(series) - -container-updated: container | services sudo - $(abspath update-container) $(container) - -services: - $(call check-service,lxc,start/running) - $(call check-service,lxc-net,start/running) - -define phony-outer-targets - container - container-updated - services - test -endef - -## Targets that run within an LXC container. - -# XXX: These packages appear to be missing from the dependencies -# declared in the packaging branch. -define missing-packages - python-distribute - python-django -endef - -test-inner: upgrade-inner - sudo -AE apt-get --assume-yes install $(strip $(missing-packages)) - sudo -AE dpkg --unpack --force-depends -- *.deb - sudo -AE apt-get --fix-broken --assume-yes install - -define build-packages - debhelper - devscripts - dh-apport -endef - -build-inner: | upgrade-inner - sudo -AE apt-get --assume-yes install $(strip $(missing-packages)) - sudo -AE apt-get --assume-yes install $(strip $(build-packages)) - cd source && debuild -i -us -uc -b - -upgrade-inner: - sudo -AE apt-get --assume-yes update - sudo -AE apt-get --assume-yes upgrade - -define phony-inner-targets - build-inner - test-inner - upgrade-inner -endef - -## Dependencies. - -source: - bzr export --uncommitted $@ $(upstream) - -source/debian: | source - bzr export $@ $(packaging)/debian - -## Miscellaneous. - -sudo: - @sudo -v - -clean: - $(RM) -r source build *.build *.changes *.deb - -define phony-misc-targets - clean - sudo -endef - -## Phony. - -define phony - $(phony-inner-targets) - $(phony-misc-targets) - $(phony-outer-targets) -endef - -phony := $(sort $(strip $(phony))) - -.PHONY: $(phony) diff -Nru maas-2.0.0+bzr5189/acceptance/README maas-2.1.1+bzr5544/acceptance/README --- maas-2.0.0+bzr5189/acceptance/README 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/acceptance/README 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ -MAAS Packaging Acceptance Testing ---------------------------------- - -The `test` make target will build binary packages for the current -branch using the latest packaging branch from Launchpad, *in a clean -ephemeral container*. The `build` target will install these packages -in another clean ephemeral LXC container. - -Consider the `build-inner` and `test-inner` targets as bootstrap -points for further work. It may not be suitable for full automated -end-to-end testing of MAAS, so be clear about what you need to test -before investing work here. OTOH, it is a good place to quickly test -that the packages build, install and configure themselves as expected. diff -Nru maas-2.0.0+bzr5189/acceptance/ubuntupass maas-2.1.1+bzr5544/acceptance/ubuntupass --- maas-2.0.0+bzr5189/acceptance/ubuntupass 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/acceptance/ubuntupass 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -#!/usr/bin/env bash -echo ubuntu diff -Nru maas-2.0.0+bzr5189/acceptance/update-container maas-2.1.1+bzr5544/acceptance/update-container --- maas-2.0.0+bzr5189/acceptance/update-container 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/acceptance/update-container 1970-01-01 00:00:00.000000000 +0000 @@ -1,32 +0,0 @@ -#!/usr/bin/env bash -# Copyright 2013-2015 Canonical Ltd. This software is licensed under the -# GNU Affero General Public License version 3 (see the file LICENSE). - -# Exit immediately if a command exits with a non-zero status. -set -o errexit -# Treat unset variables as an error when substituting. -set -o nounset - -container="$1" - -start() { - echo -n Starting... - sudo lxc-start -n "${container}" --daemon - echo " done." -} - -attach() { - sudo LC_ALL=C lxc-attach -n "${container}" -- "$@" -} - -stop() { - echo -n Stopping... - sudo lxc-stop -n "${container}" - echo " done." -} - -start && trap stop EXIT && { - sleep 5 # Allow container to get going. - attach sudo -AE apt-get --assume-yes update - attach sudo -AE apt-get --assume-yes dist-upgrade -} diff -Nru maas-2.0.0+bzr5189/acceptance/with-make maas-2.1.1+bzr5544/acceptance/with-make --- maas-2.0.0+bzr5189/acceptance/with-make 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/acceptance/with-make 1970-01-01 00:00:00.000000000 +0000 @@ -1,19 +0,0 @@ -#!/usr/bin/env bash -# Copyright 2012-2015 Canonical Ltd. This software is licensed under the -# GNU Affero General Public License version 3 (see the file LICENSE). - -# Exit immediately if a command exits with a non-zero status. -set -o errexit -# Treat unset variables as an error when substituting. -set -o nounset - -# Ensure that GNU make is installed. -if ! sudo -AE apt-get install --assume-yes make -then - # The installation of `make` may have failed because the package - # lists are out of date, so update them and try again. - sudo -AE apt-get update - sudo -AE apt-get install --assume-yes make -fi - -exec "$@" diff -Nru maas-2.0.0+bzr5189/buildout.cfg maas-2.1.1+bzr5544/buildout.cfg --- maas-2.0.0+bzr5189/buildout.cfg 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/buildout.cfg 2016-11-08 19:56:20.000000000 +0000 @@ -124,6 +124,10 @@ "test", "--noinput", "--with-crochet", + # Disable resources in the region for now because of suspected bad + # interactions with django_nose. + # "--with-resources", + "--with-scenarios", "--with-select", "--select-dir=src/maas", "--select-dir=src/maasserver", @@ -166,6 +170,8 @@ ${common:path-munge} ${common:warnings} options = [ + "--with-resources", + "--with-scenarios", "--with-select", "--select-dir=src/apiclient", "--select-dir=src/maascli", @@ -200,6 +206,8 @@ ${common:path-munge} ${common:warnings} options = [ + "--with-resources", + "--with-scenarios", "--with-select", "--select-dir=src/maastesting", "--cover-package=maastesting", @@ -238,6 +246,8 @@ options = [ "--with-crochet", "--crochet-no-setup", + "--with-resources", + "--with-scenarios", "--with-select", "--select-dir=src/provisioningserver", "--cover-package=provisioningserver", @@ -257,6 +267,8 @@ initialization = ${common:initialization} options = [ + "--with-resources", + "--with-scenarios", "--with-select", "--select-dir=etc/maas/templates/commissioning-user-data", "--cover-package=snippets", @@ -291,7 +303,7 @@ eggs = flake8 entry-points = - flake8=flake8.run:main + flake8=flake8.main.cli:main initialization = ${common:path-munge} ${common:warnings} diff -Nru maas-2.0.0+bzr5189/CHANGELOG maas-2.1.1+bzr5544/CHANGELOG --- maas-2.0.0+bzr5189/CHANGELOG 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/CHANGELOG 2016-11-08 19:56:20.000000000 +0000 @@ -2,1456 +2,954 @@ Changelog ========= -2.0.0 +2.1.1 ===== -Important announcements ----------------------- +Bugs fixed in this release +-------------------------- -**MAAS 2.0 supported on Ubuntu 16.04 LTS (Xenial)** - MAAS version 2.0 is supported on Ubuntu 16.04 LTS. MAAS 2.0 and greater - will NOT be supported on Ubuntu 14.04 LTS. The latest MAAS 1.9 point release - will continue to be supported on Ubuntu 14.04 LTS (Trusty) until it reaches - end-of-life. - - Upgrades are supported for users running Ubuntu 14.04 systems running - MAAS 1.9 or earlier. Upon upgrading to Ubuntu 16.04, the MAAS - database and configuration will be seamlessly migrated to the supported - MAAS version. - - Please see the “Other Notable Changes” section below for more details - regarding the reasons for this change. - -**Terminology Changes** - Cluster controllers have been renamed to rack controllers. - - Starting from MAAS 2.0, MAAS cluster controllers have been deprecated, - along with the legacy ``nodegroups`` API. The new API endpoint is - ``rackcontrollers``, which provides feature parity with earlier versions - of MAAS. - - For more information on rack controllers, refer to the `Major new Features` - section bellow or refer to :ref:`rack-configuration`. - -**API 1.0 has been deprecated, introducing API 2.0** - Starting from MAAS 2.0, the MAAS REST API version 1.0 has been deprecated. - MAAS 2.0 drops support for the legacy 1.0 API, in favor of API version 2.0. - With the introduction of the new API version, various endpoints have now - been deprecated, and new end-points have been introduced. API users will - need to update their client tools to reflect the changes. - - For more information on API 2.0, refer to :ref:`API documentation `. - -**Static IP ranges have been deprecated** - Starting from MAAS 2.0, static IP ranges (previously found on the cluster - interface page) have been deprecated. MAAS now assumes total control of a - subnet. MAAS will automatically assign IP addresses to deployed machines, - as long as those IP addresses are not within a dynamic or a reserved - IP range. Users are now only required to specify one or more dynamic ranges - per subnet. Dynamic ranges are used for auto-enlistment, commissioning, and - any other systems configured for DHCP. IP addresses in-use for purposes such - as devices, default gateways, DNS servers, rack and region controllers, and - BMCs are automatically avoided when assigning IP addresses. Reserved IP - ranges may be added if MAAS should avoid certain ranges of IP addresses in - the subnet. - -**maas-region-controller-min has been renamed to maas-region-api** - The ``maas-region-controller-min`` package has been renamed to - ``maas-region-api``. This package provides API services for MAAS - (``maas-regiond``) and can be used to scale out the API front-end of - a MAAS region. - -**MAAS user creation been moved to 'maas' command** - Starting from MAAS 2.0, the ``maas`` command now provides the ability to - create admin users. The ``maas-region createadmin`` command has been - deprecated. New administrators should now be created with - ``maas createadmin``. - -**maas-provision command has been replaced** - The MAAS rack controller command-line interface (``maas-provision``) has - been replaced by the ``maas-rack`` command. - -**maas-region-admin command has been replaced with maas-region** - The MAAS region controller command-line interface (``maas-region-admin``) - has been replaced by the ``maas-region`` command. Note that this command - provides an interface to interact directly with Django, which should only be - used for debugging purposes. - -**Debian Installer is no longer installed or supported** - Because support for the Debian Installer (DI) has been dropped (as - of MAAS 1.9), MAAS no longer downloads DI-related files from simplestreams. - Upon upgrading to MAAS 2.0, DI-related files will be removed from the MAAS - region (and all rack controllers). +LP: #1554636 maas serving old image to nodes +LP: #1593991 [2.0b7, API/CLI] allows you to add machines with power_type and no power_parameters -Major new features ------------------- +LP: #1602482 [2.0rc2] Incorrect DNS records -**MAAS Rack Controllers and High Availability** - Starting from MAAS 2.0, MAAS **cluster controllers** have been renamed to - **rack controllers**. - - * The ``nodegroups`` and ``nodegroups/(group)/interfaces`` API endpoints - have been deprecated. In MAAS 2.0, the ``rackcontrollers`` interface - partially replaces this functionality. For defining dynamic and reserved - ranges, or specifying default gateways, use the ``subnets`` endpoint. For - enabling or disabling DHCP, use the ``fabrics/(fabric)/vlans`` endpoint. - - * The **Clusters** tab is no longer available in the Web UI. - Controllers are now found under the **Nodes** tab, where each region - and/or rack controller can be found. Other cluster interface properties - have been moved to the Subnet and VLAN details pages under the **Networks** - tab. - - * Machines no longer belong to a specific controller. - In earlier versions of MAAS, machines would directly assigned to a cluster - controller. The cluster controller that the machine belonged to would not - only perform DHCP for that machine, but also all the PXE booting and power - management. - - In order to support high availability for rack controllers, (starting from - MAAS 2.0) machines no longer belong to a specific rack controller. The best - controller to manage a machine is now determined at runtime. - - * DHCP is now configured per-VLAN. - In earlier versions of MAAS, DHCP was directly linked and configured - per cluster interface. As of MAAS 2.0, DHCP is now configured and managed - per-VLAN, which allows any rack controller to potentially provide DHCP in - a high-availability environment. - - * Rack controllers have been enabled for high availability. - Starting from MAAS 2.0, rack controllers in the same VLAN become - candidates to manage DHCP, PXE/TFTP, and power control for machines on - the VLAN. MAAS now supports the concept of a **primary** and a - **secondary** rack controller. If a secondary controller determines that - the primary controller is unavailable, it will assume control of those - services. - - * Added ``maas-rack support-dump`` command. - For increased support observability, users can now dump the contents of - several internal MAAS data structures by executing ``sudo maas-rack - support-dump``. This command will dump networking diagnostics, rack - configuration, and image information. Information can be restricted to a - particular category by using the ``--networking``, ``--config``, or - ``--images`` options. - - * Rack controllers can now be found under the **Nodes** tab in the Web UI. - MAAS 2.0 Adds a new **Controllers** section under thee **Nodes** tab. This - section will now list all rack and region controllers. Under a rack - controller, the user will be able to see service tracking, connected VLANs, - rack interfaces and other relevant information. - -**Region Controller Redundancy (High Availability)** - Starting from MAAS 2.0, MAAS provides the ability to scale out (provide - redundancy for) the MAAS region controller API, HTTP server, and DNS. This - will allow administrators to set up multiple MAAS region controllers - (``maas-region-api``) against a common database, providing redundancy of - services. With further manual configuration, users will be able to setup - the MAAS region controller in high availability mode. - -**New Networks Web UI** - MAAS 2.0 introduces a few new Web UI features that were not available in - previous versions of MAAS. - - * Added fabric and space details pages. - - * Added the ability to add and remove fabrics, spaces, subnets and VLANs. - This can be done using the actions menu on the **Networks** tab. - - The ability to delete fabrics, spaces, subnets and VLANs is also available - from the details page for each respective object. - -**DNS Management** - MAAS 2.0 extends DNS management by adding the following features: - - * Ability to create multiple DNS domains. - * Ability to add multiple records (``CNAME``, ``TXT``, ``MX``, ``SRV``) per - domain. (API only) - * Ability to select the domain for machines and devices. - * Ability to assign (additional) names to IP addresses. (API only) - * For deployed machines, ``A`` records continue to be created for - the IP of the PXE interface. - * Additional PTR records are now created for all non-PXE interfaces in - the form: ``.`` - * Reverse DNS is now generated for only the subnet specified, rather - than the parent /24 or /16. By default, `RFC2137`_ glue is provided - for networks smaller than /24. This can be disabled or changed - on a per-subnet basis via the API. - -.. _RFC2137: - https://tools.ietf.org/html/rfc2137 - -**IP Ranges** - Previous versions of MAAS used the concepts of a **dynamic range** and - **static range**, which were properties of each cluster interface. This - has been redesigned for MAAS 2.0 as follows: - - * Dynamic ranges have been migrated from earlier MAAS releases as-is. - - * Because static ranges have been removed from MAAS, each static - range has been migrated to one or more reserved ranges, which - represent the opposite of the previous static range. (MAAS now - assumes it has full control of each managed subnet, and is free - to assign IP addresses as it sees fit, unless told otherwise.) - - For example, if in an earlier MAAS release a cluster interface was - configured on 192.168.0.1/24, with a dynamic range of 192.168.0.2 - through 192.168.0.99, and a static range of 192.168.0.100 through - 192.168.0.199, this will be migrated to:: - - IP range #1 (dynamic): 192.168.0.2 - 192.168.0.99 - IP range #2 (reserved): 192.168.0.200 - 192.168.0.254 - - Since 192.168.0.100 - 192.168.0.199 (the previous static range) - is not accounted for, MAAS assumes it is free to allocate static - IP addresses from that range. - - * Scalability is now possible by means of adding a second dynamic - IP range to a VLAN. (To deal with IP address exhaustion, MAAS - supports multiple dynamic ranges on one or more subnets within - a DHCP-enabled VLAN.) - - * Reserved ranges can now be allocated to a particular MAAS user. - - * A comment field has been added, so that users can indicate why - a particular range of IP addresses is reserved. - - * IP ranges can be configured in the Web UI via the Subnet - details page, or using the ``subnets`` REST API endpoint. - -**API 2.0 and MAAS CLI Updates** - Version 1.0 of the MAAS REST API has been removed and replaced with the 2.0 - version of the REST API. As such, new endpoints and commands have been - introduced: - - * RackControllers - This endpoint/command has the following operations - in addition to the base operations provided by nodes: - - * ``import-boot-images`` - Import the boot images on all rack - controllers - * ``describe-power-types`` - Query all of the rack controllers for - power information - - * RackController - This endpoint/command has the following operations - in addition to the base operations provided by nodes - - * ``import-boot-images`` - Import boot images on the given rack - controller - * ``refresh`` - refresh the hardware information for the given rack - controller - - * Machines - This endpoint/command replaces many of the operations - previously found in the nodes endpoint/command. The machines - endpoint/command has the following operations in addition to the - base operations provided by nodes. - - * ``power-parameters`` - Retrieve power parameters for multiple - machines - * ``list-allocated`` - Fetch machines that were allocated to the - user/oauth token. - * ``allocate`` - Allocate an available machine for deployment. - * ``accept`` - Accept declared machine into MAAS. - * ``accept-all`` - Accept all declared machines into MAAS. - * ``create`` - Create a new machine. - * ``add-chassis`` - Add special hardware types. - * ``release`` - Release multiple machines. - - * Machine - This endpoint/command replaces many of the operations - previously found in the node endpoint/command. The machine - endpoint/command has the following operations in addition to the - base operations provided by node. - - * ``power-parameters`` - Obtain power parameters for the given machine. - * ``deploy`` - Deploy an operating system to a given machine. - * ``abort`` - Abort the machines current operation. - * ``get-curtin-config`` - Return the rendered curtin configuration for - the machine. - * ``power-off`` - Power off the given machine. - * ``set-storage-layout`` - Change the storage layout of the given - machine. - * ``power-on`` - Turn on the given machine. - * ``release`` - Release a given machine. - * ``clear-default-gateways`` - Clear any set default gateways on the - machine. - * ``update`` - Change machine configuration. - * ``query-power-state`` - Query the power state of a machine. - * ``commission`` - Begin commissioning process for a machine - - Other endpoints/commands have changed: - - * All list commands/operations have been converted to read - * All new and add commands/operations have been converted to create - * Nodes - The nodes endpoint/command is now a base endpoint/command - for all other node types(devices, machines, and rack-controllers). - As such most operations have been moved to the machines - endpoint/command.The following operations remain as they can be - used on all node types. - - * ``is-registered`` - Returns whether or not the given MAC address is - registered with this MAAS. - * ``set-zone`` - Assign multiple nodes to a physical zone at once. - * ``read`` - List nodes visible to the user, optionally filtered by - criteria. - - * Node - The node endpoint/command is now a base endpoint/command for - all other node types(devices, machines, and rack-controllers). As - such most operations have been moved to the machine endpoint/command. - The following operations remain as they can be used on all node types. - - * ``read`` - Read information about a specific node - * ``details`` - Obtain various system details. - * ``delete`` - Delete a specific node. - - * With the migration of nodes to machines the following items previously - outputted with the list command have been changed or removed from the - machines read command: - - * ``status - Will now show all status types - * ``substatus``, ``substatus_action``, ``substatus_message``, - ``substatus_name`` - Replaced by ``status``, ``status_action``, - ``status_message``, ``status_name``. - * ``boot_type - Removed, MAAS 2.0 only supports fastpath. - * ``pxe_mac`` - Replaced by ``boot_interface``. - * ``hostname`` - Now only displays the hostname (without the domain) of - the machine. ``fqdn`` and ``domain`` attributes can now be used instead. - - * And other endpoints/commands have been deprecated: - - * NodeGroups - Replacement operations are found in the - RackControllers, Machines, and BootResources endpoints/commands. - * NodeGroupInterfaces - replacement operations are found in the - RackController, IPRanges, Subnets, and VLANS endpoints/commands. - -**Extended Storage Support** - MAAS 2.0 Storage Model has been extended to support: - - * XFS as a filesystem. - * Mount options. - * Swap partitions. (MAAS 1.9 only supported the creation of a swap - file in the filesystem.) - * ``tmps``/``ramfs`` support. - - All of these options are currently available over the CLI. - -**DHCP Snippets** - MAAS 2.0 introduces the ability to define DHCP snippets. This - feature allows administrators to manage DHCP directly from MAAS, removing - the need to manually modify template files. The following types of DHCP - snippets can be defined: - - * **Host snippets** - used for configuration for a particular node in MAAS. - * **Subnet snippets** - used for configuration for a specific subnet in MAAS. - * **Global snippets** - used for configuration that will affect DHCP (isc-dhcp) - as a whole. +LP: #1620478 [2.1, UI] Broken validation on VLAN MTU - For more information, see :ref:`DHCP Snippets `. +LP: #1630636 [2.1 ipv6] YAML error when maas_url has an IPv6 IP -Minor new features ------------------- +LP: #1630679 [2.1b1] Can't use custom image repository -**MAAS proxy is now managed** - Starting from MAAS 2.0, MAAS now manages the configuration for - ``maas-proxy``. This allows MAAS to lock down the proxy so that it only - allows traffic from networks MAAS knows about. For more information, see - :ref:`MAAS Proxy `. - -**rsyslog during enlistment and commissioning** - MAAS 2.0 now enables ``rsyslog`` for the enlistment and commissioning - environment (when using Xenial as the commissioning image). This allows users - to see ``cloud-init``'s syslog information in ``/var/log/maas/rsyslog/``. - -**Ability to change a machine’s domain name from the UI** - MAAS 2.0 introduces the ability to change a machine’s DNS domain - via the Web UI. It was previously supported on the API only. - -**Networks listing page** - In the **Networks** tab, a new networks overview has been introduced, which - provides a high-level view of the MAAS networking mode. The network model - can be grouped by either fabrics or spaces. - -**Service Tracking** - MAAS now tracks the status of the services required for its operation, such - as ``bind``, ``maas-dhcpd``, ``maas-dhcpd6``, ``tgt``, and ``maas-proxy``. +LP: #1633717 [2.1] DHCP probe needs to be smarter about interface selection to avoid log spam +LP: #1636858 [2.1.1, trunk, bzr5510] Can't enlist machines -Other notable changes ---------------------- +LP: #1636861 [2.1.1, trunk, bzr5510] UI error when adding a chassis -**MAAS 2.0 requires Python 3.5** - Starting with MAAS 2.0, MAAS has now been ported to Python 3.5 (the default - version of Python in Ubuntu 16.04 "Xenial"). - -**MAAS 2.0 now fully supports native Django 1.8 migration system** - MAAS is now based on Django 1.8. Django 1.8 has dropped support for the - South migration system in favor of the native Django migration - system, which breaks backwards compatibility with previous versions of - Django. - - MAAS continues to support a full upgrade path. MAAS versions 1.5, 1.7, 1.8, - and 1.9 have been tested and confirmed to upgrade seamlessly to MAAS 2.0. - -**Instant DHCP lease notifications** - MAAS no longer scans the leases file every 5 minutes. ``isc-dhcp-server`` - now directly notifies MAAS if a lease is committed, released, or expires. - -**Host entries in DHCP** - Host entries are now rendered in the DHCP configuration instead - of placed in the leases file. This removes any state that previously - existed in the DHCP lease database on the cluster controller. - - Starting with MAAS 2.0, if the dhcpd.leases file is lost (such as during a - failure scenario in a high availability environment), MAAS will be able to - reconstruct it. - -**Power control is no longer specific to a rack controller** - MAAS selects one of the available rack controllers to power control - or query a BMC. The same rack controller that powers the BMC does - not need to be the rack controller that the machine PXE boots from. +LP: #1636992 [2.1] Deleting all boot sources and creating a new boot source, does not update the cache +LP: #1598175 [2.0] If the machine is deployed, I cannot update NIC's nor storage -2.0.0 (rc4) -=========== +LP: #1603563 [2.0 RC2] Multiple failures to release nodes -Issues fixed in this release ----------------------------- - -LP: #1592666 Mirror URL contains double slash (/) after hostname, impacting proxy cachaility. - -LP: #1604461 [2.0rc2] Static IP address are allowed to be created in a dynamic range. - -LP: #1610397 When juju adds containers to MAAS, ensure they inherit the parent machine domain name, if none is passed by Juju. +LP: #1606508 [2.1] Failover peers must be IPv4 for use with ISC dhcpd -LP: #1611342 UI error while generating a MAAS key (token). +LP: #1632853 [2.1] Observed neighbours should be avoided when assigning IP addresses -LP: #1610414 apiclient.maas_client.MAASClient.post() always sets an op in the query string +LP: #1633401 [2.1] In device discovery in Settings, remove the header of the first dropdown field (Host discovery and network observation) +LP: #1633452 [2.1] In settings, rename the option Disabled (suppress active scanning) in the Active discovery interval field to Never (disabled). -2.0.0 (rc3) -=========== - -Issues fixed in this release ----------------------------- +LP: #1633462 [2.1] In settings in the device discovery section reduce the text of the explanation of the fields. -LP: #1557434 For the MAAS CLI, mimic the error behaviour provided by argparse 1.1 on PyPI when insufficient arguments are given. - -LP: #1594991 MAAS displays every power query on the summarized view of node event log. - -LP: #1603147 Commissioning dropdown is grey and checkmarks are missing. - -LP: #1576116 [2.0rc1] MAAS does not respect default subnet's DNS server when choosing default DNS - -LP: #1600720 [2.0rc1] MAAS doesn't honor DNS settings for a subnet for DHCP - -LP: #1598028 [2.0] Loading latest machine events can make web browser unresponsive - -LP: #1604128 [2.0rc2] Unable to add a public SSH Key due to lp1604147 - -LP: #1604169 [2.0] maas login yields "ImportError: No module named 'maasserver'" - -LP: #1604962 Fixes to correctly log cloud-init/curtin FAIL events in the node event log. - -LP: #1604987 Fixes to correctly log "mark_failed" events. - -LP: #1602721 [2.0rc2] Can't get node-results via cli/api - -LP: #1604465 [2.0] RackController.get_image_sync_status causes huge load on regiond process - -LP: #1598149 [2.0rc2] MAAS is not automatically monitoring timeouts for commissioning. - -LP: #1605252 [2.0] Error messaging about monitor expiry has been dropped - - -2.0.0 (rc2) -=========== - -Issues fixed in this release ----------------------------- - -LP: #1582070 Pick up wrong grub.cfg if another filesystem exists - -LP: #1599223 [2.0] confusing reverse DNS lookups because MAAS creates multiple PTR records - -LP: #1600259 [2.0] reverse DNS sometimes assigns FQDN where it should assign IFACE.FQDN - -LP: #1599997 [2.0rc1] after upgrade from 2.0b3, Error on request (13) subnet.list: 'NoneType' object is not iterable - -LP: #1598461 [2.0rc1] Image import dates are inconsistent - -LP: #1598937 [2.0rc1] Following fresh install maas command fails - PermissionError: [Errno 13] Permission denied: '/home/ubuntu/.maascli.db' - -LP: #1597787 [1.9.3,2.0] cannot create more than 4 partitions when disk is configured with mbr - -LP: #1600267 [1.9,2.0,UX] Can't add aliases when parent interface is set to 'DCHP' - -LP: #1600198 [1.9,2.0,UX] Creating a Bcache disk is not prevented when is not created in partition - - -2.0.0 (rc1) -=========== - -Issues fixed in this release ----------------------------- - -LP: #1576357 Determine a method for how to reconnect a deleted rack controller - -LP: #1592246 [2.0b7, regression] maas-rack register makes up a new hostname - -LP: #1595753 [beta8] HMC power driver regression -- Not able to connect via SSH. - -LP: #1592885 [2.0b7] Date and time format should be consistent accross logs - -LP: #1597324 [2.0b8] Unable to set default gateway interface - -LP: #1515188 [1.9] VMware power management fails when VMs are organized in nested subfolders - -LP: #1596046 [2.0] maas 2.0 pxeboot fails on PowerNV - -LP: #1600267 [1.9,2.0,UX] Can't add aliases when parent interface is set to 'DCHP' - -LP: #1598937 [2.0 rc1] Following fresh install maas command fails - PermissionError: [Errno 13] Permission denied: '/home/ubuntu/.maascli.db' - -2.0.0 (beta8) -============= - -Issues fixed in this release ----------------------------- +LP: #1633822 [2.1] Device discovery ignores reverse DNS -LP: #1590081 Allow ed25519 and ecdsa ssh keys +LP: #1636250 [2.1] machines allocate API returns a random machine if incorrect - parameters are used -LP: #1462078 [2.0b2, UI] Can't add a device and it does not show why +LP: #1636873 [2.1.0] Creating a bond doesn't work and no feedback is provided if fabric in interfaces is 'disconnected' -LP: #1573626 [2.0b3] Interfaces on region controllers are not discovered +LP: #1636874 [2.1, Yakkety] Plus '+' button is not visible when you hover over an interface in machine details -LP: #1562107 [2.0b4, UI] No feedback when failing to assign static IP address on the Node Details Page +LP: #1637009 [2.0,2.1] Node acquisition constraints API documentation needs to be updated to match reality -LP: #1583670 [2.0b5] No way to read settings, like proxy, for non-admin users +LP: #1637182 Help and documentation 'list of unicodes' inconsistent -LP: #1585016 [2.0b5] Commissing with LVM breaks deployments +LP: #1637192 [2.0,2.1] Allocate using subnets or not_subnets with space fails -LP: #1581729 [2.0b5] dns templates still in /etc/maas/templates +LP: #1637246 MaaS should use configured names for VLAN interfaces -LP: #1588907 [2.0b6] django.db.utils.IntegrityError: insert or update on table "piston3_consumer" violates foreign key constraint LP: "piston3_consumer_user_id_4ac0863fa7e05162_fk_auth_user_id +LP: #1638284 [2.1.1pre] Debug logging shown by default in regiond.conf -LP: #1581130 [2.0b6] Image status stays out-of-sync after adding custom image +LP: #1638288 [2.1.1 pre] A lot of repeated logging -LP: #1590144 [2.0b6] core count not updated during commissioning if MAAS previously stored a higher core count +LP: #1638589 [2.1] commissioning doesn't find the second address family on the boot interface -LP: #1592282 [2.0b7] Adding rack controller instructions could be in the GUI +LP: #1600328 [2.0rc1, API/CLI] When adding a new machine and no rack controller can connect to the BMC, no error message is displayed. -LP: #1592132 [2.0b7] Enlisting output returns objects +LP: #1633378 [Device Discovery] Rename the section Header in the Settings page -LP: #1592137 [2.0b7, UI] Can't sort IP addresses under a subnet details page +LP: #1633600 [2.1.1] Docs do not mention the need to mirror bootloaders -LP: #1593789 [2.0b7] Nodes API doesn't show regions +LP: #1636251 resolv.conf search path doesn't match the domain for the host -2.0.0 (beta7) -============= - -Issues fixed in this release ----------------------------- - -LP: #1587896 get_interfaces_definition is not thread-safe - -LP: #1590946 Auto detection of running virtual environment during commissioning almost always fails - -LP: #1591093 [2.0,1.9] 3rd party HP drivers (archive hostname renamed) - deployment fails - -LP: #1590021 [2.0] Cannot create an IP reservation with a hostname - -LP: #1591346 [2.0] maas createadmin fails - -LP: #1577953 [2.0b4] Rack Controller fail to update commissioning info? - -LP: #1579215 [2.0b4] Can attempt to commission enlisted nodes without chosen power type - -LP: #1581219 [2.0b4 UI] MAAS WebUI doesn't quickly refresh when deleting machines - -LP: #1581723 [2.0b5] request to http://192.168.10.27:5240/MAAS/metadata/status/43he8/latest failed - -LP: #1587896 [2.0b5] p.refresh.get_swap_size misconverting units - -LP: #1590499 [2.9b6] Can edit fabric and subnet on deployed node - -LP: #1591395 [2.0b6] some arm64 systems need ipmi_ssif module in addition to ipmi_si - -LP: #1589587 [2.0b6] Attempting to delete a VLAN that cannot be deleted, shows traceback in regiond.log - -LP: #1591958 [2.0b6] Commisioning fails on machines without HW virtualization - -LP: #1590991 [2.0b6] Cannot allocate a node based on its system_id - -LP: #1589562 [2.0b6, UI] When I delete a fabric, it takes me back to the Node listing page - -LP: #1589596 [2.0b6, UI] When I delete a space, it takes me back to the Node listing page - -LP: #1588298 [2.0b5, UI] No form validation when adding a subnet, space, fabric or vlan - -LP: #1589606 [2.0b6, UI] Message "No IP ranges have been reserved for this subnet." doesn't go away after adding IP Range - -LP: #1589583 [2.0b6, UI] Can't add a VLAN over the WebUI - -LP: #1589560 [2.6b6, UI] Adding a fabric with an optional name ends up with a new fabric with automatically assigned name - -LP: #1589595 [2.6b6, UI] Adding a space with an optional name ends up with a new space with automatically assigned name - - -2.0.0 (beta6) -============= - -Issues fixed in this release ----------------------------- - -LP: #1572646 Spurious failures in test_regionservice - -LP: #1582836 use http for stream mirror, not https - -LP: #1583715 MAAS version API call should not require authentication - -LP: #1572740 Detect and identify NIC SR-IOV capability - -LP: #1584211 [1.9,2.0]Commissioning fails when BIOS reports floppy drive, but there is none installed - -LP: #1584850 [1.9,2.0] DNS record created against IPv6 address when it is not on the PXE interface - -LP: #1586555 [2.0] MaaS 2.0 BMC information not removed when nodes are removed - -LP: #1508741 [2.0] IPMI driver does not handle timeouts correctly - -LP: #1585759 [2.0] Display RAM amount to the first decimal place in the UI - -LP: #1585760 [2.0] Expose the refresh rack controller action over the UI - -LP: #1585768 [2.0] Rename maas-nodegrou-worker to MAAS - -LP: #1553841 [2.0a1] MAAS should ensure that BMC password is correct before saving - -LP: #1571645 [2.0b2] DNS zone serials are not stable - -LP: #1570985 [2.0b2] If you deploy a machine in MAAS, and manually install a rack controller in it, it disappears from the machine list" - -LP: #1576417 [2.0b3] rack / region controllers are visible to non-admins - -LP: #1577972 [2.0b4] external maas-rack-controller logs to syslog instead of maas.log - -LP: #1580817 [2.0b4] twisted.internet.error.ConnectionDone: Connection was closed cleanly. - -LP: #1581318 [2.0b4 UI/API] No notifications rack controller is disconnected. No power type available - -LP: #1580350 [2.0b5] AMT machines using wsman do not netboot - -LP: #1581737 [2.0b5] When installing secondary region controller on its on, last image sync is never - -LP: #1583685 [2.0b5] Can't force the import of images per Rack Controller - -LP: #1585649 [2.0b5] After changing proxy, MAAS cannot install images - -LP: #1584936 [2.0b5] MAAS doesn't import default images automatically - -LP: #1558635 [2.0b5] Trying to assign an IP address statically to a device results in builtins.AttributeError: 'NoneType' object has no attribute 'link_subnet' (vid, fabric_id)=(2, 0) already exists. - -LP: #1583333 [2.0b5] duplicate key on startup: Key - -LP: #1588531 [2.0b5] Deployed regions should be able to transistion back to machines +2.1.0 +===== -LP: #1581224 [2.0b5] domain details page does not update as the domain contents change +Important announcements +----------------------- -LP: #1583392 [2.0b5] Cannot disable DHCP if you remove the subnet first ("Cannot configure DHCP: At least one dynamic range is required.") +**New MAAS dashboard, now including discovered devices!** + In MAAS 2.1, administrators will be redirected to the new MAAS dashboard + after they log in to the Web UI. On the dashboard, administrators are guided + through where to go to quickly get MAAS up and running. In addition, + administrators can view hosts that have been discovered on the network, and + quickly convert them to a device in MAAS. + +**Image streams have been upgraded to v3. (Important: update your mirrors!)** + In order to support the new kernels, MAAS has moved to a new format for image + streams. Previous releases used stream in “v2” format. Starting from MAAS 2.1, + the “v3” format image stream will be used. + + Users upgrading from earlier versions of MAAS who are using the default images + URL will be automatically migrated to the new “v3” URL. + + For users with custom mirrors, MAAS will not migrate the image URL + automatically. Users must ensure their image mirrors contain the “v3” stream, + which is available at http://images.maas.io/ephemeral-v3/. Old images + downloaded from the “v2” stream will continue to work until the mirror is + updated, but the MAAS team only supports MAAS 2.1 users using the “v3” stream. + Please note that bootloaders are now included in the mirror; be sure to mirror + them in addition to the images. + +**New hardware enablement kernel naming convention** + Starting from MAAS 2.1 and Ubuntu 16.04 "Xenial", MAAS is adhering to a new + naming convention for hardware enablement kernels. On Xenial and above, MAAS + will not support HWE kernels with the old naming convention, but it will + support HWE kernel channel. For example, given Ubuntu 16.04 "Xenial" and + Yakkety, currently available kernels in MAAS are: + + * ga- + The GA, or general availability kernel is the kernel which the Ubuntu + release shipped with. For example ‘ga-16.04’ is the default 4.4 kernel + which shipped on Ubuntu 16.04 "Xenial". The ga kernel contains all bug and + security fixes provided by the Ubuntu archives. Deployments which use the + ga kernel will stay at the same kernel version through upgrades until the + entire release is upgraded with ‘do-release-upgrade.’ + + * hwe- + The latest Hardware Enablement Kernel currently available in a given + Ubuntu release. As new Hardware Enable Kernels are released with new Ubuntu + releases the hwe- kernel will be upgraded up until the next LTS. + For example hwe-16.04 is currently the 16.04 GA kernel. Once 16.10 is + released the hwe-16.04 kernel will be upgraded to the 16.10 GA kernel. The + kernel will continue to be upgraded up until and including the 18.04 GA + kernel. + +**Commissioning-user-data and pxe/uefi templates no longer available** + In the past, MAAS stored commissioning-user-data and pxe/uefi templates in + /etc/maas/templates. As of MAAS 2.1, these templates are no longer available + under /etc/maas. -LP: #1588846 [2.0b5] builtins.ValueError: invalid literal for int() with base 10 +Major new features +------------------ -LP: #1585628 [2.0, UI] Bulk actions-Nodes action doesn’t apply should be red +**First user configuration journey (UI)** + MAAS now provides the ability for administrators to perform some initial + configuration immediately after they log-in into the MAAS UI for the first + time. The configuration includes: + + * Ability to change the name of your MAAS + * Ability to configure options that affect connectivity: + * Option to select an Upstream DNS Server (Optional) + * Option to input different Ubuntu Mirrors (Required) + * Option to input an external proxy (Optional) + * Ability to select additional images to download + * Ability to import SSH keys from Launchpad or Github + +**Device discovery** + MAAS will now automatically listen to the network and report any discovered + devices. Devices are identified when the MAAS rack observes them + communicating on an attached IPv4 subnet. Discovered devices that do not + correspond to machines and devices already known to MAAS are shown on the + dashboard. If a device advertises a hostname using mDNS (such as with avahi + or Bonjour), MAAS will also present the discovered hostname in the dashboard. + Using the dashboard, a discovery can quickly be added to MAAS as a device or + as a network interface to a machine or device. + +**Active subnet mapping** + The device discovery feature was designed to operate passively by default. + While MAAS will not send any traffic on attached networks for discovery + purposes unless instructed to, there are two ways to instruct MAAS to map + your networks: + + * On-demand: administrators can choose to map their subnet using an action + on the subnet details page. This action will scan the subnet just once, so + that observed devices on that subnet may quickly be seen in the dashboard. + This feature is useful after initially installing MAAS, to quickly populate + the list of discoveries with active devices on the network. + + * Periodically (recommended): by enabling active discovery on a per-subnet + basis, subnets will be scanned at a user-specified interval. (default is + every three hours) This allows MAAS to maintain current information about + which IP addresses are in use on each subnet. + + Before actively mapping any networks, it is recommended that the ‘nmap’ + package be installed on each MAAS rack controller. Doing so results in faster + scans that require less network traffic. (If ‘nmap’ is not installed, MAAS + will resort to scanning using the ‘ping’ utility.) + +**Offline deployment and customizable APT repositories** + MAAS 2.1 improves its offline deployment capabilities by adding support for + Ubuntu derived repositories, PPAs, and custom APT repositories. This enables + MAAS to configure deployed machines with the correct APT repositories and + keyrings, without being dependent on Internet connectivity. + + * Ubuntu Derived Repositories (from an Ubuntu Mirror) + MAAS 2.0 and earlier versions only allowed users to change the Ubuntu + archive to use. This was limited to defining the location of an official + Ubuntu mirror. + + Derived repositories are based on an Ubuntu mirror, but have had packages + added or removed, which requires signing the repository with an unofficial + GPG key. MAAS now allow users to provide GPG key fingerprints to support + this type of repository. These fingerprints are required in order for + the derived repository to be trusted, and will be added to the APT keyring + on each machine. + + * PPAs + PPAs can now be specified, which will be added to the APT sources on + deployed machines. Users may define a GPG key fingerprint in order for + the machine to trust the PPA, for cases where the deployed machine cannot + access the Ubuntu key server. + + * Custom repositories + Custom repositories can be specified to add additional packages to deployed + machines. For custom repositories, the distribution and component can be + customized as appropriate. For example, users would be able to add the + Google Chrome repository, which is as follows: + + deb http://dl.google.com/linux/chrome/deb/ stable main + + In this case, the distribution is “stable”, and the component is “main”. + (Multiple components may also be specified.) + +**MAAS time sync, NTP services and configuration** + MAAS now provides managed NTP services (with ntpd) for all region and rack + controllers. This allows MAAS to both keep its own controllers synchronized, + and keep deployed machines synchronized well. + + * Region controllers synchronize time externally + The MAAS region controller configures the NTP service (ntpd) to keep its + time synchronized from one or more external sources. By default, the MAAS + region controller uses ntp.ubuntu.com. This can be customized on the + settings page. + + * Rack controllers synchronize time from the region controller + The rack controllers also configure the NTP service (ntpd). Unlike the + region controllers, rack controllers synchronize their time from region + controllers, rather than accessing an external time source. + + Rack controllers also configure DHCP with the correct NTP information, so + that any machine on the network that obtains a DHCP lease from MAAS will + benefit from the enhanced NTP support. + + * Controllers and Machines can synchronize time for external time sources only. + MAAS 2.1 also provides the ability to directly use external time sources + without using the Rack Controller as a source of time for machines. This + means that administrators who already have their own NTP infrastructure, + and they don’t want MAAS to provide NTP services, they can tell all + machines and controllers to sync their time from the external time source. + This can be done by selecting the "External Only" option on the Settings + page. + +**Advanced networking: static routes** + MAAS 2.1 introduces the ability to define static routes. This allows + administrators to configure reachability to a subnet from a source subnet. + Administrators can define routes on a per-subnet basis to use a particular + gateway, using a configured destination and metric. + +**Machine networking: bridge configuration** + MAAS now supports the creation of bridge interfaces. This support is limited + to the ability to create a bridge against a single interface, such as for the + purpose of eventually deploying virtual machines or containers on the machine. + + Automatic bridge creation on all configured interfaces can also be performed + at allocation time using the API. + +**Rescue mode** + MAAS 2.1 supports a new state in the machine lifecycle: rescue mode. Rescue + mode allows users to boot a Deployed or a Broken using an ephemeral image. + (That is, Ubuntu is running in memory on the machine.) This allows + administrators to SSH to the machine for maintenance purposes, similar to + running Ubuntu from a USB stick. + +**Enhanced images user interface** + The MAAS images page has been completely redesigned. Improvements include: + + * Supports selecting the image source (maas.io or custom repository). + * Now shows the image releases and architectures available in a repository before the import starts. + * Now displays detailed status throughout the image import process. + * The Boot Images section in the settings page has been removed. -LP: #1587936 [2.0, UI] Add fabric, VLAN, Space show's badly place form +Minor new features +------------------ -LP: #1587939 [2.0, UI] 'Commission' a node under the Node Listing Page shows actions not correctly formatted. +**Disk erasing improvements and secure erase** + In 1.7 (and later) MAAS introduced the ability to erase disks on machine + release. This support was limited to erasing the whole disk and could only + be enabled (or disabled) globally. + + Starting from MAAS 2.1, it now supports the ability to request disk erasure + on a per-machine basis, at the time the machine is released. In addition, new + options for the disk erase mode have been added: + + * Secure erase - If this option is enabled, MAAS will attempt to erase via + secure erase (if the storage device support it), otherwise, it will perform + a full erase or a quick erase (depending on the options provided). + + * Quick erase - If this option is enabled, MAAS will only erase the beginning + and the end of each storage device. + +**Machine networking: - SR-IOV auto-tagging, tags UI** + MAAS now allows the definition of tags per network interface via the WebUI. + Additionally, MAAS also attempts to auto-detect and tag SR-IOV NIC cards. + +**Support for low latency kernels** + Starting from Ubuntu 16.04 “Xenial” and later, “low latency” kernels available + on i386 and amd64 for both GA and HWE kernels. The currently available + lowlatency kernels are: + + * hwe-x-lowlatency - For using the Xenial Lowlatency kernel on Trusty + * ga-16.04-lowlatency - For using the GA lowlatency kernel on Xenial + * hwe-16.04-lowlatency - For using the HWE lowlatency kernel on Xenial. + +**Bootloaders are now provided in the image stream** + Previously, bootloaders where downloaded on the rack controller from the + Ubuntu archives for each architecture MAAS had images for. Starting from MAAS + 2.1, bootloaders are downloaded with the images. All rack controllers retrieve + all supported bootloaders from the region controller. MAAS no longer directly + interacts with the Ubuntu archives. + + In the case that bootloaders are missing from the stream, MAAS will attempt + to locate previous downloads of the bootloader as well as package installs of + the bootloader. Users with image mirrors must ensure image their mirrors + include the bootloaders in order to be running the latest supported versions. + +**SSH keys can be imported from Launchpad or GitHub** + All users will now have the ability to import their SSH public keys from the + UI. Users who log-in to MAAS for the first time will be prompted to import + their SSH keys, if desired. Alternatively, users can import keys later on + their user profile page, or continue to upload keys manually. -LP: #1587998 [2.0, UI] Add domain show's badly place form +Other notable changes +--------------------- -LP: #1588000 [2.0, UI] There's no spacing between combo boxes under the Machine Details page +**Better error surfacing for DHCP snippets and package repositories** + Both the DHCP Snippets section and the Package Repositories section have been + improved in order to show errors in a more user-friendly way. +**Vanilla framework: HTML and CSS updates, smoother look and feel** + The HTML templates and CSS frameworks in MAAS have been completely rebuilt + with the Vanilla CSS framework. Icons and interactions in MAAS have greatly + improved; users will notice smoother, more intuitive interactions with the UI. -2.0.0 (beta5) -============= + The MAAS team would like to thank the Canonical design and web teams for their + contributions in this area. Issues fixed in this release ---------------------------- -LP: #1572076 [UI 2.0b1] Impossible to change subnet CIDR or gateway with instant editing - -LP: #1568102 [UI 2.0b1] Network details page doesn't have CSS for editting - -LP: #1571670 [UI 2.0b2] Can't edit fabric's, vlans, subnets from the WebUI - -LP: #1571672 [UI 2.0b2] Can't add/edit/delete IP ranges through UI - -LP: #1570990 [UI/Backend 2.0b2] Can't delete a rack controller from the Rack Details Page - -LP: #1576267 [UI 2.0b3] interface addresses on rack controller details page not updated automatically - -LP: #1577386 [UI 2.0b4] Actions list is unordered - -LP: #1580827 [UI 2.0b4] I can 'add special filesystem' when the machine is deployed - -LP: #1521618 [1.9] wrong subnet in DHCP answer when multiple networks are present - -LP: #1536346 [2.0] include maas resetMachine() API primitive - -LP: #1575567 [2.0] Re-commissioning doesn't detect storage changes - -LP: #1570002 [2.0] Expose custom network in non ubuntu deployments - -LP: #1580260 [2.0a4] Reserved IP ranges should be allowed to be created by standard users - -LP: #1542353 [2.0b2] 6 Core system is listed as having a single CPU +A full list of issues fixed in this release is available in the Launchpad 2.1.0 +Milestone page -LP: #1570995 [2.0b2] Cannot delete a rack controller that was previously a 'machine' + https://launchpad.net/maas/+milestone/2.1.0 -LP: #1576758 [2.0b3] IP Ranges section on the subnet page should be shown even if no ranges -LP: #1372544 [2.0b3] Tag changes depend on rack / cluster connection - -LP: #1577953 [2.0b4] Rack Controller fail to update commissioning info? - -LP: #1577954 [2.0b4] Rack Controller mark-broken / mark-fixed - -LP: #1577970 [2.0b4] Registering external rack controller tracebacks - -LP: #1578800 [2.0b4] RackControllerService flooding log with: 'RegionAdvertisingService' object has no attribute 'processId' - -LP: #1580405 [2.0b4] set_initial_networking_configuration shouldn't raise ValidationError - -LP: #1580280 [2.0b4] Disks less than 4MB in size cause a traceback on the MAAS server - -LP: #1577974 [2.0b4] Rack Controller details page shows "never" under last image sync - -LP: #1580285 [2.0b4] Machines successfully commission but don't get marked 'Ready' - -LP: #1581654 [2.0b4] Region RPC losing connection and raising exception - -LP: #1580771 [2.0b4] unregisterConnection() missing 1 required positional argument: 'host' - - -2.0.0 (beta4) -============= +2.1.0 (RC1) +=========== Issues fixed in this release ---------------------------- -LP: #1527634 [2.0] Disk erasing with Xenial results it abnormal poweroff +LP: #1569365 TestPartition.test_get_partition_number_returns_starting_at_2_for_ppc64el fails spuriously -LP: #1555864 [2.0a1] UI Nodes page shows 'ascii' codec can't decode byte +LP: #1598470 "Deployed" and "Deploying" are too similar -LP: #1574003 [2.0a4] When power_type changed to manual "power_state" was not set to "unknown" +LP: #1536354 Users' maas api keys do not have a name -LP: #1571007 [2.0b2] MAAS Rack Controller doesn't log when it is importing images. +LP: #1631358 [2.1] Incorrect logging message - showing SERVICE_STATE.ON -LP: #1575945 [2.0b3] rackd fails to register vlan interfaces with "vlan" naming scheme +LP: #1631420 [2.1 UI] Images page "Queued for download" is confusing when selections are not saved -LP: #1573492 [2.0b3] Traceback deleting fabric +LP: #1631024 [2.1b1] Dashboard column widths for discovered items are wonky -LP: #1566108 [2.0b3] adding files with paths in the filename confuses maas +LP: #1631022 [2.1b1] 'Registering existing rack controller' -LP: #1571621 [2.0b3] MAAS does not add node to DNS Domain +LP: #1629604 [2.1] Command 'interface link-subnet' does not work -LP: #1573644 [2.0b3] tag only supports 'nodes' and and not 'machines' or 'controller's +LP: #1628114 [FUJ] SSH input field not indicated for invalid username & the error is incomprehensible -LP: #1573264 [2.0b3] enlistment fails: /tmp/sh.UZ7qJT/bin/maas-enlist: archdetect: not found +LP: #1629475 [2.1 ipv6] DHCP generation should not fail when address-family conflicts are present -LP: #1562919 [2.0b3] creating a dnsresource-record at the root of a zone should allow fqdn= +LP: #1603466 [2.0rc2] Commissioning node with gateway_link_v4 set fails. -LP: #1573690 [2.0b3] In the domain details pages, sometimes names have links to nodes when they should not +LP: #1608555 [2.1, 2.0 UI] Error when using dhcp range with pre-existing dynamic reservation -LP: #1576854 [2.0b3] Can't power on/off Rack Controller +LP: #1632815 [2.1b2] Node failed to be released, because of the following error: 'NoneType' object has no attribute 'addErrback' -LP: #1573660 [2.0b4] ipranges create raises incorrect error for missing type +LP: #1632395 [2.1, Yakkety, UI] UI error when adding a chassis -LP: #1557597 [UI 2.0] fabric and space pages fail to update automatically +LP: #1631079 [2.0, 2.1 UI] Other reserved IP ranges disappear when one of them is deleted on Subnet details page. -LP: #1567150 [UI 2.0b1] Subnet page doesn't show which machine or device owns an IP address +LP: #1630667 [2.1b1] MAAS fails to deploy systems with 3+ TB disks -LP: #1571680 [UI 2.0b2] MAAS Controller listing page doesn't indicate whne a rack is downloading images +LP: #1630633 [2.1 Yakkety UI] Unable to select nodes -LP: #1573219 [1.9.1] Deleting user in UI leads to 500 +LP: #1629061 [2.0, 2.1] Release and list IPs reserved by another user -LP: #1556219 [1.9.1] maas enlistment of power8 found ipmi 1.5 should do ipmi 2.0 +LP: #1605476 [2.0rc2] Changing DNSSEC validation does not trigger configuration file update -2.0.0 (beta3) +2.1.0 (beta2) ============= Issues fixed in this release ---------------------------- -LP: #1573219 Deleting user in UI leads to 500 - -LP: #1553665 Unconfigured interfaces shouldn't add DNS records - -LP: #1571563 Can't override built in partitioning +LP: #1630394 [2.1] Bootloaders not downloaded on initial import -LP: #1566109 adding a device with no mac address gives an internal server error +LP: #1611949 cryptic error when PXE-boot requires an image not yet imported -LP: #1564927 [2.0] Can't start OMAPI protocol: address not available +LP: #1625676 [2.0, 2.1, UI] MAAS webui allows boot disk to be changed on an already deployed node -LP: #1570606 [2.0] subnet.list: list index out of range error when using a /31 subnet +LP: #1630591 Rename "Networks" tab to "Subnets" -LP: #1570600 [2.0b2] Trying to enabled dhcp on fabric-1 with IPv4 networks, results in maas-dhcpd6 attempted to be enabled +LP: #1628761 [2.1] netaddr assumes MAC OUI is ascii -LP: #1570609 [2.0b2] builtins.TypeError: cannot use a bytes pattern on a string-like object +LP: #1619262 [2.1, 2.0] Can't input dynamic range on "Enable DHCP" after I deleted the dynamic range -LP: #1571851 [2.0b2] interface_set returns an interface without 'links' even if empty +LP: #1630636 [2.1 ipv6] YAML error when maas_url has an IPv6 IP -LP: #1570626 [2.0b2] NameError: name 'LargeFile' is not defined +LP: #1612203 Machine unable to pxe with no-such-image while non-related images are being imported -LP: #1572070 [2.0b2] Cannot link physical device interfaces to tagged vlans, breaking juju 2.0 multi-NIC containers +LP: #1628645 External DHCP detection is broken for a variety of reasons -LP: #1569483 [2.0b2] Can't deploy CentOS +LP: #1627362 [2.1] expected string or bytes-like object -LP: #1571622 [2.0b2] Bad VLAN Validation on UI Node Details page +LP: #1614659 [2.1] When trying to release a node, it gets stuck in releasing if there is no rack controller to power control -LP: #1555715 [UI 2.0a1] changing a subnet's space does not cause a refresh in networks/spaces tab in the UI +LP: #1445941 WebUI needs a filter for deployed OS -LP: #1570152 [UI 2.0b1] Can't delete subnet in the UI, no action for it. -LP: #1571002 [UI 2.0b2] When reconfiguring DHCP, I can't unselect Secondary Rack Controller - - -2.0.0 (beta2) +2.1.0 (beta1) ============= -Issues fixed in this release ----------------------------- - -LP: #1563409 [2.0a4] 2.0 api is confused about its hash - -LP: #1555251 [2.0] Missing region-controller API - -LP: #1569102 API 2.0 deploy makes machine lose power information - -LP: #1564657 [2.0a4] Bridges no longer discovered by the rack controller - -LP: #1557144 [2.0a1] When Xenial is the only one image imported, nodes fail to boot after saving the commissioning image - -LP: #1556185 TypeError: 'Machine' object is not iterable - -LP: #1562198 [2.0a4] When providng DHCP a smarter default dynamic range is needed - -LP: #1568051 ThreadPool context entry failure causes thread pool to break - -LP: #1567178 [2.0 beta 1] After CD install, maas-region RPC endpoints is not available - -LP: #1566419 Rack controllers should output whether boot resources are synced - -LP: #1566920 Cannot change power settings for machine - -LP: #1568041 "[2.0beta1] macaddress_set should be removed from the machines and devices API" - -LP: #1568045 [2.0beta1] constraint_map should be removed from the machines acquire output - -LP: #1567213 Devices results missing interface_set - -LP: #1568847 "[2.0 beta1 ] Service 'maas-proxy' failed to start - -LP: #1543195 Unable to set mtu on default VLAN - -LP: #1566336 MAAS keeps IPs assigned to eth0, even after eth0 is enslaved into a bond - -LP: #1546274 Importing custom boot images is broken in MAAS 1.10. - -LP: #1566503 "Failed talking to node's BMC: cannot use a string pattern on a bytes-like object" - -LP: #1543968 MAAS 1.9+ allows non-unique space names and shows no space id in a subnet - -LP: #1543707 MAAS 1.9+ should not allow whitespace characters in space names - -LP: #1560495 [UI 2.0a3] Bad table spacing between columns - -LP: #1561733 [2.0a3] MAAS no longer detects external DHCP servers - -LP: #1566848 [2.0 beta1] Xenial is not the default image - -LP: #1563701 [2.0] VLAN interfaces of secondary rack-controller are not reported - -LP: #1561991 [2.0a4] Doesn't use modify over the OMAPI - -LP: #1566829 DoesNotExist: RegionControllerProcess matching query does not exist. - -LP: #1561954 Ubuntu Server install menu needs a 16.04 refresh - -LP: #1564971 [2.0a4] duplicate ipranges cuase dhcpd Configuration file errors - -LP: #1568207 Remove deprecated node-interface - +Important Announcements +----------------------- -2.0.0 (beta1) -============= +**New Hardware Enablement Kernels naming convention** + Starting from MAAS 2.1 and Ubuntu Xenial, MAAS is adhering to a new naming + convention for hardware enablement kernels. On Xenial and above, MAAS will + not support HWE kernels with the old naming convention, but it will support + HWE kernel channel. For Ubuntu Xenial and Yakkety, currently available + kernels in MAAS now are: + + * ga- + The GA, or general availability kernel is the kernel which the Ubuntu + release shipped with. For example ‘ga-16.04’ is the default 4.4 kernel + which shipped on Ubuntu Xenial. The ga kernel contains all bug and security + fixes provided by the Ubuntu archives. Deployments which use the ga + kernel will stay at the same kernel version through upgrades until the + entire release is upgraded with ‘do-release-upgrade.’ + + * hwe- + The latest Hardware Enablement Kernel currently available in a given + Ubuntu release. As new Hardware Enable Kernels are released with new + Ubuntu releases the hwe- kernel will be upgraded up until the + next LTS. For example hwe-16.04 is currently the 16.04 GA kernel. Once + 16.10 is released the hwe-16.04 kernel will be upgraded to the 16.10 GA + kernel. The kernel will continue to be upgraded up until and including + the 18.04 GA kernel. + +**New Simplestreams Version - Update your images & your Image repositories** + In order to support the new kernels, MAAS has updated the version of the + MAAS Image streams. Previously MAAS has been using the Streams Version 2, + and as of MAAS 2.1 it will use the MAAS Streams Version 3. + + All users who upgrade from an earlier version of MAAS who have been using + the default image mirror, will be automatically migrated to the new version + of streams. + + For all those users running a custom mirror, MAAS won’t make the migration + automatically. Users are requested to update their image mirror to match the + latest images. This image mirror is now available at + http://images.maas.io/ephemeral-v3/. Major new features ------------------ -**Region Controller Redundancy** - Starting from MAAS 2.0 beta 1, MAAS now provides the ability to scale out or - provide redundancy for the MAAS Region Controller API server and DNS. This - will allow administrators to set up multiple MAAS Region Controllers - (maas-region-api) against a common database, providing redundancy of services. - With further manual configuration, users will be able to setup MAAS Region - Controller in High Availability. +**Support for Low Latency kernels.** + Starting from MAAS 2.1 Beta 1 and Ubuntu Xenial, MAAS will be making available + the ability to install low latency kernels. Low latency kernels are available + on i386 and amd64 for both GA and HWE kernels. The currently available + lowlatency kernels are + + * hwe-x-lowlatency - For using the Xenial Lowlatency kernel on Trusty + * ga-16.04-lowlatency - For using the GA lowlatency kernel on Xenial + * hwe-16.04-lowlatency - For using the HWE lowlatency kernel on Xenial. + +**Bootloaders are now provided in the SimpleStream.** + Previously bootloaders where downloaded on the Rack Controller from the Ubuntu + archives for each architecture MAAS had images for. Starting with MAAS 2.1 + Beta 1 bootloaders are downloaded with the images from the SimpleStream. All + Rack Controllers retrieve all supported bootloaders from the Region Controller. + MAAS no longer directly interacts with the Ubuntu archives. + + In the case that bootloaders are missing from the SimpleStream MAAS will + attempt to locate previous downloads of the bootloader as well as package + installs of the bootloader. Minor new features ------------------ -**MAAS Proxy is now managed** - Starting from MAAS 2.0 beta 1, MAAS now manages the configuration for - maas-proxy. This allows MAAS to lock down maas-proxy, and only allow traffic - from networks MAAS know about. For more information see :ref:`MAAS Proxy ` - -**DHCP Snippets WebUI** - MAAS 2.0 beta 1 introduces the ability to add and remove DHCP snippets via - the Web UI. This can be found under the ‘Settings’ page. This feature is - available for administrative only. - -Issues fixed in this release ----------------------------- - -LP: #1557451 [2.0] MAAS api 1.0 version returns null - -LP: #1563094 builtins.FileNotFoundError: [Errno 2] No such file or directory: 'bzr' - -LP: #1557526 [2.0a2] Link "go to rack controllers page" does not link to controllers page. - -LP: #1562106 [2.0a4] Can't assign a 'Static IP' Address - -LP: #1562888 [2.0] DHCP Snippets are not validated before committed - -LP: #1553841 [2.0a1] MAAS should ensure that BMC password is correct before saving - -LP: #1379567 maas-proxy is an open proxy with no ACLs. it should add networks automatically +**Active Device Discovery - Map your subnet** + To complete MAAS’ Active Discovery, starting from beta 1 MAAS 2.1 now allows + the user to ‘Map a subnet’, both automatically at regular intervals, or + manually: + + * Manually + Administrators can now Map a subnet manually from the Subnet Details page + under the ‘Take Action’ option. This will allow administrators to map + their subnet. By default, this will use ping but if nmap is installed, + it will automatically use nmap. + + * Automatically + Administrators can now chose to Map their subnets Automatically at regular + intervals. This allows administrators to have MAAS always probe on the + network to find new devices. By default, the automatic mechanism is enabled, + but no subnet is enabled by default. + + To automatically map each subnet, please refer to the ‘Active Discovery’ + section on the subnet details page. + +Bugs fixed in this release +-------------------------- + +LP: #1392763 When changing sync-url via the UI, it's not obvious if syncing starts on its own or not +LP: #1508975 maas deletes products/images locally that do not exist remotely +LP: #1481285 1.8 Boot images tick boxes should be orange +LP: #1629402 [2.1] please cleanup log format for new interface monitoring state +LP: #1629011 Missing punctuation in disk erasing options +LP: #1629008 Missing preposition sentence disk erasing options +LP: #1629004 Typo: "futher" +LP: #1628052 [2.1, FUJ] Help text in input fields is missing 'e.g' +LP: #1459888 Too much spacing between checkboxes/releases in the 'Images' +LP: #1627039 [2.1] Discovery object and view doesn't set a flag when the device is the DHCP server +LP: #1627038 [2.1] SSH key import should use the specified HTTP proxy if one exists +LP: #1625714 DHCP services on rack controllers only publishes external NTP servers +LP: #1625711 Peer selection for NTP servers on region controllers is broken +LP: #1593388 Changing a boot source URL while images are being download doesn't interrupt current downloads to use the new URL +LP: #1623878 [2.1] mDNS label contains disallowed characters +LP: #1394792 MAAS could do a better job of reporting image download status +LP: #1623110 [2.1] Networks page doesn't load fully on yakkety +LP: #1629896 [2.1] Deployment defaulting to hwe-16.04 instead of ga-16.04 +LP: #1629491 [2.1] After upgrade to latest trunk (pre-beta1) and after updating images, machines fail to pxe boot due to missing hwe-x kernel +LP: #1629142 2.1 DHCP reported as enabled but not running +LP: #1629045 [2.1] When failing to download images, MAAS leaves old files in the fs +LP: #1629022 [2.1, UI] Broken 'images page' link +LP: #1629019 [2.1 ipv6] log_host needs to be ipv6 when booting ipv6-only +LP: #1628298 [2.1 UI] SSH keys not listed on user page and no button to add keys +LP: #1628213 [2.1 yakkety UI] First user journey doesn't display and can't be skipped +LP: #1627363 [2.1] 'NoneType' object has no attribute 'external_dhcp' +LP: #1627019 [2.1, rev5385] NTP services on region/rack keep showing as ON/OFF constantly +LP: #1623634 [2.1, UX] Trying to cancel an image import from the new Images page results on it not being cancelled on the backend. +LP: #1589640 [2.0b6] MAAS should validate a boot source path actually provides images + +Known issues and workarounds +Trusty images not available on fresh installs +The MAAS Images V3 streams do not yet have Ubuntu Trusty available. These are currently being built to be made available. + +User’s upgrading from a previous version of MAAS that had originally imported Trusty images will continue to be able to deploy Trusty. Once the images are made available, MAAS will automatically update (if so configured). -LP: #1562214 [2.0a4] If external proxy is being used, status from maas-proxy shouldn't be surfaced +LP: #1627362 - expected string or bytes-like object +In some situations after an upgrade, accessing the dashboard might yield error above. This is a difficult to easily reproduce issue. If you come across it please contact a MAAS developer immediately. -LP: #1555392 [2.0a1] python3-maas-client needs to send data as bytes() +https://bugs.launchpad.net/maas/+bug/1627362 -LP: #1563807 Systemd units need to reflect updated MAAS names -LP: #1563799 [2.0a4] Permission error for boot-resources/cache - -LP: #1563779 [2.0a4] maas-rackd missing presumed lost - - -2.0.0 (alpha4) +2.1.0 (alpha4) ============== -Important annoucements ----------------------- +Important Announcements +----------------------- + +**MAAS Landing page - Let’s see what’s on your network!** + As of MAAS 2.1 alpha 4, administrative users have a new landing page. Once + administrators log in they will be redirected to the MAAS dashboard. -**maas-region-controller-min has been renamed to maas-region-api** - The `maas-region-controller-min` package has now been renamed to - `maas-region-api`. This package provides the API services for MAAS - (maas-regiond) and can be used to scale out the API front-end of - your MAAS region controller. + This dashboard is where administrators will have some basic information + and the ability to see the observed and discovered devices. Major new features ------------------ -**DHCP Snippets Backend & API** - MAAS 2.0 alpha 4 introduces the ability to define DHCP snippets. This - feature allows administrators to manage DHCP directly from MAAS’, removing - the need to manually modify template files. Snippets can be defined as: - - * `Host snippets`, allowing to define configuration for a particular node in MAAS. - * `Subnet snippets`, allowing to define configuration for a specific subnet in MAAS. - * `Global snippets`, allowing to define configuration that will affect DHCP (isc-dhcp) as a whole. - - For more information, see :ref:`DHCP Snippets `. +**Device discovery UI** + MAAS 2.1 alpha 4 introduces the MAAS Device Discovery UI. As part of the + dashboard, administrative users will be able to see all the observed and + discovered devices. + + MAAS will also allow administrator to properly register those discoveries + as MAAS known devices, and be able to select the IP address allocation for + them, if MAAS is to manage them. + +**Active Device Discovery - map your network (API only)** + As of MAAS 2.1 alpha 2, networks attached to rack controllers are observed + for device discovery purposes. MAAS listens to ARP requests and replies to + determine which IPv4 addresses are in-use on attached networks, and will + resolve their hostnames if possible (when advertised using the mDNS + protocol). + + As of MAAS 2.1 alpha 4, MAAS now has the ability to actively probe subnets. + This allows MAAS to keep its knowledge of which devices are on the network + up-to-date, and discover “quiet” devices that MAAS would not be able to + observe passively. If ‘nmap’ is installed, MAAS will prefer to use it for + scanning (since the scan is faster and will transmit fewer packets). If + ‘nmap’ is not installed, MAAS will fall back to using parallel ‘ping’ requests. + + Scanning is available using the API at the following URL: + + POST /MAAS/api/2.0/discovery/?op=scan + + To scan using the command-line interface, you can use the following syntax: + + maas discoveries scan [cidr= [cidr=....] [force=true] [always_use_ping=true] [slow=true] [threads=] + + If you want to scan particular subnets, specify one or more using the cidr + option. For example, ‘cidr=192.168.0.0/24’ would scan for neighbours on + 192.168.0.0/24 on any rack controller configured with an address in that + network. The cidr option can be specified multiple times, such as + ‘cidr=192.168.0.0/24 cidr=192.168.1.0/24’. + + If you want to scan all networks attached to all rack controllers, you must + specify the “force=true” option. (This is not allowed by default, since some + network operators do not allow active neighbour scanning.) + + If your organization has a policy against using ‘nmap’, you will want to use + the ‘always_use_ping’ option, in case ‘nmap’ has been installed on a rack + controller by mistake. + + If quickly scanning your network using ‘nmap’ may raise alerts with an + intrusion detection system, you can use the ‘slow=true’ argument to slow + down scanning. This option has no effect when using ‘ping’, since scanning + using ‘ping’ is already slower. If using ‘ping’, scans can be slowed down or + sped up, if desired, by using the threads option, such as by specifying + “threads=2”. Using the threads option has less impact on nmap threads, which + use a single thread to scan an entire network. Minor new features ------------------ -**Rack Controller Web UI Improvements** - MAAS 2.0 alpha 4 adds the UI for Served VLANs and Service Tracking, allowing users - to see what VLANs are being currently served by a rack controller, and the status - of the services in those Rack Controllers. - -**Rsyslog during enlistment and commissioning** - MAAS 2.0 alpha 4 now enables rsyslog for the enlistment and commissioning - environment when using Xenial as the Commissioning image. This allows users - to see all cloud-init’s syslog information in /var/log/maas/rsyslog/. - -Known issues and work arounds ------------------------------ - -**DHCP snippets are not validated before committed** - When DHCP snippets are created, MAAS is not validating the DHCP snippet against - isc-dhcp config. This means that if users input invalid isc-dhcp configuration, - this will cause the DHCP config to be generated anyway, yielding maas-dhcp to - not be working properly or started at all. - - See bug `1562888`_ for more information. - -.. _1562888: - http://launchpad.net/bugs/1562888 - -Issues fixed in this release ----------------------------- - -LP: #1561816 Rack controller 'None' disconnected. - -LP: #1557616 [2.0a2] UI provides no way to disable DHCP - -LP: #1559332 [2.0a3] Server VLAN's UI is showing too many vlans - -LP: #1555679 [2.0a1] bridges with same mac as physical interfaces prevent rack interface discovery +**First User Journey - Import your SSH keys from Launchpad or Github** + The ability to import SSH keys from Launchpad or Github was introduced in + MAAS alpha 3. As of alpha 4, you can do so via the Front-end. + + All users will now have the ability to import their SSH keys from the UI. + All users who log-in to MAAS for the first time will be prompted to import + their SSH keys, if they so desire. Alternatively, users can do so via their + user profile page. -LP: #1560233 [2.0a3] maas-regiond not available right after install. - -LP: #1559330 [2.0a3] maas-rackd attemps to connect to regiond, constantely, without stop - -LP: #1559361 [2.0a3] maas-dhcpd is being restarted constantly while enlisting/commissioning multiple machines - -LP: #1559327 [2.0a3] dhcpd is configured incorrectly when two subnets are incorrectly placed in the same VLAN - -LP: #1549843 [2.0a1] Failed to update this region's process and endpoints; unleashed:pid=28940 record's may be out of date - -LP: #1559398 [2.0a3] Can't commission too many machines at a time +Other notable changes +--------------------- -LP: #1556366 [2.0a1] PXE interface incorrectly displayed on the UI +**NTP Improvements - MAAS NTP vs External** + MAAS now provides the ability to decide between using solely an external NTP + server or a MAAS run NTP server. MAAS run NTP services is the preferred + configuration, but, in order to maintain backwards compatibility, + administrators can chose to use external NTP organizations. This will only + be suitable for scenarios where administrators have restricted communication + between their machines and the MAAS rack controllers. + +Bugs fixed in this release +-------------------------- + +#1625668 [2.1] When trying to add SSH keys for a GH user that doesn't exist, there's no feedback +#1626748 [2.1] maas admin discoveries scan API output shows rack controller ids instead of names +#1626722 [2.1] DHPv6 addresses do not have netmasks: do not create /128 subnets for them +#1625812 [2.1] Error message is not user friendly +#1625689 [2.1] default gateway cannot be set to fe80::/64 via web ui +#1626727 [2.1] You can define distribution or component for 'ubuntu archive' or 'ubuntu extra architectures' +#1625671 [2.1] Need better error message when trying to add SSH keys for LP/GH user that doesn't exist +#1623994 [2.1] DHCP configuration breaks when NTP servers are unresolvable. +#1626669 [2.1] Can't logout, create users and do other actions +#1625674 [2.1] No feedback when there are no keys to import from LP/GH + +Known issues and workarounds +---------------------------- + +**LP: #1623634: Unable to cancel the image import.** + When downloading images, MAAS will fail to cancel the import of all or + any of the images being imported. MAAS will first download all the images + before the user is able to remove them. + + See bug `1617596`_ for more information. + +.. _1617596: + http://launchpad.net/bugs/1617596 + +**LP: 1624693: Rack failed to run/register on fresh install** + The MAAS Rack Controller is unable to register after a fresh install due to + being unable to parse network interfaces. After manual restart of maas-rackd, + the rack was successfully registered. + See bug `1624693`_ for more information. -2.0.0 (alpha3) -============== +.. _1624693: + http://launchpad.net/bugs/1624693 -Important Announcements ------------------------ -**Debian Installer Files are no longer installed** - Following the full drop of support for the Debian Installer (DI) in - 1.9, MAAS no longer downloads the DI related files from simplestreams - and on upgrade all DI related files will be removed both from the - region and all rack controllers. +2.1.0 (alpha 3) +=============== Major new features ------------------ -**Networks WebUI** - MAAS 2.0.0 alpha 3 is introducing a few new Web UI features that were - not available in MAAS 1.9 or MAAS 1.10. - - * Add Fabric and Space details pages - MAAS 2.0.0 now displays more detailed information of the Fabric and - Space, by introducing the details page for each. - - * Add ability to add/remove (create/delete) new Fabrics, Spaces, Subnets and VLANs - MAAS 2.0.0 now provides the ability to add new Fabrics, Spaces, Subnets and VLANs. - This can be done as actions under the Networks listing page. - - The ability to delete such Fabrics, Spaces, Subnets and VLANs is also available, - however, this is only possible for the non-default components and from the - component’s details page. - -**WebUI for new storage features** - MAAS 2.0.0 alpha 3 provides the ability to add mount options via the WebUI. - MAAS 2.0.0 alpha 3 also provides the ability to create new swap partitions - via the WebUI. As a reminder, previous MAAS releases would automatically - create a swap file, but starting from MAAS 2.0, users will have the - ability to create a swap partition instead, if so desired. +**First User Configuration Journey (UI)** + Starting from alpha 3, MAAS now provides the ability for administrators to + perform some initial configuration when they log-in into the UI for the + first time. The configuration includes: + + * Ability to change the name of your MAAS. + * Ability to configure options that affect connectivity: + * Option to select an Upstream DNS Server (Optional) + * Option to input different Ubuntu Mirrors (Required). + * Option to input an external proxy (Optional) + * Ability to select additional images to download. + +**MAAS time sync, NTP services and configuration** + Starting from alpha 3, MAAS now provides managed NTP services (with ntpd) in + both the Region and Rack controller. This allows MAAS to not only keep its + own controllers time synced, but the deployed machines as well. + + * Region Controller time syncs from external source + The Region Controller configures the NTP service (ntpd) to keep its time + sync from one or various external sources. By default, the MAAS region + controller syncs its time from ntp.ubuntu.com. The default can be changed + by one or multiple external NTP servers from the Settings page, under the + Network Configuration section. + + * Rack Controller time syncs from the Region Controller + The Rack Controllers also configure the NTP service (ntpd). Unlike the + Region Controllers, the Rack Controllers sync their time from the Region + Controller(s) instead of accessing directly to the external time source. + + Additionally, the Rack Controllers also configure DHCP with the correct + NTP information, so that any machine on the network that DHCP’s from MAAS + can benefit of the NTP configuration. + + * Machines configured to sync time from external NTP (transitional). + MAAS also configures deployed machines with NTP configuration. This is done + by cloud-init via MAAS vendor data. + + During the transition period, MAAS will configure machines to use the + external time source (configured under the Settings page). Note that this + is transitional, as in future releases the machines will default to the + Rack Controller for NTP. + +**MAAS Images page re-written in AngularJS** + Continuing the transition from YUI to AngularJS, the MAAS Images page has now + been completely redesigned and reimplemented in AngularJS. Improvements to + the Image page include: + + * Ability to select the image source (maas.io or custom repository). + Show the releases and architectures available in the custom repository + before the import starts. + + * Ability to view the status of the image in the import process. + Show percentage based progress on the image import. + + Additionally, the ‘Boot Images’ section in the Settings page has been removed. + +**Minor new features** + + * (Backend) Ability to import SSH keys from Launchpad and Github + MAAS now provides the ability to import SSH keys for a user from Launchpad + and Github. This is currently supported via the API or via the user + creation process. Users can import their SSH keys when creating their user + for Launchpad or Github: + + maas createadmin --ssh-import lp: + maas createadmin --ssh-import gh: + + Or via the API based CLI with: + + maas sshkeys import protocol=lp auth_id= + maas sshkeys import protocol=gh auth_id= + + * MAAS now provides cloud-init vendor data for NTP + As of MAAS 2.1 alpha 3, MAAS now provide cloud-init vendor data. Vendor + data allows cloud-init to do some initial configurations on the system + before user data is being run. As of 2.1, MAAS will provide NTP + configuration which is delivered via vendor data. Note that this is + dependent on the latest version of cloud-init (0.7.8-1-g3705bb5-0ubuntu1). + This is currently available in Yakkety and is in progress to be available + in Xenial. + + * Add ability to enable or disable network discovery + MAAS now provides the ability to disable the discovery of networks and + devices. By default, discovery is enabled. This setting can be changed + under the Settings page, or via the MAAS CLI and API using the + “network_discovery” configuration key. (Accepted values are “enabled” and + “disabled”.) When discovery is disabled, mDNS records and ARP requests will + no longer be stored in MAAS, and the listening processes on each rack + controller will be shut down. -Minor new features ------------------- +Other notable changes +--------------------- -**Ability to change a machine’s domain name from the UI** - MAAS 2.0.0 alpha 3 introduces the ability to change a machine’s DNS domain - via the WebUI. It was previously supported on the API only. +**HTML template updates** + In MAAS 2.1 alpha 3, the HTML templates and SCSS framework has been + completely rebuilt and using the current Vanilla CSS framework as its base. + This includes all design patterns and utility classes which would be expected + of a powerful frontend GUI framework. -**Rack Controller details page now shows served VLANs** - The Rack Controller details page now shows what VLANs are being served on - this Rack Controller, and whether it is the primary or secondary Rack - providing services for such VLAN. + HTML and CSS templates have been completely redesigned to use the new + “Vanilla” styles. This brings a refreshed look of icons and interactions that + benefit the UI. While users may not see much difference, it has been + completely re-implemented in the backend. -**Added `maas-rack support-dump` command** - For increased support observability, users can now dump the contents of - several commonly-needed data structures by executing `sudo maas-rack support-dump`. - This command will dump networking diagnostics, rack configuration, and image - information. Information can be restricted to a particular category by using - the `--networking`, `--config`, or `--images` options. + Thank you the design and web teams for their contribution to MAAS. -Known issues and work arounds ------------------------------ +Known issues and workarounds +---------------------------- -**Rack Controller tries to constantly reconnect** - In some situations, the MAAS Rack Controller will try to constantly re-connect - to the region controller after a restart, causing the Rack Controller to be - unavailable for a period of time. +**Unable to cancel the image import.** + When downloading images, MAAS will fail to cancel the import of all or any of + the images being imported. MAAS will first download all the images before the + user is able to remove them. - At the moment, there's no work around other than to wait for a few minutes - until the Rack Controller has been fully connected. + See bug `1623634`_ for more information. - See bug `1559330`_ for more information. +.. _1623634: + http://launchpad.net/bugs/1623634 -.. _1559330: - http://launchpad.net/bugs/1559330 +**Unable to enable DHCP if NTP server is unresolvable.** + If the NTP server(s) are unresolvable, DHCP will fail to enable. This is + because DHCP doesn’t accept DNS names for DHCP’s NTP configuration, and as + such, MAAS tries to resolve the domain before it is able to set it in the + configuration. -Major bugs fixed in this release --------------------------------- + See bug `1623994`_ for more information. -LP: #1555393 python3-maas-client API 2.0 seems to no longer use op but MAASClient.post requires it and incorectly passes it along +.. _1623994: + http://launchpad.net/bugs/1623994 -LP: #1554566 Fail to commission when Fabric on Machine Interface and Rack Interface dont match +**Rack failed to run/register on fresh install** + The MAAS Rack Controller is unable to register after a fresh install due to + being unable to parse network interfaces. After manual restart of maas-rackd, + the rack was successfully registered. -LP: #1553848 TFTP back-end crashes + See bug `1624693`_ for more information. -LP: #1554999 Can't deploy a node (no interfaces on rack controller) +.. _1624693: + http://launchpad.net/bugs/1624693 -2.0.0 (alpha2) +2.1.0 (alpha2) ============== Important Announcements ----------------------- -**maas-region-admin command has been replaced** - The MAAS Region command, `maas-region-admin` has now been replaced - by the `maas-region` command. - -**maas-provision command has been replaced** - The MAAS Rack Controller command, `maas-provision`, has now been - replaced by the `maas-rack` command. +**commissioning-user-data and pxe/uefi templates no longer available** + In the past, MAAS stored commissioning-user-data and pxe/uefi templates + in `/etc/maas/templates`. As of MAAS 2.1.0 Alpha 2, these templates are + no longer available under /etc/maas. -Major new features +Major New Features ------------------ -**Networks listing page** - A new Networks listing page has been introduced, that allows users - users to have a better view of MAAS networking concepts under the - 'Networks' tab. It allows users to filter by `Fabric` and `Space`. +**(Backend) Device Discovery** + As of MAAS 2.1.0 Alpha 2, MAAS will automatically listen to the network + and report any observed devices. + + * New discovery API can be used to get information about what MAAS has + discovered. This API can be used from the command line interface as + follows: + + * maas discoveries read - Lists all MAC, IP bindings + (discoveries) that MAAS has seen, and attempts to correlate those + discoveries with hostnames advertised by mDNS. + * maas discoveries by-unknown-mac - Lists all discoveries, + but filters out discoveries where the MAC belongs to an interface + known to MAAS. + * maas discoveries by-unknown-ip - Lists all discoveries, + but filters out discoveries where the IP address is known to MAAS + (such as reserved by a user, or assigned to a node). + * maas discoveries by-unknown-ip-and-mac - Lists all discoveries, + but applies the filters for both unknown MACs and unknown IP addresses. + + * Note that the discovery API is currently read-only. It brings together + data from several different sources, including observed network neighbours, + resolved mDNS hostnames, and controller interface information. + * New maas-rack commands have been added, which are called internally by + MAAS in order to gather information about observed devices on the network. + MAAS administrators should not normally need to use these commands + (although they could be helpful for supportability). + + * maas-rack observe-mdns [--verbose] + * sudo maas-rack observe-arp [--verbose] + + * Note: this feature intentionally does not place any network devices into + “promiscuous mode”, or actively probe. MAAS controllers listen to ARP + traffic they would have received anyway. Therefore, if a MAAS admin wants + to keep MAAS’s knowledge of the network up-to-date, a command such as one + of the following could be run periodically (such as from a script invoked + by a crontab); MAAS will listen to any ARP replies and update its knowledge + of the network: + + * To actively probe one or more subnet CIDRs on an interface: + sudo nmap -e -sn -n -oX - -PR [cidr2] [...] + + * To actively probe for a single IP address from a particular interface + (regardless of whether or not the IP address is routable on-link on that + interface): + ping -r -I -c 3 -w 1 -i 0.2 -D -O + + * MAAS now depends on the avahi-utils and tcpdump packages in order to provide + this functionality. (Before MAAS 2.1.0 is released, the MAAS team will consider + making these optional dependencies, in case MAAS administrators do not want + to run the avahi daemon, or require that tcpdump not be installed.) + +Important Bugs Fixed in this Release +------------------------------------ + +**Bug #1617596: [2.1] Rack(relay) Controller is rejected after upgrade to 2.1** + Fixes a regression regarding registering rack controllers which have bonds + interfaces which are not currently bonding any interfaces. + + See bug `1617596`_ for more information. + +.. _1617596: + http://launchpad.net/bugs/1617596 + +**Bug #1615618: [2.1] 'SERVICE_STATE' object has no attribute 'getStatusInfo'** + Fixes a regression in the service tracking mechanism, where it would fail to + successfully track the status of some services. -**Service Tracking** - MAAS is now fully tracking the status of the services for the different - services that MAAS uses, as defined by systemd. These services are: + See bug `1615618`_ for more information. - * maas-proxy - * bind - * maas-dhcpd and maas-dhcpd6 - * tgt +.. _1615618: + http://launchpad.net/bugs/1615618 -Known issues & work arounds ---------------------------- -**Failure to commission when Machine interfaces are not in the same fabric as DHCP** - Machines fail to commission when its interfaces are in a different fabric from the - one DHCP is running on. - - For example, if DHCP is enabled on `fabric-2`, and the machine's PXE interface is on - `fabric-0`, the machine will fail to commission. To work around this, you can update - the Rack Controller interface connected to `fabric-2`, to be under `fabric-0`, and - enabling DHCP on the `untagged` VLAN under `fabric-0`. - - See bug `1553617`_ for more information. - -.. _1554566: - https://launchpad.net/bugs/1554566 - - -2.0.0 (alpha1) -============== - -Important Announcements ------------------------ - -**MAAS 2.0 supported on Ubuntu 16.04 LTS (Xenial)** - MAAS version 2.0 will be supported on Ubuntu 16.04 LTS. MAAS 2.0 (and - the transitional 1.10 release) will NOT be supported on Ubuntu 14.04 LTS. - MAAS versions 1.9 and earlier will continue to be supported on Ubuntu - 14.04 LTS (Trusty) until they reach end-of-life. - - Upgrades are supported for users running Ubuntu 14.04 systems running - MAAS 1.9 or earlier. Upon upgrading to Ubuntu 16.04, the MAAS - database and configuration will be seamlessly migrated to the supported - MAAS version. - - Please see the “Other Notable Changes” section below for more details - regarding the reasons for this change. - -**API 1.0 has been deprecated, introducing API 2.0** - Starting from MAAS 2.0, the API 1.0 has now been deprecated and a new - MAAS 2.0 API is being introduced. With the introduction of the new - API version, various different endpoints have now been deprecated - and new end-points have been introduced. API users will need to update - their client tools to reflect the changes of the new API 2.0. - - For more information on API 2.0, refer to :ref:`API documentation `. - -**Cluster Controllers have now been deprecated. Introducing Rack Controllers** - Starting from MAAS 2.0, MAAS Cluster Controllers have been deprecated - alongside with the NodeGroups API. The Cluster Controllers have been - replaced with Rack Controllers, and the RackController API have now - been introduced. Thehe new Rack Controllers currently provides feature - parity with earlier versions of MAAS. - - For more information on Rack Controllers, refer to the `Major new Features` - section bellow or refer to :ref:`rack-configuration`. - -**MAAS Static Range has been deprecated** - Starting from MAAS 2.0, the MAAS Static Range has now been deprecated, - and MAAS assumes total control of a subnet. MAAS will auto-assign IP - addresses to deployed machines that are not within a dynamic or a reserved - range. Users are now only required to (continue to) specify the dynamic - range, which continues to be used for auto-enlistment, commissioning, - and any other systems configured for DHCP. - -Major new features -------------------- - -**MAAS Rack Controllers** - Starting for MAAS 2.0, MAAS has introduced Rack Controllers that completely - replace Cluster Controllers. - - * NodeGroups and NodeGroupInterfaces API endpoints are now deprecated. - RackControllers API endpoint has been introduced. - - * Clusters tab is no longer available in the WebUI. - Controllers can now be found under the Nodes tab, where each cluster - interface can be found. Other cluster interface properties have been - moved to the Subnet and VLAN details page under the “Networks” tab. - - * Machines no longer belong to Rack Controllers. - In earlier versions of MAAS, Machines would directly belong to a Cluster - Controller in order for them to be managed. The Cluster Controller that - the machine belonged to would not only perform DHCP for that machine, - but also all the PXE/TFTP booting, and power management. - - As of MAAS 2.0, Machines no longer belong to a Rack Controller. Multiple - Rack Controllers could potentially manage the machine. This is now - automatically determined. - - * DHCP now configured per VLAN - In earlier versions of MAAS, DHCP was directly linked and configured - per Cluster Controller Interface. As of MAAS 2.0, DHCP is now configured - and managed per VLAN, allowing the ability for any Rack Controller in a - VLAN to manage DHCP. - - * Rack Controllers now provide High Availability - Provided that machines no longer belong to a Rack Controller, and that - DHCP is managed on the VLAN bases, multiple Rack Controllers can manage - the same set of machines. Starting from MAAS 2.0, Rack Controllers in the - same VLAN become candidates to manage DHCP, PXE/TFTP, and power for the - machines connected to the VLAN. - - As such, Rack Controllers now support high availability. MAAS supports - the concept of Primary and Secondary Rack Controller. In the event that - the Primary Rack Controller is unavailable, the Secondary Rack Controller - can take over the services provided providing High Availability. - -**DNS Management** - MAAS 2.0 extends DNS management and provides the ability to: - - * Ability to create multiple DNS domains. - * Ability to add multiple records (CNAME, TXT, MX, SRV ) per - domain. (API only) - * Ability to select Domain for Machines and Devices. (API only, WebUI - in progress) - * Ability to assign (additional) names to IP addresses (API only) - * For deployed machines, A records continue to be create specifying - the IP of the PXE interface. - * Additional PTR records and now created for all the other interfaces in - the form of: . - * Reverse DNS is now generated for only the subnet specified, rather - than the parent /24 or /16. By default, RFC2137 glue is provided - for networks smaller than /24. This can be disabled or changed - on a per-subnet basis via the API. - -**IP Ranges** - Previous versions of MAAS used the concepts of a “dynamic range” and - “static range”, which were properties of each cluster interface. This - has been redesigned for MAAS 2.0 as follows: - - * Dynamic ranges have been migrated from MAAS 1.10 and earlier as-is. - - * Because static ranges have been removed from MAAS, each static - range has been migrated to one or more reserved ranges, which - represent the opposite of the previous static range. (MAAS now - assumes it has full control of each managed subnet, and is free - to assign IP addresses as it sees fit, unless told otherwise.) - - For example, if in MAAS 1.10 or earlier you configured a cluster - interface on 192.168.0.1/24, with a dynamic range of 192.168.0.2 - through 192.168.0.99, and a static range of 192.168.0.100 through - 192.168.0.199, this will be migrated to: - - IP range #1 (dynamic): 192.168.0.2 - 192.168.0.99 - IP range #2 (reserved): 192.168.0.200 - 192.168.0.254 - - Since 192.168.0.100 - 192.168.0.199 (the previous static range) - is not accounted for, MAAS assumes it is free to allocate static - IP addresses from that range. - - * Scalability is now possible by means of adding a second dynamic - IP range to a VLAN. (To deal with IP address exhaustion, MAAS - supports multiple dynamic ranges on one or more subnets within - a DHCP-enabled VLAN.) - - * Reserved ranges can now be allocated to a particular MAAS user. - - * A comment field has been added, so that users can indicate why - a particular range of IP addresses is reserved. - -**API 2.0 and MAAS CLI Updates** - MAAS 2.0 introduces a new API version, fully deprecating the - MAAS 1.0 API. As such, new endpoints and commands have been introduced: - - * RackControllers - This endpoint/command has the following operations - in addition to the base operations provided by nodes: - - * import-boot-images - Import the boot images on all rack - controllers - * describe-power-types - Query all of the rack controllers for - power information - - * RackController - This endpoint/command has the following operations - in addition to the base operations provided by nodes - - * import-boot-images - Import boot images on the given rack - controller - * refresh - refresh the hardware information for the given rack - controller - - * Machines - This endpoint/command replaces many of the operations - previously found in the nodes endpoint/command. The machines - endpoint/command has the following operations in addition to the - base operations provided by nodes. - - * power-parameters - Retrieve power parameters for multiple - machines - * list-allocated - Fetch machines that were allocated to the - user/oauth token. - * allocate - Allocate an available machine for deployment. - * accept - Accept declared machine into MAAS. - * accept-all - Accept all declared machines into MAAS. - * create - Create a new machine. - * add-chassis - Add special hardware types. - * release - Release multiple machines. - - * Machine - This endpoint/command replaces many of the operations - previously found in the node endpoint/command. The machine - endpoint/command has the following operations in addition to the - base operations provided by node. - - * power-parameters - Obtain power parameters for the given machine. - * deploy - Deploy an operating system to a given machine. - * abort - Abort the machines current operation. - * get-curtin-config - Return the rendered curtin configuration for - the machine. - * power-off - Power off the given machine. - * set-storage-layout - Change the storage layout of the given - machine. - * power-on -Turn on the given machine. - * release - Release a given machine. - * clear-default-gateways - Clear any set default gateways on the - machine. - * update - Change machine configuration. - * query-power-state - Query the power state of a machine. - * commission - Begin commissioning process for a machine - - Other endpoints/commands have changed: - - * All list commands/operations have been converted to read - * All new and add commands/operations have been converted to create - * Nodes - The nodes endpoint/command is now a base endpoint/command - for all other node types(devices, machines, and rack-controllers). - As such most operations have been moved to the machines - endpoint/command.The following operations remain as they can be - used on all node types. - - * is-registered - Returns whether or not the given MAC address is - registered with this MAAS. - * set-zone - Assign multiple nodes to a physical zone at once. - * read - List nodes visible to the user, optionally filtered by - criteria. - - * Node - The node endpoint/command is now a base endpoint/command for - all other node types(devices, machines, and rack-controllers). As - such most operations have been moved to the machine endpoint/command. - The following operations remain as they can be used on all node types. - - * read - Read information about a specific node - * details - Obtain various system details. - * delete - Delete a specific node. - - * With the migration of nodes to machines the following items previously - outputted with the list command have been changed or removed from the - machines read command: - - * status - Will now show all status types - * substatus, substatus_action, substatus_message, substatus_name - - Replaced by status, status_action, status_message, status_name. - * boot_type - Removed, MAAS 2.0 only supports fastpath. - * pxe_mac - Replaced by boot_interface. - * hostname - Now only displays the hostname, without the domain, of - the machine. To get the fully qualified domain name the fqdn and - domain are now also outputted. - - * And other endpoints/commands have been deprecated: - - * NodeGroups - Replacement operations are found in the - RackControllers, Machines, and BootResources endpoints/commands. - * NodeGroupInterfaces - replacement operations are found in the - RackController, IPRanges, Subnets, and VLANS endpoints/commands. - -**Extended Storage Support** - MAAS 2.0 Storage Model has been extended to support: - - * XFS as a filesystem. - * Mount Options. - * Swap partitions. MAAS 1.9 only supported the creation of a swap - file in the filesystem. - * tmps/ramfs Support. +Other Notable Changes +--------------------- - All of these options are currently available over the CLI. +**WebUI - Better error surfacing for DHCP snippets and Package Repositories** + Both the DHCP Snippets Section and the Package Repositories section have now + been improvement and will surface better errors. -Other notable changes ---------------------- +Ongoing Work +------------ -**MAAS 2.0 Requires Python 3.5** - Starting from MAAS 1.10 transitional release, MAAS has now been - ported to Python 3. The Python 3 version ported against is 3.5, - which is default in Ubuntu Xenial. - -**MAAS 2.0 now fully supports native Django 1.8 migration system** - Starting from the MAAS 1.10 transitional release, MAAS has added - support for Django 1.8. Django 1.8 has dropped support for the - south migration system in favor of the native Django migration - system, breaking backwards compatibility. As such, MAAS 2.0 has - inherited such support and moving forward migrations will be run - with the native migration system. - - Provided that Django 1.8 breaks backwards compatibility with the - south migration system, the MAAS team has put significant effort - in ensuring MAAS continues to support an upgrade path, and as - such, users from 1.5, 1.7, 1.8, 1.9 and 1.10 will be able to - upgrade seamlessly to MAAS 2.0. - -**Instant DHCP Lease Notifications** - We no longer scan the leases file every 5 minutes. ISC-DHCP now - directly notifies MAAS if a lease is committed, released, or expires. - -**Host entries in DHCP** - Host entries are now rendered in the DHCP configuration instead - of placed in the leases file. This removes any state that used - to previously exist in the leases file on the cluster controller. - Now deleting the dhcpd.leases file will not cause an issue with - MAAS static mappings. - -**Modeling BMCs** - We select one of the available rack controllers to power control - or query a BMC. The same rack controller that powers the BMC does - not need to be the rack controller that the machine PXE boots from. + * First User Journery - WebUI + * Device Discovery - WebUI + * Improved IPv6 Support + * MAAS Services - NTP + * MAAS Image Consolidation + * Support for HWE Rolling Kernels -Known Problems & Workarounds +Known Issues and Workarounds ---------------------------- -**Rack Controllers will fail to register when bond interfaces are present** - Registering Rack Controller that have bond interfaces will fail. +**Configuring APT key’s in ephemeral environment (overlayfs) fails.** + A regression preventing cloud-init from configuring APT's key in a + ephemeral environment, prevents MAAS from enlisting, commissioning and + deploying `only` when using Derived Repositories or Custom Mirrors that + require a new key. - See bug `1553617`_ for more information. + See bug `1618572`_ for more information. -.. _1553617: - https://launchpad.net/bugs/1553617 +.. _1618572: + http://launchpad.net/bugs/1618572 diff -Nru maas-2.0.0+bzr5189/contrib/preseeds_v2/curtin_userdata maas-2.1.1+bzr5544/contrib/preseeds_v2/curtin_userdata --- maas-2.0.0+bzr5189/contrib/preseeds_v2/curtin_userdata 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/contrib/preseeds_v2/curtin_userdata 2016-11-08 19:56:20.000000000 +0000 @@ -14,7 +14,7 @@ driver_04_load: ["sh", "-c", "depmod && modprobe {{driver['module']}}"] {{endif}} late_commands: - maas: [wget, '--no-proxy', '{{node_disable_pxe_url|escape.shell}}', '--post-data', '{{node_disable_pxe_data|escape.shell}}', '-O', '/dev/null'] + maas: [wget, '--no-proxy', {{node_disable_pxe_url|escape.json}}, '--post-data', {{node_disable_pxe_data|escape.json}}, '-O', '/dev/null'] {{if third_party_drivers and driver}} driver_00_key_get: curtin in-target -- sh -c "/bin/echo -en '{{key_string}}' > /tmp/maas-{{driver['package']}}.gpg" driver_02_key_add: ["curtin", "in-target", "--", "apt-key", "add", "/tmp/maas-{{driver['package']}}.gpg"] @@ -27,21 +27,3 @@ power_state: mode: reboot - -{{if node.split_arch()[0] in {'i386', 'amd64'} }} -apt_mirrors: - ubuntu_archive: http://{{main_archive_hostname}}/{{main_archive_directory}} - ubuntu_security: http://{{main_archive_hostname}}/{{main_archive_directory}} -{{else}} -apt_mirrors: - ubuntu_archive: http://{{ports_archive_hostname}}/{{ports_archive_directory}} - ubuntu_security: http://{{ports_archive_hostname}}/{{ports_archive_directory}} -{{endif}} - -{{if enable_http_proxy}} -{{if http_proxy }} -apt_proxy: {{http_proxy}} -{{else}} -apt_proxy: http://{{server_host}}:8000/ -{{endif}} -{{endif}} diff -Nru maas-2.0.0+bzr5189/contrib/preseeds_v2/enlist_userdata maas-2.1.1+bzr5544/contrib/preseeds_v2/enlist_userdata --- maas-2.0.0+bzr5189/contrib/preseeds_v2/enlist_userdata 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/contrib/preseeds_v2/enlist_userdata 2016-11-08 19:56:20.000000000 +0000 @@ -1,30 +1,5 @@ #cloud-config -{{if enable_http_proxy}} -{{if http_proxy}} -apt_proxy: {{http_proxy}} -{{elif server_host}} -apt_proxy: http://{{server_host}}:8000/ -{{endif}} -{{endif}} - -system_info: - package_mirrors: - - arches: [i386, amd64] - search: - primary: ["http://{{main_archive_hostname}}/{{main_archive_directory}}"] - security: ["http://{{main_archive_hostname}}/{{main_archive_directory}}"] - failsafe: - primary: "http://archive.ubuntu.com/ubuntu" - security: "http://security.ubuntu.com/ubuntu" - - arches: [default] - search: - primary: ["http://{{ports_archive_hostname}}/{{ports_archive_directory}}"] - security: ["http://{{ports_archive_hostname}}/{{ports_archive_directory}}"] - failsafe: - primary: "http://ports.ubuntu.com/ubuntu-ports" - security: "http://ports.ubuntu.com/ubuntu-ports" - rsyslog: remotes: maas: "{{syslog_host_port}}" diff -Nru maas-2.0.0+bzr5189/debian/changelog maas-2.1.1+bzr5544/debian/changelog --- maas-2.0.0+bzr5189/debian/changelog 2016-08-22 15:29:17.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/changelog 2016-11-08 20:03:53.000000000 +0000 @@ -1,3 +1,18 @@ +maas (2.1.1+bzr5544-0ubuntu1~16.04.1) xenial-proposed; urgency=medium + + * MAAS new upstream bugfix release, 2.1.1 bzr 5544 (SRU LP: #1639766): + - Support new consolidated images (squashfs) + - Support for new HWE kernels & Low Latency kernels. + - Support for NTP configuration + - Support for third party and derived repositories. + - Support for IPv6 + - Support for static routes + - Support for Network Bridge Configuration + - Introduce the First User Journey + - Introduce Device Discovery + + -- Andres Rodriguez Mon, 24 Oct 2016 11:28:59 -0400 + maas (2.0.0+bzr5189-0ubuntu1~16.04.1) xenial-proposed; urgency=medium * New upstream release, 2.0.0 bzr5189 (SRU LP: #1615210): diff -Nru maas-2.0.0+bzr5189/debian/control maas-2.1.1+bzr5544/debian/control --- maas-2.0.0+bzr5189/debian/control 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/control 2016-11-08 19:56:26.000000000 +0000 @@ -74,6 +74,7 @@ maas-cli (=${binary:Version}), maas-common (= ${binary:Version}), maas-proxy (= ${binary:Version}), + ntp, python3-bson, python3-django, python3-django-maas (= ${binary:Version}), @@ -95,12 +96,16 @@ Package: maas-region-controller Architecture: all -Depends: dbconfig-pgsql, +Depends: avahi-utils, + dbconfig-pgsql, + iputils-ping, maas-dns (= ${binary:Version}), maas-region-api (= ${binary:Version}), postgresql (>= 9.1), + tcpdump, ${misc:Depends}, Recommends: openssh-server +Suggests: nmap Description: Region Controller for MAAS The MAAS region controller (maas-regiond) is the REST API server for all MAAS clients, and the postgres database that maintains machine @@ -120,6 +125,7 @@ Depends: archdetect-deb, lshw, openssh-client, + python3-attr, python3-bson, python3-crochet, python3-curtin (>> 0.1.0~bzr351), @@ -182,13 +188,16 @@ Package: maas-rack-controller Architecture: all Depends: authbind, + avahi-utils, bind9utils, distro-info, freeipmi-tools, grub-common, + iputils-ping, maas-cli (=${binary:Version}), maas-common (=${binary:Version}), maas-dhcp (=${binary:Version}), + ntp, pxelinux | syslinux-common (<< 3:6.00~pre4+dfsg-5), python3-httplib2, python3-maas-provisioningserver (=${binary:Version}), @@ -197,12 +206,13 @@ python3-twisted, python3-zope.interface, syslinux-common, + tcpdump, tgt, uuid-runtime, wget, ${misc:Depends}, ${python3:Depends} -Suggests: amtterm, ipmitool, libvirt-bin, wsmancli +Suggests: amtterm, ipmitool, libvirt-bin, nmap, wsmancli Conflicts: tftpd-hpa Breaks: python-maas-provisioningserver, maas-cluster-controller @@ -229,6 +239,7 @@ Section: python Architecture: all Depends: python3-apt, + python3-attr, python3-convoy, python3-crochet, python3-curtin (>> 0.1.0~bzr275), diff -Nru maas-2.0.0+bzr5189/debian/extras/99-maas-common-sudoers maas-2.1.1+bzr5544/debian/extras/99-maas-common-sudoers --- maas-2.0.0+bzr5189/debian/extras/99-maas-common-sudoers 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/extras/99-maas-common-sudoers 2016-11-08 19:56:26.000000000 +0000 @@ -1,2 +1,8 @@ maas ALL= NOPASSWD: /usr/bin/lshw maas ALL= NOPASSWD: /sbin/blockdev + +# Control of the NTP server: MAAS needs to reconfigure it after editing +# its configuration file, and start it again if stopped manually. +maas ALL= NOPASSWD: /bin/systemctl restart ntp +maas ALL= NOPASSWD: /bin/systemctl start ntp +maas ALL= NOPASSWD: /bin/systemctl status ntp diff -Nru maas-2.0.0+bzr5189/debian/extras/99-maas-sudoers maas-2.1.1+bzr5544/debian/extras/99-maas-sudoers --- maas-2.0.0+bzr5189/debian/extras/99-maas-sudoers 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/extras/99-maas-sudoers 2016-11-08 19:56:26.000000000 +0000 @@ -11,4 +11,5 @@ maas ALL= NOPASSWD: /bin/systemctl disable maas-rackd maas ALL= NOPASSWD: /bin/systemctl stop maas-rackd maas ALL= NOPASSWD: /usr/sbin/maas-rack +maas ALL= NOPASSWD: /usr/lib/maas/maas-network-monitor maas ALL= NOPASSWD: SETENV: /usr/sbin/tgt-admin, /usr/bin/uec2roottar diff -Nru maas-2.0.0+bzr5189/debian/extras/maas-probe-dhcp maas-2.1.1+bzr5544/debian/extras/maas-probe-dhcp --- maas-2.0.0+bzr5189/debian/extras/maas-probe-dhcp 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/extras/maas-probe-dhcp 1970-01-01 00:00:00.000000000 +0000 @@ -1,7 +0,0 @@ -#!/bin/sh -if [ "$(id -u)" != "0" ]; then - echo "This utility may only be run as root." 1>&2 - exit 1 -fi -export PYTHONPATH="/usr/share/maas${PYTHONPATH:+:}${PYTHONPATH}" -exec /usr/bin/python3 -m provisioningserver.dhcp.probe "$@" diff -Nru maas-2.0.0+bzr5189/debian/extras/maas-rack maas-2.1.1+bzr5544/debian/extras/maas-rack --- maas-2.0.0+bzr5189/debian/extras/maas-rack 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/extras/maas-rack 2016-11-08 19:56:26.000000000 +0000 @@ -23,6 +23,9 @@ """Check that the runnig user is in users.""" uid = os.getuid() for user in users: + if user is None: + # Special case: this means any user is allowed. + return None user_uid = pwd.getpwnam(user)[2] if uid == user_uid: return user @@ -57,11 +60,17 @@ "removed in a future version. From now on please use 'maas-rack' " "instead.\n") - # Allow dhcpd user to call dhcp-notify. + # Allow dhcpd user to call dhcp-notify, and maas user to call observe-arp. users = ["root"] if len(sys.argv) > 1: if sys.argv[1] == "dhcp-notify": users.append("dhcpd") + if sys.argv[1] == "observe-arp": + users.append("maas") + if sys.argv[1] == "observe-mdns": + # Any user can call this. (It might be necessary for a normal + # user to call this for support/debugging purposes.) + users.append(None) # Only set the group and umask when running as root. if check_users(users) == "root": diff -Nru maas-2.0.0+bzr5189/debian/maas-common.dirs maas-2.1.1+bzr5544/debian/maas-common.dirs --- maas-2.0.0+bzr5189/debian/maas-common.dirs 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/maas-common.dirs 2016-11-08 19:56:26.000000000 +0000 @@ -1,2 +1,3 @@ var/log/maas var/lib/maas +etc/ntp diff -Nru maas-2.0.0+bzr5189/debian/maas-rack-controller.install maas-2.1.1+bzr5544/debian/maas-rack-controller.install --- maas-2.0.0+bzr5189/debian/maas-rack-controller.install 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/maas-rack-controller.install 2016-11-08 19:56:26.000000000 +0000 @@ -1,14 +1,13 @@ -# Install templates -debian/tmp/etc/maas/templates/pxe -debian/tmp/etc/maas/templates/uefi - # Install uec2roottar debian/tmp/usr/bin/uec2roottar # Install maas-dhcp-helper debian/tmp/usr/sbin/maas-dhcp-helper +# Install network monitoring scripts +debian/tmp/usr/lib/maas/maas-network-monitor +debian/tmp/usr/lib/maas/maas-dhcp-monitor + # Install all other stuff debian/extras/99-maas-sudoers etc/sudoers.d -debian/extras/maas-probe-dhcp usr/sbin debian/extras/maas-rack usr/sbin diff -Nru maas-2.0.0+bzr5189/debian/maas-rack-controller.lintian-overrides maas-2.1.1+bzr5544/debian/maas-rack-controller.lintian-overrides --- maas-2.0.0+bzr5189/debian/maas-rack-controller.lintian-overrides 2016-08-18 11:27:32.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/maas-rack-controller.lintian-overrides 2016-11-08 19:56:26.000000000 +0000 @@ -1 +1 @@ -maas-rack-controller: binary-without-manpage usr/bin/uec2roottar usr/sbin/maas-dhcp-helper +maas-rack-controller: binary-without-manpage usr/bin/uec2roottar usr/sbin/maas-dhcp-helper usr/lib/maas/maas-network-monitor usr/lib/maas/maas-dhcp-monitor diff -Nru maas-2.0.0+bzr5189/debian/maas-region-api.install maas-2.1.1+bzr5544/debian/maas-region-api.install --- maas-2.0.0+bzr5189/debian/maas-region-api.install 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/maas-region-api.install 2016-11-08 19:56:26.000000000 +0000 @@ -10,9 +10,6 @@ # Install new preseed files debian/tmp/etc/maas/preseeds -# Install templates -debian/tmp/etc/maas/templates/commissioning-user-data - # Install driver configuration file debian/tmp/etc/maas/drivers.yaml diff -Nru maas-2.0.0+bzr5189/debian/maas-region-api.postrm maas-2.1.1+bzr5544/debian/maas-region-api.postrm --- maas-2.0.0+bzr5189/debian/maas-region-api.postrm 2016-08-18 11:27:32.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/maas-region-api.postrm 2016-11-08 19:56:26.000000000 +0000 @@ -42,7 +42,7 @@ # Delete any remaining / leftover file rm -rf /usr/share/maas/maas/ rm -rf /etc/maas/regiond.conf - rm -rf /etc/maas/templates/dns.maas-old + rm -rf /etc/maas/templates.maas-old esac #DEBHELPER# diff -Nru maas-2.0.0+bzr5189/debian/maas-region-api.preinst maas-2.1.1+bzr5544/debian/maas-region-api.preinst --- maas-2.0.0+bzr5189/debian/maas-region-api.preinst 2016-08-18 11:27:32.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/maas-region-api.preinst 2016-11-08 19:56:26.000000000 +0000 @@ -30,8 +30,8 @@ rm -rf /var/lib/maas/media fi - if [ -d /etc/maas/templates/dns ]; then - mv /etc/maas/templates/dns /etc/maas/templates/dns.maas-old + if [ -d /etc/maas/templates ]; then + mv /etc/maas/templates /etc/maas/templates.maas-old fi fi diff -Nru maas-2.0.0+bzr5189/debian/maas-region-controller.postinst maas-2.1.1+bzr5544/debian/maas-region-controller.postinst --- maas-2.0.0+bzr5189/debian/maas-region-controller.postinst 2016-08-18 11:27:32.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/maas-region-controller.postinst 2016-11-08 19:56:26.000000000 +0000 @@ -21,25 +21,38 @@ configure_maas_default_url() { local ipaddr="$1" - local local_port=$(echo "$ipaddr" | cut -d":" -f2) - if [ -z "$local_port" ]; then - # Ensure MAAS binds to 5240 by default. - ipaddr=${ipaddr}:5240 + # The given address is either "[IPv6_IP]" or "IPv4_IP" or "name", such as + # [2001:db8::3:1]:5555 or 127.0.0.1 or maas.example.com. + # The ugly sed splits the given thing as: + # (string of anything but ":", or [ipv6_ip]), + # optionally followed by :port. + local address=$(echo "$ipaddr" | + sed -rn 's/^([^:]*|\[[0-9a-fA-F:]*\])(|:[0-9]*)?$/\1/p') + local port=$(echo "$ipaddr" | + sed -rn 's/^([^:]*|\[[0-9a-fA-F:]*\])(|:[0-9]*)?$/\2/p') + test -n "$port" || port=":5240" + ipaddr="${ipaddr}${port}" + maas-region local_config_set --maas-url "http://${ipaddr}/MAAS" +} + +get_default_route_ip6() { + while read Src SrcPref Dest DestPref Gateway Metric RefCnt Use Flags Iface + do + [ "$SrcPref" = 00 ] && [ "$Iface" != lo ] && break + done < /proc/net/ipv6_route + if [ -n "$Iface" ]; then + LC_ALL=C /sbin/ip -6 addr list dev "$Iface" scope global permanent | + sed -n '/ inet6 /s/.*inet6 \([0-9a-fA-F:]*\).*/[\1]/p' | head -1 fi - maas-region local_config_set \ - --maas-url "http://${ipaddr}/MAAS" } -get_default_route_ip_or_localhost() { +get_default_route_ip4() { while read Iface Destination Gateway Flags RefCnt Use Metric Mask MTU Window IRTT do [ "$Mask" = "00000000" ] && break done < /proc/net/route - interface="$Iface" - if [ -z "$interface" ]; then - echo "localhost" - else - ipaddr=$(LC_ALL=C /sbin/ip -4 addr list dev "$interface" scope global) + if [ -n "$Iface" ]; then + ipaddr=$(LC_ALL=C /sbin/ip -4 addr list dev "$Iface" scope global) ipaddr=${ipaddr#* inet } ipaddr=${ipaddr%%/*} echo $ipaddr @@ -67,18 +80,25 @@ ######################################################### # Obtain IP address of default route and change DEFAULT_MAAS_URL - # if default-maas-url has not been preseeded. + # if default-maas-url has not been preseeded. Prefer ipv4 addresses if + # present, and use "localhost" only if there is no default route in either + # address family. db_get maas/default-maas-url ipaddr="$RET" - if [ -z "$RET" ]; then - ipaddr=$(get_default_route_ip_or_localhost) + if [ -z "$ipaddr" ]; then + ipaddr=$(get_default_route_ip4) fi - # Set the IP address of the interface with default route - if [ -n "$ipaddr" ]; then - configure_maas_default_url "$ipaddr" - db_subst maas/installation-note MAAS_URL "$ipaddr" - db_set maas/default-maas-url "$ipaddr" + if [ -z "$ipaddr" ]; then + ipaddr=$(get_default_route_ip6) + fi + # Fallback default is "localhost" + if [ -z "$ipaddr" ]; then + ipaddr=localhost fi + # Set the IP address of the interface with default route + configure_maas_default_url "$ipaddr" + db_subst maas/installation-note MAAS_URL "$ipaddr" + db_set maas/default-maas-url "$ipaddr" ######################################################### ################ Configure Database ################### diff -Nru maas-2.0.0+bzr5189/debian/rules maas-2.1.1+bzr5544/debian/rules --- maas-2.0.0+bzr5189/debian/rules 2016-08-18 11:27:31.000000000 +0000 +++ maas-2.1.1+bzr5544/debian/rules 2016-11-08 19:56:26.000000000 +0000 @@ -81,4 +81,4 @@ | sed -rne 's,^Version: ([^-]+).*,\1,p') get-orig-source: bzr export -r $(REV) --root=maas-$(VER).orig \ - maas_$(VER).orig.tar.gz lp:maas/2.0 + maas_$(VER).orig.tar.gz lp:maas diff -Nru maas-2.0.0+bzr5189/docs/bootsources.rst maas-2.1.1+bzr5544/docs/bootsources.rst --- maas-2.0.0+bzr5189/docs/bootsources.rst 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/bootsources.rst 2016-11-08 19:56:20.000000000 +0000 @@ -20,7 +20,7 @@ $ maas $PROFILE boot-sources read [ { - "url": "http://images.maas.io/ephemeral-v2/daily/", + "url": "http://images.maas.io/ephemeral-v3/daily/", "keyring_data": "", "resource_uri": "", "keyring_filename": "/usr/share/keyrings/ubuntu-cloudimage-keyring.gpg", diff -Nru maas-2.0.0+bzr5189/docs/changelog.rst maas-2.1.1+bzr5544/docs/changelog.rst --- maas-2.0.0+bzr5189/docs/changelog.rst 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/changelog.rst 2016-11-08 19:56:20.000000000 +0000 @@ -2,1456 +2,954 @@ Changelog ========= -2.0.0 +2.1.1 ===== -Important announcements ----------------------- +Bugs fixed in this release +-------------------------- -**MAAS 2.0 supported on Ubuntu 16.04 LTS (Xenial)** - MAAS version 2.0 is supported on Ubuntu 16.04 LTS. MAAS 2.0 and greater - will NOT be supported on Ubuntu 14.04 LTS. The latest MAAS 1.9 point release - will continue to be supported on Ubuntu 14.04 LTS (Trusty) until it reaches - end-of-life. - - Upgrades are supported for users running Ubuntu 14.04 systems running - MAAS 1.9 or earlier. Upon upgrading to Ubuntu 16.04, the MAAS - database and configuration will be seamlessly migrated to the supported - MAAS version. - - Please see the “Other Notable Changes” section below for more details - regarding the reasons for this change. - -**Terminology Changes** - Cluster controllers have been renamed to rack controllers. - - Starting from MAAS 2.0, MAAS cluster controllers have been deprecated, - along with the legacy ``nodegroups`` API. The new API endpoint is - ``rackcontrollers``, which provides feature parity with earlier versions - of MAAS. - - For more information on rack controllers, refer to the `Major new Features` - section bellow or refer to :ref:`rack-configuration`. - -**API 1.0 has been deprecated, introducing API 2.0** - Starting from MAAS 2.0, the MAAS REST API version 1.0 has been deprecated. - MAAS 2.0 drops support for the legacy 1.0 API, in favor of API version 2.0. - With the introduction of the new API version, various endpoints have now - been deprecated, and new end-points have been introduced. API users will - need to update their client tools to reflect the changes. - - For more information on API 2.0, refer to :ref:`API documentation `. - -**Static IP ranges have been deprecated** - Starting from MAAS 2.0, static IP ranges (previously found on the cluster - interface page) have been deprecated. MAAS now assumes total control of a - subnet. MAAS will automatically assign IP addresses to deployed machines, - as long as those IP addresses are not within a dynamic or a reserved - IP range. Users are now only required to specify one or more dynamic ranges - per subnet. Dynamic ranges are used for auto-enlistment, commissioning, and - any other systems configured for DHCP. IP addresses in-use for purposes such - as devices, default gateways, DNS servers, rack and region controllers, and - BMCs are automatically avoided when assigning IP addresses. Reserved IP - ranges may be added if MAAS should avoid certain ranges of IP addresses in - the subnet. - -**maas-region-controller-min has been renamed to maas-region-api** - The ``maas-region-controller-min`` package has been renamed to - ``maas-region-api``. This package provides API services for MAAS - (``maas-regiond``) and can be used to scale out the API front-end of - a MAAS region. - -**MAAS user creation been moved to 'maas' command** - Starting from MAAS 2.0, the ``maas`` command now provides the ability to - create admin users. The ``maas-region createadmin`` command has been - deprecated. New administrators should now be created with - ``maas createadmin``. - -**maas-provision command has been replaced** - The MAAS rack controller command-line interface (``maas-provision``) has - been replaced by the ``maas-rack`` command. - -**maas-region-admin command has been replaced with maas-region** - The MAAS region controller command-line interface (``maas-region-admin``) - has been replaced by the ``maas-region`` command. Note that this command - provides an interface to interact directly with Django, which should only be - used for debugging purposes. - -**Debian Installer is no longer installed or supported** - Because support for the Debian Installer (DI) has been dropped (as - of MAAS 1.9), MAAS no longer downloads DI-related files from simplestreams. - Upon upgrading to MAAS 2.0, DI-related files will be removed from the MAAS - region (and all rack controllers). +LP: #1554636 maas serving old image to nodes +LP: #1593991 [2.0b7, API/CLI] allows you to add machines with power_type and no power_parameters -Major new features ------------------- +LP: #1602482 [2.0rc2] Incorrect DNS records -**MAAS Rack Controllers and High Availability** - Starting from MAAS 2.0, MAAS **cluster controllers** have been renamed to - **rack controllers**. - - * The ``nodegroups`` and ``nodegroups/(group)/interfaces`` API endpoints - have been deprecated. In MAAS 2.0, the ``rackcontrollers`` interface - partially replaces this functionality. For defining dynamic and reserved - ranges, or specifying default gateways, use the ``subnets`` endpoint. For - enabling or disabling DHCP, use the ``fabrics/(fabric)/vlans`` endpoint. - - * The **Clusters** tab is no longer available in the Web UI. - Controllers are now found under the **Nodes** tab, where each region - and/or rack controller can be found. Other cluster interface properties - have been moved to the Subnet and VLAN details pages under the **Networks** - tab. - - * Machines no longer belong to a specific controller. - In earlier versions of MAAS, machines would directly assigned to a cluster - controller. The cluster controller that the machine belonged to would not - only perform DHCP for that machine, but also all the PXE booting and power - management. - - In order to support high availability for rack controllers, (starting from - MAAS 2.0) machines no longer belong to a specific rack controller. The best - controller to manage a machine is now determined at runtime. - - * DHCP is now configured per-VLAN. - In earlier versions of MAAS, DHCP was directly linked and configured - per cluster interface. As of MAAS 2.0, DHCP is now configured and managed - per-VLAN, which allows any rack controller to potentially provide DHCP in - a high-availability environment. - - * Rack controllers have been enabled for high availability. - Starting from MAAS 2.0, rack controllers in the same VLAN become - candidates to manage DHCP, PXE/TFTP, and power control for machines on - the VLAN. MAAS now supports the concept of a **primary** and a - **secondary** rack controller. If a secondary controller determines that - the primary controller is unavailable, it will assume control of those - services. - - * Added ``maas-rack support-dump`` command. - For increased support observability, users can now dump the contents of - several internal MAAS data structures by executing ``sudo maas-rack - support-dump``. This command will dump networking diagnostics, rack - configuration, and image information. Information can be restricted to a - particular category by using the ``--networking``, ``--config``, or - ``--images`` options. - - * Rack controllers can now be found under the **Nodes** tab in the Web UI. - MAAS 2.0 Adds a new **Controllers** section under thee **Nodes** tab. This - section will now list all rack and region controllers. Under a rack - controller, the user will be able to see service tracking, connected VLANs, - rack interfaces and other relevant information. - -**Region Controller Redundancy (High Availability)** - Starting from MAAS 2.0, MAAS provides the ability to scale out (provide - redundancy for) the MAAS region controller API, HTTP server, and DNS. This - will allow administrators to set up multiple MAAS region controllers - (``maas-region-api``) against a common database, providing redundancy of - services. With further manual configuration, users will be able to setup - the MAAS region controller in high availability mode. - -**New Networks Web UI** - MAAS 2.0 introduces a few new Web UI features that were not available in - previous versions of MAAS. - - * Added fabric and space details pages. - - * Added the ability to add and remove fabrics, spaces, subnets and VLANs. - This can be done using the actions menu on the **Networks** tab. - - The ability to delete fabrics, spaces, subnets and VLANs is also available - from the details page for each respective object. - -**DNS Management** - MAAS 2.0 extends DNS management by adding the following features: - - * Ability to create multiple DNS domains. - * Ability to add multiple records (``CNAME``, ``TXT``, ``MX``, ``SRV``) per - domain. (API only) - * Ability to select the domain for machines and devices. - * Ability to assign (additional) names to IP addresses. (API only) - * For deployed machines, ``A`` records continue to be created for - the IP of the PXE interface. - * Additional PTR records are now created for all non-PXE interfaces in - the form: ``.`` - * Reverse DNS is now generated for only the subnet specified, rather - than the parent /24 or /16. By default, `RFC2137`_ glue is provided - for networks smaller than /24. This can be disabled or changed - on a per-subnet basis via the API. - -.. _RFC2137: - https://tools.ietf.org/html/rfc2137 - -**IP Ranges** - Previous versions of MAAS used the concepts of a **dynamic range** and - **static range**, which were properties of each cluster interface. This - has been redesigned for MAAS 2.0 as follows: - - * Dynamic ranges have been migrated from earlier MAAS releases as-is. - - * Because static ranges have been removed from MAAS, each static - range has been migrated to one or more reserved ranges, which - represent the opposite of the previous static range. (MAAS now - assumes it has full control of each managed subnet, and is free - to assign IP addresses as it sees fit, unless told otherwise.) - - For example, if in an earlier MAAS release a cluster interface was - configured on 192.168.0.1/24, with a dynamic range of 192.168.0.2 - through 192.168.0.99, and a static range of 192.168.0.100 through - 192.168.0.199, this will be migrated to:: - - IP range #1 (dynamic): 192.168.0.2 - 192.168.0.99 - IP range #2 (reserved): 192.168.0.200 - 192.168.0.254 - - Since 192.168.0.100 - 192.168.0.199 (the previous static range) - is not accounted for, MAAS assumes it is free to allocate static - IP addresses from that range. - - * Scalability is now possible by means of adding a second dynamic - IP range to a VLAN. (To deal with IP address exhaustion, MAAS - supports multiple dynamic ranges on one or more subnets within - a DHCP-enabled VLAN.) - - * Reserved ranges can now be allocated to a particular MAAS user. - - * A comment field has been added, so that users can indicate why - a particular range of IP addresses is reserved. - - * IP ranges can be configured in the Web UI via the Subnet - details page, or using the ``subnets`` REST API endpoint. - -**API 2.0 and MAAS CLI Updates** - Version 1.0 of the MAAS REST API has been removed and replaced with the 2.0 - version of the REST API. As such, new endpoints and commands have been - introduced: - - * RackControllers - This endpoint/command has the following operations - in addition to the base operations provided by nodes: - - * ``import-boot-images`` - Import the boot images on all rack - controllers - * ``describe-power-types`` - Query all of the rack controllers for - power information - - * RackController - This endpoint/command has the following operations - in addition to the base operations provided by nodes - - * ``import-boot-images`` - Import boot images on the given rack - controller - * ``refresh`` - refresh the hardware information for the given rack - controller - - * Machines - This endpoint/command replaces many of the operations - previously found in the nodes endpoint/command. The machines - endpoint/command has the following operations in addition to the - base operations provided by nodes. - - * ``power-parameters`` - Retrieve power parameters for multiple - machines - * ``list-allocated`` - Fetch machines that were allocated to the - user/oauth token. - * ``allocate`` - Allocate an available machine for deployment. - * ``accept`` - Accept declared machine into MAAS. - * ``accept-all`` - Accept all declared machines into MAAS. - * ``create`` - Create a new machine. - * ``add-chassis`` - Add special hardware types. - * ``release`` - Release multiple machines. - - * Machine - This endpoint/command replaces many of the operations - previously found in the node endpoint/command. The machine - endpoint/command has the following operations in addition to the - base operations provided by node. - - * ``power-parameters`` - Obtain power parameters for the given machine. - * ``deploy`` - Deploy an operating system to a given machine. - * ``abort`` - Abort the machines current operation. - * ``get-curtin-config`` - Return the rendered curtin configuration for - the machine. - * ``power-off`` - Power off the given machine. - * ``set-storage-layout`` - Change the storage layout of the given - machine. - * ``power-on`` - Turn on the given machine. - * ``release`` - Release a given machine. - * ``clear-default-gateways`` - Clear any set default gateways on the - machine. - * ``update`` - Change machine configuration. - * ``query-power-state`` - Query the power state of a machine. - * ``commission`` - Begin commissioning process for a machine - - Other endpoints/commands have changed: - - * All list commands/operations have been converted to read - * All new and add commands/operations have been converted to create - * Nodes - The nodes endpoint/command is now a base endpoint/command - for all other node types(devices, machines, and rack-controllers). - As such most operations have been moved to the machines - endpoint/command.The following operations remain as they can be - used on all node types. - - * ``is-registered`` - Returns whether or not the given MAC address is - registered with this MAAS. - * ``set-zone`` - Assign multiple nodes to a physical zone at once. - * ``read`` - List nodes visible to the user, optionally filtered by - criteria. - - * Node - The node endpoint/command is now a base endpoint/command for - all other node types(devices, machines, and rack-controllers). As - such most operations have been moved to the machine endpoint/command. - The following operations remain as they can be used on all node types. - - * ``read`` - Read information about a specific node - * ``details`` - Obtain various system details. - * ``delete`` - Delete a specific node. - - * With the migration of nodes to machines the following items previously - outputted with the list command have been changed or removed from the - machines read command: - - * ``status - Will now show all status types - * ``substatus``, ``substatus_action``, ``substatus_message``, - ``substatus_name`` - Replaced by ``status``, ``status_action``, - ``status_message``, ``status_name``. - * ``boot_type - Removed, MAAS 2.0 only supports fastpath. - * ``pxe_mac`` - Replaced by ``boot_interface``. - * ``hostname`` - Now only displays the hostname (without the domain) of - the machine. ``fqdn`` and ``domain`` attributes can now be used instead. - - * And other endpoints/commands have been deprecated: - - * NodeGroups - Replacement operations are found in the - RackControllers, Machines, and BootResources endpoints/commands. - * NodeGroupInterfaces - replacement operations are found in the - RackController, IPRanges, Subnets, and VLANS endpoints/commands. - -**Extended Storage Support** - MAAS 2.0 Storage Model has been extended to support: - - * XFS as a filesystem. - * Mount options. - * Swap partitions. (MAAS 1.9 only supported the creation of a swap - file in the filesystem.) - * ``tmps``/``ramfs`` support. - - All of these options are currently available over the CLI. - -**DHCP Snippets** - MAAS 2.0 introduces the ability to define DHCP snippets. This - feature allows administrators to manage DHCP directly from MAAS, removing - the need to manually modify template files. The following types of DHCP - snippets can be defined: - - * **Host snippets** - used for configuration for a particular node in MAAS. - * **Subnet snippets** - used for configuration for a specific subnet in MAAS. - * **Global snippets** - used for configuration that will affect DHCP (isc-dhcp) - as a whole. +LP: #1620478 [2.1, UI] Broken validation on VLAN MTU - For more information, see :ref:`DHCP Snippets `. +LP: #1630636 [2.1 ipv6] YAML error when maas_url has an IPv6 IP -Minor new features ------------------- +LP: #1630679 [2.1b1] Can't use custom image repository -**MAAS proxy is now managed** - Starting from MAAS 2.0, MAAS now manages the configuration for - ``maas-proxy``. This allows MAAS to lock down the proxy so that it only - allows traffic from networks MAAS knows about. For more information, see - :ref:`MAAS Proxy `. - -**rsyslog during enlistment and commissioning** - MAAS 2.0 now enables ``rsyslog`` for the enlistment and commissioning - environment (when using Xenial as the commissioning image). This allows users - to see ``cloud-init``'s syslog information in ``/var/log/maas/rsyslog/``. - -**Ability to change a machine’s domain name from the UI** - MAAS 2.0 introduces the ability to change a machine’s DNS domain - via the Web UI. It was previously supported on the API only. - -**Networks listing page** - In the **Networks** tab, a new networks overview has been introduced, which - provides a high-level view of the MAAS networking mode. The network model - can be grouped by either fabrics or spaces. - -**Service Tracking** - MAAS now tracks the status of the services required for its operation, such - as ``bind``, ``maas-dhcpd``, ``maas-dhcpd6``, ``tgt``, and ``maas-proxy``. +LP: #1633717 [2.1] DHCP probe needs to be smarter about interface selection to avoid log spam +LP: #1636858 [2.1.1, trunk, bzr5510] Can't enlist machines -Other notable changes ---------------------- +LP: #1636861 [2.1.1, trunk, bzr5510] UI error when adding a chassis -**MAAS 2.0 requires Python 3.5** - Starting with MAAS 2.0, MAAS has now been ported to Python 3.5 (the default - version of Python in Ubuntu 16.04 "Xenial"). - -**MAAS 2.0 now fully supports native Django 1.8 migration system** - MAAS is now based on Django 1.8. Django 1.8 has dropped support for the - South migration system in favor of the native Django migration - system, which breaks backwards compatibility with previous versions of - Django. - - MAAS continues to support a full upgrade path. MAAS versions 1.5, 1.7, 1.8, - and 1.9 have been tested and confirmed to upgrade seamlessly to MAAS 2.0. - -**Instant DHCP lease notifications** - MAAS no longer scans the leases file every 5 minutes. ``isc-dhcp-server`` - now directly notifies MAAS if a lease is committed, released, or expires. - -**Host entries in DHCP** - Host entries are now rendered in the DHCP configuration instead - of placed in the leases file. This removes any state that previously - existed in the DHCP lease database on the cluster controller. - - Starting with MAAS 2.0, if the dhcpd.leases file is lost (such as during a - failure scenario in a high availability environment), MAAS will be able to - reconstruct it. - -**Power control is no longer specific to a rack controller** - MAAS selects one of the available rack controllers to power control - or query a BMC. The same rack controller that powers the BMC does - not need to be the rack controller that the machine PXE boots from. +LP: #1636992 [2.1] Deleting all boot sources and creating a new boot source, does not update the cache +LP: #1598175 [2.0] If the machine is deployed, I cannot update NIC's nor storage -2.0.0 (rc4) -=========== +LP: #1603563 [2.0 RC2] Multiple failures to release nodes -Issues fixed in this release ----------------------------- - -LP: #1592666 Mirror URL contains double slash (/) after hostname, impacting proxy cachaility. - -LP: #1604461 [2.0rc2] Static IP address are allowed to be created in a dynamic range. - -LP: #1610397 When juju adds containers to MAAS, ensure they inherit the parent machine domain name, if none is passed by Juju. +LP: #1606508 [2.1] Failover peers must be IPv4 for use with ISC dhcpd -LP: #1611342 UI error while generating a MAAS key (token). +LP: #1632853 [2.1] Observed neighbours should be avoided when assigning IP addresses -LP: #1610414 apiclient.maas_client.MAASClient.post() always sets an op in the query string +LP: #1633401 [2.1] In device discovery in Settings, remove the header of the first dropdown field (Host discovery and network observation) +LP: #1633452 [2.1] In settings, rename the option Disabled (suppress active scanning) in the Active discovery interval field to Never (disabled). -2.0.0 (rc3) -=========== - -Issues fixed in this release ----------------------------- +LP: #1633462 [2.1] In settings in the device discovery section reduce the text of the explanation of the fields. -LP: #1557434 For the MAAS CLI, mimic the error behaviour provided by argparse 1.1 on PyPI when insufficient arguments are given. - -LP: #1594991 MAAS displays every power query on the summarized view of node event log. - -LP: #1603147 Commissioning dropdown is grey and checkmarks are missing. - -LP: #1576116 [2.0rc1] MAAS does not respect default subnet's DNS server when choosing default DNS - -LP: #1600720 [2.0rc1] MAAS doesn't honor DNS settings for a subnet for DHCP - -LP: #1598028 [2.0] Loading latest machine events can make web browser unresponsive - -LP: #1604128 [2.0rc2] Unable to add a public SSH Key due to lp1604147 - -LP: #1604169 [2.0] maas login yields "ImportError: No module named 'maasserver'" - -LP: #1604962 Fixes to correctly log cloud-init/curtin FAIL events in the node event log. - -LP: #1604987 Fixes to correctly log "mark_failed" events. - -LP: #1602721 [2.0rc2] Can't get node-results via cli/api - -LP: #1604465 [2.0] RackController.get_image_sync_status causes huge load on regiond process - -LP: #1598149 [2.0rc2] MAAS is not automatically monitoring timeouts for commissioning. - -LP: #1605252 [2.0] Error messaging about monitor expiry has been dropped - - -2.0.0 (rc2) -=========== - -Issues fixed in this release ----------------------------- - -LP: #1582070 Pick up wrong grub.cfg if another filesystem exists - -LP: #1599223 [2.0] confusing reverse DNS lookups because MAAS creates multiple PTR records - -LP: #1600259 [2.0] reverse DNS sometimes assigns FQDN where it should assign IFACE.FQDN - -LP: #1599997 [2.0rc1] after upgrade from 2.0b3, Error on request (13) subnet.list: 'NoneType' object is not iterable - -LP: #1598461 [2.0rc1] Image import dates are inconsistent - -LP: #1598937 [2.0rc1] Following fresh install maas command fails - PermissionError: [Errno 13] Permission denied: '/home/ubuntu/.maascli.db' - -LP: #1597787 [1.9.3,2.0] cannot create more than 4 partitions when disk is configured with mbr - -LP: #1600267 [1.9,2.0,UX] Can't add aliases when parent interface is set to 'DCHP' - -LP: #1600198 [1.9,2.0,UX] Creating a Bcache disk is not prevented when is not created in partition - - -2.0.0 (rc1) -=========== - -Issues fixed in this release ----------------------------- - -LP: #1576357 Determine a method for how to reconnect a deleted rack controller - -LP: #1592246 [2.0b7, regression] maas-rack register makes up a new hostname - -LP: #1595753 [beta8] HMC power driver regression -- Not able to connect via SSH. - -LP: #1592885 [2.0b7] Date and time format should be consistent accross logs - -LP: #1597324 [2.0b8] Unable to set default gateway interface - -LP: #1515188 [1.9] VMware power management fails when VMs are organized in nested subfolders - -LP: #1596046 [2.0] maas 2.0 pxeboot fails on PowerNV - -LP: #1600267 [1.9,2.0,UX] Can't add aliases when parent interface is set to 'DCHP' - -LP: #1598937 [2.0 rc1] Following fresh install maas command fails - PermissionError: [Errno 13] Permission denied: '/home/ubuntu/.maascli.db' - -2.0.0 (beta8) -============= - -Issues fixed in this release ----------------------------- +LP: #1633822 [2.1] Device discovery ignores reverse DNS -LP: #1590081 Allow ed25519 and ecdsa ssh keys +LP: #1636250 [2.1] machines allocate API returns a random machine if incorrect - parameters are used -LP: #1462078 [2.0b2, UI] Can't add a device and it does not show why +LP: #1636873 [2.1.0] Creating a bond doesn't work and no feedback is provided if fabric in interfaces is 'disconnected' -LP: #1573626 [2.0b3] Interfaces on region controllers are not discovered +LP: #1636874 [2.1, Yakkety] Plus '+' button is not visible when you hover over an interface in machine details -LP: #1562107 [2.0b4, UI] No feedback when failing to assign static IP address on the Node Details Page +LP: #1637009 [2.0,2.1] Node acquisition constraints API documentation needs to be updated to match reality -LP: #1583670 [2.0b5] No way to read settings, like proxy, for non-admin users +LP: #1637182 Help and documentation 'list of unicodes' inconsistent -LP: #1585016 [2.0b5] Commissing with LVM breaks deployments +LP: #1637192 [2.0,2.1] Allocate using subnets or not_subnets with space fails -LP: #1581729 [2.0b5] dns templates still in /etc/maas/templates +LP: #1637246 MaaS should use configured names for VLAN interfaces -LP: #1588907 [2.0b6] django.db.utils.IntegrityError: insert or update on table "piston3_consumer" violates foreign key constraint LP: "piston3_consumer_user_id_4ac0863fa7e05162_fk_auth_user_id +LP: #1638284 [2.1.1pre] Debug logging shown by default in regiond.conf -LP: #1581130 [2.0b6] Image status stays out-of-sync after adding custom image +LP: #1638288 [2.1.1 pre] A lot of repeated logging -LP: #1590144 [2.0b6] core count not updated during commissioning if MAAS previously stored a higher core count +LP: #1638589 [2.1] commissioning doesn't find the second address family on the boot interface -LP: #1592282 [2.0b7] Adding rack controller instructions could be in the GUI +LP: #1600328 [2.0rc1, API/CLI] When adding a new machine and no rack controller can connect to the BMC, no error message is displayed. -LP: #1592132 [2.0b7] Enlisting output returns objects +LP: #1633378 [Device Discovery] Rename the section Header in the Settings page -LP: #1592137 [2.0b7, UI] Can't sort IP addresses under a subnet details page +LP: #1633600 [2.1.1] Docs do not mention the need to mirror bootloaders -LP: #1593789 [2.0b7] Nodes API doesn't show regions +LP: #1636251 resolv.conf search path doesn't match the domain for the host -2.0.0 (beta7) -============= - -Issues fixed in this release ----------------------------- - -LP: #1587896 get_interfaces_definition is not thread-safe - -LP: #1590946 Auto detection of running virtual environment during commissioning almost always fails - -LP: #1591093 [2.0,1.9] 3rd party HP drivers (archive hostname renamed) - deployment fails - -LP: #1590021 [2.0] Cannot create an IP reservation with a hostname - -LP: #1591346 [2.0] maas createadmin fails - -LP: #1577953 [2.0b4] Rack Controller fail to update commissioning info? - -LP: #1579215 [2.0b4] Can attempt to commission enlisted nodes without chosen power type - -LP: #1581219 [2.0b4 UI] MAAS WebUI doesn't quickly refresh when deleting machines - -LP: #1581723 [2.0b5] request to http://192.168.10.27:5240/MAAS/metadata/status/43he8/latest failed - -LP: #1587896 [2.0b5] p.refresh.get_swap_size misconverting units - -LP: #1590499 [2.9b6] Can edit fabric and subnet on deployed node - -LP: #1591395 [2.0b6] some arm64 systems need ipmi_ssif module in addition to ipmi_si - -LP: #1589587 [2.0b6] Attempting to delete a VLAN that cannot be deleted, shows traceback in regiond.log - -LP: #1591958 [2.0b6] Commisioning fails on machines without HW virtualization - -LP: #1590991 [2.0b6] Cannot allocate a node based on its system_id - -LP: #1589562 [2.0b6, UI] When I delete a fabric, it takes me back to the Node listing page - -LP: #1589596 [2.0b6, UI] When I delete a space, it takes me back to the Node listing page - -LP: #1588298 [2.0b5, UI] No form validation when adding a subnet, space, fabric or vlan - -LP: #1589606 [2.0b6, UI] Message "No IP ranges have been reserved for this subnet." doesn't go away after adding IP Range - -LP: #1589583 [2.0b6, UI] Can't add a VLAN over the WebUI - -LP: #1589560 [2.6b6, UI] Adding a fabric with an optional name ends up with a new fabric with automatically assigned name - -LP: #1589595 [2.6b6, UI] Adding a space with an optional name ends up with a new space with automatically assigned name - - -2.0.0 (beta6) -============= - -Issues fixed in this release ----------------------------- - -LP: #1572646 Spurious failures in test_regionservice - -LP: #1582836 use http for stream mirror, not https - -LP: #1583715 MAAS version API call should not require authentication - -LP: #1572740 Detect and identify NIC SR-IOV capability - -LP: #1584211 [1.9,2.0]Commissioning fails when BIOS reports floppy drive, but there is none installed - -LP: #1584850 [1.9,2.0] DNS record created against IPv6 address when it is not on the PXE interface - -LP: #1586555 [2.0] MaaS 2.0 BMC information not removed when nodes are removed - -LP: #1508741 [2.0] IPMI driver does not handle timeouts correctly - -LP: #1585759 [2.0] Display RAM amount to the first decimal place in the UI - -LP: #1585760 [2.0] Expose the refresh rack controller action over the UI - -LP: #1585768 [2.0] Rename maas-nodegrou-worker to MAAS - -LP: #1553841 [2.0a1] MAAS should ensure that BMC password is correct before saving - -LP: #1571645 [2.0b2] DNS zone serials are not stable - -LP: #1570985 [2.0b2] If you deploy a machine in MAAS, and manually install a rack controller in it, it disappears from the machine list" - -LP: #1576417 [2.0b3] rack / region controllers are visible to non-admins - -LP: #1577972 [2.0b4] external maas-rack-controller logs to syslog instead of maas.log - -LP: #1580817 [2.0b4] twisted.internet.error.ConnectionDone: Connection was closed cleanly. - -LP: #1581318 [2.0b4 UI/API] No notifications rack controller is disconnected. No power type available - -LP: #1580350 [2.0b5] AMT machines using wsman do not netboot - -LP: #1581737 [2.0b5] When installing secondary region controller on its on, last image sync is never - -LP: #1583685 [2.0b5] Can't force the import of images per Rack Controller - -LP: #1585649 [2.0b5] After changing proxy, MAAS cannot install images - -LP: #1584936 [2.0b5] MAAS doesn't import default images automatically - -LP: #1558635 [2.0b5] Trying to assign an IP address statically to a device results in builtins.AttributeError: 'NoneType' object has no attribute 'link_subnet' (vid, fabric_id)=(2, 0) already exists. - -LP: #1583333 [2.0b5] duplicate key on startup: Key - -LP: #1588531 [2.0b5] Deployed regions should be able to transistion back to machines +2.1.0 +===== -LP: #1581224 [2.0b5] domain details page does not update as the domain contents change +Important announcements +----------------------- -LP: #1583392 [2.0b5] Cannot disable DHCP if you remove the subnet first ("Cannot configure DHCP: At least one dynamic range is required.") +**New MAAS dashboard, now including discovered devices!** + In MAAS 2.1, administrators will be redirected to the new MAAS dashboard + after they log in to the Web UI. On the dashboard, administrators are guided + through where to go to quickly get MAAS up and running. In addition, + administrators can view hosts that have been discovered on the network, and + quickly convert them to a device in MAAS. + +**Image streams have been upgraded to v3. (Important: update your mirrors!)** + In order to support the new kernels, MAAS has moved to a new format for image + streams. Previous releases used stream in “v2” format. Starting from MAAS 2.1, + the “v3” format image stream will be used. + + Users upgrading from earlier versions of MAAS who are using the default images + URL will be automatically migrated to the new “v3” URL. + + For users with custom mirrors, MAAS will not migrate the image URL + automatically. Users must ensure their image mirrors contain the “v3” stream, + which is available at http://images.maas.io/ephemeral-v3/. Old images + downloaded from the “v2” stream will continue to work until the mirror is + updated, but the MAAS team only supports MAAS 2.1 users using the “v3” stream. + Please note that bootloaders are now included in the mirror; be sure to mirror + them in addition to the images. + +**New hardware enablement kernel naming convention** + Starting from MAAS 2.1 and Ubuntu 16.04 "Xenial", MAAS is adhering to a new + naming convention for hardware enablement kernels. On Xenial and above, MAAS + will not support HWE kernels with the old naming convention, but it will + support HWE kernel channel. For example, given Ubuntu 16.04 "Xenial" and + Yakkety, currently available kernels in MAAS are: + + * ga- + The GA, or general availability kernel is the kernel which the Ubuntu + release shipped with. For example ‘ga-16.04’ is the default 4.4 kernel + which shipped on Ubuntu 16.04 "Xenial". The ga kernel contains all bug and + security fixes provided by the Ubuntu archives. Deployments which use the + ga kernel will stay at the same kernel version through upgrades until the + entire release is upgraded with ‘do-release-upgrade.’ + + * hwe- + The latest Hardware Enablement Kernel currently available in a given + Ubuntu release. As new Hardware Enable Kernels are released with new Ubuntu + releases the hwe- kernel will be upgraded up until the next LTS. + For example hwe-16.04 is currently the 16.04 GA kernel. Once 16.10 is + released the hwe-16.04 kernel will be upgraded to the 16.10 GA kernel. The + kernel will continue to be upgraded up until and including the 18.04 GA + kernel. + +**Commissioning-user-data and pxe/uefi templates no longer available** + In the past, MAAS stored commissioning-user-data and pxe/uefi templates in + /etc/maas/templates. As of MAAS 2.1, these templates are no longer available + under /etc/maas. -LP: #1588846 [2.0b5] builtins.ValueError: invalid literal for int() with base 10 +Major new features +------------------ -LP: #1585628 [2.0, UI] Bulk actions-Nodes action doesn’t apply should be red +**First user configuration journey (UI)** + MAAS now provides the ability for administrators to perform some initial + configuration immediately after they log-in into the MAAS UI for the first + time. The configuration includes: + + * Ability to change the name of your MAAS + * Ability to configure options that affect connectivity: + * Option to select an Upstream DNS Server (Optional) + * Option to input different Ubuntu Mirrors (Required) + * Option to input an external proxy (Optional) + * Ability to select additional images to download + * Ability to import SSH keys from Launchpad or Github + +**Device discovery** + MAAS will now automatically listen to the network and report any discovered + devices. Devices are identified when the MAAS rack observes them + communicating on an attached IPv4 subnet. Discovered devices that do not + correspond to machines and devices already known to MAAS are shown on the + dashboard. If a device advertises a hostname using mDNS (such as with avahi + or Bonjour), MAAS will also present the discovered hostname in the dashboard. + Using the dashboard, a discovery can quickly be added to MAAS as a device or + as a network interface to a machine or device. + +**Active subnet mapping** + The device discovery feature was designed to operate passively by default. + While MAAS will not send any traffic on attached networks for discovery + purposes unless instructed to, there are two ways to instruct MAAS to map + your networks: + + * On-demand: administrators can choose to map their subnet using an action + on the subnet details page. This action will scan the subnet just once, so + that observed devices on that subnet may quickly be seen in the dashboard. + This feature is useful after initially installing MAAS, to quickly populate + the list of discoveries with active devices on the network. + + * Periodically (recommended): by enabling active discovery on a per-subnet + basis, subnets will be scanned at a user-specified interval. (default is + every three hours) This allows MAAS to maintain current information about + which IP addresses are in use on each subnet. + + Before actively mapping any networks, it is recommended that the ‘nmap’ + package be installed on each MAAS rack controller. Doing so results in faster + scans that require less network traffic. (If ‘nmap’ is not installed, MAAS + will resort to scanning using the ‘ping’ utility.) + +**Offline deployment and customizable APT repositories** + MAAS 2.1 improves its offline deployment capabilities by adding support for + Ubuntu derived repositories, PPAs, and custom APT repositories. This enables + MAAS to configure deployed machines with the correct APT repositories and + keyrings, without being dependent on Internet connectivity. + + * Ubuntu Derived Repositories (from an Ubuntu Mirror) + MAAS 2.0 and earlier versions only allowed users to change the Ubuntu + archive to use. This was limited to defining the location of an official + Ubuntu mirror. + + Derived repositories are based on an Ubuntu mirror, but have had packages + added or removed, which requires signing the repository with an unofficial + GPG key. MAAS now allow users to provide GPG key fingerprints to support + this type of repository. These fingerprints are required in order for + the derived repository to be trusted, and will be added to the APT keyring + on each machine. + + * PPAs + PPAs can now be specified, which will be added to the APT sources on + deployed machines. Users may define a GPG key fingerprint in order for + the machine to trust the PPA, for cases where the deployed machine cannot + access the Ubuntu key server. + + * Custom repositories + Custom repositories can be specified to add additional packages to deployed + machines. For custom repositories, the distribution and component can be + customized as appropriate. For example, users would be able to add the + Google Chrome repository, which is as follows: + + deb http://dl.google.com/linux/chrome/deb/ stable main + + In this case, the distribution is “stable”, and the component is “main”. + (Multiple components may also be specified.) + +**MAAS time sync, NTP services and configuration** + MAAS now provides managed NTP services (with ntpd) for all region and rack + controllers. This allows MAAS to both keep its own controllers synchronized, + and keep deployed machines synchronized well. + + * Region controllers synchronize time externally + The MAAS region controller configures the NTP service (ntpd) to keep its + time synchronized from one or more external sources. By default, the MAAS + region controller uses ntp.ubuntu.com. This can be customized on the + settings page. + + * Rack controllers synchronize time from the region controller + The rack controllers also configure the NTP service (ntpd). Unlike the + region controllers, rack controllers synchronize their time from region + controllers, rather than accessing an external time source. + + Rack controllers also configure DHCP with the correct NTP information, so + that any machine on the network that obtains a DHCP lease from MAAS will + benefit from the enhanced NTP support. + + * Controllers and Machines can synchronize time for external time sources only. + MAAS 2.1 also provides the ability to directly use external time sources + without using the Rack Controller as a source of time for machines. This + means that administrators who already have their own NTP infrastructure, + and they don’t want MAAS to provide NTP services, they can tell all + machines and controllers to sync their time from the external time source. + This can be done by selecting the "External Only" option on the Settings + page. + +**Advanced networking: static routes** + MAAS 2.1 introduces the ability to define static routes. This allows + administrators to configure reachability to a subnet from a source subnet. + Administrators can define routes on a per-subnet basis to use a particular + gateway, using a configured destination and metric. + +**Machine networking: bridge configuration** + MAAS now supports the creation of bridge interfaces. This support is limited + to the ability to create a bridge against a single interface, such as for the + purpose of eventually deploying virtual machines or containers on the machine. + + Automatic bridge creation on all configured interfaces can also be performed + at allocation time using the API. + +**Rescue mode** + MAAS 2.1 supports a new state in the machine lifecycle: rescue mode. Rescue + mode allows users to boot a Deployed or a Broken using an ephemeral image. + (That is, Ubuntu is running in memory on the machine.) This allows + administrators to SSH to the machine for maintenance purposes, similar to + running Ubuntu from a USB stick. + +**Enhanced images user interface** + The MAAS images page has been completely redesigned. Improvements include: + + * Supports selecting the image source (maas.io or custom repository). + * Now shows the image releases and architectures available in a repository before the import starts. + * Now displays detailed status throughout the image import process. + * The Boot Images section in the settings page has been removed. -LP: #1587936 [2.0, UI] Add fabric, VLAN, Space show's badly place form +Minor new features +------------------ -LP: #1587939 [2.0, UI] 'Commission' a node under the Node Listing Page shows actions not correctly formatted. +**Disk erasing improvements and secure erase** + In 1.7 (and later) MAAS introduced the ability to erase disks on machine + release. This support was limited to erasing the whole disk and could only + be enabled (or disabled) globally. + + Starting from MAAS 2.1, it now supports the ability to request disk erasure + on a per-machine basis, at the time the machine is released. In addition, new + options for the disk erase mode have been added: + + * Secure erase - If this option is enabled, MAAS will attempt to erase via + secure erase (if the storage device support it), otherwise, it will perform + a full erase or a quick erase (depending on the options provided). + + * Quick erase - If this option is enabled, MAAS will only erase the beginning + and the end of each storage device. + +**Machine networking: - SR-IOV auto-tagging, tags UI** + MAAS now allows the definition of tags per network interface via the WebUI. + Additionally, MAAS also attempts to auto-detect and tag SR-IOV NIC cards. + +**Support for low latency kernels** + Starting from Ubuntu 16.04 “Xenial” and later, “low latency” kernels available + on i386 and amd64 for both GA and HWE kernels. The currently available + lowlatency kernels are: + + * hwe-x-lowlatency - For using the Xenial Lowlatency kernel on Trusty + * ga-16.04-lowlatency - For using the GA lowlatency kernel on Xenial + * hwe-16.04-lowlatency - For using the HWE lowlatency kernel on Xenial. + +**Bootloaders are now provided in the image stream** + Previously, bootloaders where downloaded on the rack controller from the + Ubuntu archives for each architecture MAAS had images for. Starting from MAAS + 2.1, bootloaders are downloaded with the images. All rack controllers retrieve + all supported bootloaders from the region controller. MAAS no longer directly + interacts with the Ubuntu archives. + + In the case that bootloaders are missing from the stream, MAAS will attempt + to locate previous downloads of the bootloader as well as package installs of + the bootloader. Users with image mirrors must ensure image their mirrors + include the bootloaders in order to be running the latest supported versions. + +**SSH keys can be imported from Launchpad or GitHub** + All users will now have the ability to import their SSH public keys from the + UI. Users who log-in to MAAS for the first time will be prompted to import + their SSH keys, if desired. Alternatively, users can import keys later on + their user profile page, or continue to upload keys manually. -LP: #1587998 [2.0, UI] Add domain show's badly place form +Other notable changes +--------------------- -LP: #1588000 [2.0, UI] There's no spacing between combo boxes under the Machine Details page +**Better error surfacing for DHCP snippets and package repositories** + Both the DHCP Snippets section and the Package Repositories section have been + improved in order to show errors in a more user-friendly way. +**Vanilla framework: HTML and CSS updates, smoother look and feel** + The HTML templates and CSS frameworks in MAAS have been completely rebuilt + with the Vanilla CSS framework. Icons and interactions in MAAS have greatly + improved; users will notice smoother, more intuitive interactions with the UI. -2.0.0 (beta5) -============= + The MAAS team would like to thank the Canonical design and web teams for their + contributions in this area. Issues fixed in this release ---------------------------- -LP: #1572076 [UI 2.0b1] Impossible to change subnet CIDR or gateway with instant editing - -LP: #1568102 [UI 2.0b1] Network details page doesn't have CSS for editting - -LP: #1571670 [UI 2.0b2] Can't edit fabric's, vlans, subnets from the WebUI - -LP: #1571672 [UI 2.0b2] Can't add/edit/delete IP ranges through UI - -LP: #1570990 [UI/Backend 2.0b2] Can't delete a rack controller from the Rack Details Page - -LP: #1576267 [UI 2.0b3] interface addresses on rack controller details page not updated automatically - -LP: #1577386 [UI 2.0b4] Actions list is unordered - -LP: #1580827 [UI 2.0b4] I can 'add special filesystem' when the machine is deployed - -LP: #1521618 [1.9] wrong subnet in DHCP answer when multiple networks are present - -LP: #1536346 [2.0] include maas resetMachine() API primitive - -LP: #1575567 [2.0] Re-commissioning doesn't detect storage changes - -LP: #1570002 [2.0] Expose custom network in non ubuntu deployments - -LP: #1580260 [2.0a4] Reserved IP ranges should be allowed to be created by standard users - -LP: #1542353 [2.0b2] 6 Core system is listed as having a single CPU +A full list of issues fixed in this release is available in the Launchpad 2.1.0 +Milestone page -LP: #1570995 [2.0b2] Cannot delete a rack controller that was previously a 'machine' + https://launchpad.net/maas/+milestone/2.1.0 -LP: #1576758 [2.0b3] IP Ranges section on the subnet page should be shown even if no ranges -LP: #1372544 [2.0b3] Tag changes depend on rack / cluster connection - -LP: #1577953 [2.0b4] Rack Controller fail to update commissioning info? - -LP: #1577954 [2.0b4] Rack Controller mark-broken / mark-fixed - -LP: #1577970 [2.0b4] Registering external rack controller tracebacks - -LP: #1578800 [2.0b4] RackControllerService flooding log with: 'RegionAdvertisingService' object has no attribute 'processId' - -LP: #1580405 [2.0b4] set_initial_networking_configuration shouldn't raise ValidationError - -LP: #1580280 [2.0b4] Disks less than 4MB in size cause a traceback on the MAAS server - -LP: #1577974 [2.0b4] Rack Controller details page shows "never" under last image sync - -LP: #1580285 [2.0b4] Machines successfully commission but don't get marked 'Ready' - -LP: #1581654 [2.0b4] Region RPC losing connection and raising exception - -LP: #1580771 [2.0b4] unregisterConnection() missing 1 required positional argument: 'host' - - -2.0.0 (beta4) -============= +2.1.0 (RC1) +=========== Issues fixed in this release ---------------------------- -LP: #1527634 [2.0] Disk erasing with Xenial results it abnormal poweroff +LP: #1569365 TestPartition.test_get_partition_number_returns_starting_at_2_for_ppc64el fails spuriously -LP: #1555864 [2.0a1] UI Nodes page shows 'ascii' codec can't decode byte +LP: #1598470 "Deployed" and "Deploying" are too similar -LP: #1574003 [2.0a4] When power_type changed to manual "power_state" was not set to "unknown" +LP: #1536354 Users' maas api keys do not have a name -LP: #1571007 [2.0b2] MAAS Rack Controller doesn't log when it is importing images. +LP: #1631358 [2.1] Incorrect logging message - showing SERVICE_STATE.ON -LP: #1575945 [2.0b3] rackd fails to register vlan interfaces with "vlan" naming scheme +LP: #1631420 [2.1 UI] Images page "Queued for download" is confusing when selections are not saved -LP: #1573492 [2.0b3] Traceback deleting fabric +LP: #1631024 [2.1b1] Dashboard column widths for discovered items are wonky -LP: #1566108 [2.0b3] adding files with paths in the filename confuses maas +LP: #1631022 [2.1b1] 'Registering existing rack controller' -LP: #1571621 [2.0b3] MAAS does not add node to DNS Domain +LP: #1629604 [2.1] Command 'interface link-subnet' does not work -LP: #1573644 [2.0b3] tag only supports 'nodes' and and not 'machines' or 'controller's +LP: #1628114 [FUJ] SSH input field not indicated for invalid username & the error is incomprehensible -LP: #1573264 [2.0b3] enlistment fails: /tmp/sh.UZ7qJT/bin/maas-enlist: archdetect: not found +LP: #1629475 [2.1 ipv6] DHCP generation should not fail when address-family conflicts are present -LP: #1562919 [2.0b3] creating a dnsresource-record at the root of a zone should allow fqdn= +LP: #1603466 [2.0rc2] Commissioning node with gateway_link_v4 set fails. -LP: #1573690 [2.0b3] In the domain details pages, sometimes names have links to nodes when they should not +LP: #1608555 [2.1, 2.0 UI] Error when using dhcp range with pre-existing dynamic reservation -LP: #1576854 [2.0b3] Can't power on/off Rack Controller +LP: #1632815 [2.1b2] Node failed to be released, because of the following error: 'NoneType' object has no attribute 'addErrback' -LP: #1573660 [2.0b4] ipranges create raises incorrect error for missing type +LP: #1632395 [2.1, Yakkety, UI] UI error when adding a chassis -LP: #1557597 [UI 2.0] fabric and space pages fail to update automatically +LP: #1631079 [2.0, 2.1 UI] Other reserved IP ranges disappear when one of them is deleted on Subnet details page. -LP: #1567150 [UI 2.0b1] Subnet page doesn't show which machine or device owns an IP address +LP: #1630667 [2.1b1] MAAS fails to deploy systems with 3+ TB disks -LP: #1571680 [UI 2.0b2] MAAS Controller listing page doesn't indicate whne a rack is downloading images +LP: #1630633 [2.1 Yakkety UI] Unable to select nodes -LP: #1573219 [1.9.1] Deleting user in UI leads to 500 +LP: #1629061 [2.0, 2.1] Release and list IPs reserved by another user -LP: #1556219 [1.9.1] maas enlistment of power8 found ipmi 1.5 should do ipmi 2.0 +LP: #1605476 [2.0rc2] Changing DNSSEC validation does not trigger configuration file update -2.0.0 (beta3) +2.1.0 (beta2) ============= Issues fixed in this release ---------------------------- -LP: #1573219 Deleting user in UI leads to 500 - -LP: #1553665 Unconfigured interfaces shouldn't add DNS records - -LP: #1571563 Can't override built in partitioning +LP: #1630394 [2.1] Bootloaders not downloaded on initial import -LP: #1566109 adding a device with no mac address gives an internal server error +LP: #1611949 cryptic error when PXE-boot requires an image not yet imported -LP: #1564927 [2.0] Can't start OMAPI protocol: address not available +LP: #1625676 [2.0, 2.1, UI] MAAS webui allows boot disk to be changed on an already deployed node -LP: #1570606 [2.0] subnet.list: list index out of range error when using a /31 subnet +LP: #1630591 Rename "Networks" tab to "Subnets" -LP: #1570600 [2.0b2] Trying to enabled dhcp on fabric-1 with IPv4 networks, results in maas-dhcpd6 attempted to be enabled +LP: #1628761 [2.1] netaddr assumes MAC OUI is ascii -LP: #1570609 [2.0b2] builtins.TypeError: cannot use a bytes pattern on a string-like object +LP: #1619262 [2.1, 2.0] Can't input dynamic range on "Enable DHCP" after I deleted the dynamic range -LP: #1571851 [2.0b2] interface_set returns an interface without 'links' even if empty +LP: #1630636 [2.1 ipv6] YAML error when maas_url has an IPv6 IP -LP: #1570626 [2.0b2] NameError: name 'LargeFile' is not defined +LP: #1612203 Machine unable to pxe with no-such-image while non-related images are being imported -LP: #1572070 [2.0b2] Cannot link physical device interfaces to tagged vlans, breaking juju 2.0 multi-NIC containers +LP: #1628645 External DHCP detection is broken for a variety of reasons -LP: #1569483 [2.0b2] Can't deploy CentOS +LP: #1627362 [2.1] expected string or bytes-like object -LP: #1571622 [2.0b2] Bad VLAN Validation on UI Node Details page +LP: #1614659 [2.1] When trying to release a node, it gets stuck in releasing if there is no rack controller to power control -LP: #1555715 [UI 2.0a1] changing a subnet's space does not cause a refresh in networks/spaces tab in the UI +LP: #1445941 WebUI needs a filter for deployed OS -LP: #1570152 [UI 2.0b1] Can't delete subnet in the UI, no action for it. -LP: #1571002 [UI 2.0b2] When reconfiguring DHCP, I can't unselect Secondary Rack Controller - - -2.0.0 (beta2) +2.1.0 (beta1) ============= -Issues fixed in this release ----------------------------- - -LP: #1563409 [2.0a4] 2.0 api is confused about its hash - -LP: #1555251 [2.0] Missing region-controller API - -LP: #1569102 API 2.0 deploy makes machine lose power information - -LP: #1564657 [2.0a4] Bridges no longer discovered by the rack controller - -LP: #1557144 [2.0a1] When Xenial is the only one image imported, nodes fail to boot after saving the commissioning image - -LP: #1556185 TypeError: 'Machine' object is not iterable - -LP: #1562198 [2.0a4] When providng DHCP a smarter default dynamic range is needed - -LP: #1568051 ThreadPool context entry failure causes thread pool to break - -LP: #1567178 [2.0 beta 1] After CD install, maas-region RPC endpoints is not available - -LP: #1566419 Rack controllers should output whether boot resources are synced - -LP: #1566920 Cannot change power settings for machine - -LP: #1568041 "[2.0beta1] macaddress_set should be removed from the machines and devices API" - -LP: #1568045 [2.0beta1] constraint_map should be removed from the machines acquire output - -LP: #1567213 Devices results missing interface_set - -LP: #1568847 "[2.0 beta1 ] Service 'maas-proxy' failed to start - -LP: #1543195 Unable to set mtu on default VLAN - -LP: #1566336 MAAS keeps IPs assigned to eth0, even after eth0 is enslaved into a bond - -LP: #1546274 Importing custom boot images is broken in MAAS 1.10. - -LP: #1566503 "Failed talking to node's BMC: cannot use a string pattern on a bytes-like object" - -LP: #1543968 MAAS 1.9+ allows non-unique space names and shows no space id in a subnet - -LP: #1543707 MAAS 1.9+ should not allow whitespace characters in space names - -LP: #1560495 [UI 2.0a3] Bad table spacing between columns - -LP: #1561733 [2.0a3] MAAS no longer detects external DHCP servers - -LP: #1566848 [2.0 beta1] Xenial is not the default image - -LP: #1563701 [2.0] VLAN interfaces of secondary rack-controller are not reported - -LP: #1561991 [2.0a4] Doesn't use modify over the OMAPI - -LP: #1566829 DoesNotExist: RegionControllerProcess matching query does not exist. - -LP: #1561954 Ubuntu Server install menu needs a 16.04 refresh - -LP: #1564971 [2.0a4] duplicate ipranges cuase dhcpd Configuration file errors - -LP: #1568207 Remove deprecated node-interface - +Important Announcements +----------------------- -2.0.0 (beta1) -============= +**New Hardware Enablement Kernels naming convention** + Starting from MAAS 2.1 and Ubuntu Xenial, MAAS is adhering to a new naming + convention for hardware enablement kernels. On Xenial and above, MAAS will + not support HWE kernels with the old naming convention, but it will support + HWE kernel channel. For Ubuntu Xenial and Yakkety, currently available + kernels in MAAS now are: + + * ga- + The GA, or general availability kernel is the kernel which the Ubuntu + release shipped with. For example ‘ga-16.04’ is the default 4.4 kernel + which shipped on Ubuntu Xenial. The ga kernel contains all bug and security + fixes provided by the Ubuntu archives. Deployments which use the ga + kernel will stay at the same kernel version through upgrades until the + entire release is upgraded with ‘do-release-upgrade.’ + + * hwe- + The latest Hardware Enablement Kernel currently available in a given + Ubuntu release. As new Hardware Enable Kernels are released with new + Ubuntu releases the hwe- kernel will be upgraded up until the + next LTS. For example hwe-16.04 is currently the 16.04 GA kernel. Once + 16.10 is released the hwe-16.04 kernel will be upgraded to the 16.10 GA + kernel. The kernel will continue to be upgraded up until and including + the 18.04 GA kernel. + +**New Simplestreams Version - Update your images & your Image repositories** + In order to support the new kernels, MAAS has updated the version of the + MAAS Image streams. Previously MAAS has been using the Streams Version 2, + and as of MAAS 2.1 it will use the MAAS Streams Version 3. + + All users who upgrade from an earlier version of MAAS who have been using + the default image mirror, will be automatically migrated to the new version + of streams. + + For all those users running a custom mirror, MAAS won’t make the migration + automatically. Users are requested to update their image mirror to match the + latest images. This image mirror is now available at + http://images.maas.io/ephemeral-v3/. Major new features ------------------ -**Region Controller Redundancy** - Starting from MAAS 2.0 beta 1, MAAS now provides the ability to scale out or - provide redundancy for the MAAS Region Controller API server and DNS. This - will allow administrators to set up multiple MAAS Region Controllers - (maas-region-api) against a common database, providing redundancy of services. - With further manual configuration, users will be able to setup MAAS Region - Controller in High Availability. +**Support for Low Latency kernels.** + Starting from MAAS 2.1 Beta 1 and Ubuntu Xenial, MAAS will be making available + the ability to install low latency kernels. Low latency kernels are available + on i386 and amd64 for both GA and HWE kernels. The currently available + lowlatency kernels are + + * hwe-x-lowlatency - For using the Xenial Lowlatency kernel on Trusty + * ga-16.04-lowlatency - For using the GA lowlatency kernel on Xenial + * hwe-16.04-lowlatency - For using the HWE lowlatency kernel on Xenial. + +**Bootloaders are now provided in the SimpleStream.** + Previously bootloaders where downloaded on the Rack Controller from the Ubuntu + archives for each architecture MAAS had images for. Starting with MAAS 2.1 + Beta 1 bootloaders are downloaded with the images from the SimpleStream. All + Rack Controllers retrieve all supported bootloaders from the Region Controller. + MAAS no longer directly interacts with the Ubuntu archives. + + In the case that bootloaders are missing from the SimpleStream MAAS will + attempt to locate previous downloads of the bootloader as well as package + installs of the bootloader. Minor new features ------------------ -**MAAS Proxy is now managed** - Starting from MAAS 2.0 beta 1, MAAS now manages the configuration for - maas-proxy. This allows MAAS to lock down maas-proxy, and only allow traffic - from networks MAAS know about. For more information see :ref:`MAAS Proxy ` - -**DHCP Snippets WebUI** - MAAS 2.0 beta 1 introduces the ability to add and remove DHCP snippets via - the Web UI. This can be found under the ‘Settings’ page. This feature is - available for administrative only. - -Issues fixed in this release ----------------------------- - -LP: #1557451 [2.0] MAAS api 1.0 version returns null - -LP: #1563094 builtins.FileNotFoundError: [Errno 2] No such file or directory: 'bzr' - -LP: #1557526 [2.0a2] Link "go to rack controllers page" does not link to controllers page. - -LP: #1562106 [2.0a4] Can't assign a 'Static IP' Address - -LP: #1562888 [2.0] DHCP Snippets are not validated before committed - -LP: #1553841 [2.0a1] MAAS should ensure that BMC password is correct before saving - -LP: #1379567 maas-proxy is an open proxy with no ACLs. it should add networks automatically +**Active Device Discovery - Map your subnet** + To complete MAAS’ Active Discovery, starting from beta 1 MAAS 2.1 now allows + the user to ‘Map a subnet’, both automatically at regular intervals, or + manually: + + * Manually + Administrators can now Map a subnet manually from the Subnet Details page + under the ‘Take Action’ option. This will allow administrators to map + their subnet. By default, this will use ping but if nmap is installed, + it will automatically use nmap. + + * Automatically + Administrators can now chose to Map their subnets Automatically at regular + intervals. This allows administrators to have MAAS always probe on the + network to find new devices. By default, the automatic mechanism is enabled, + but no subnet is enabled by default. + + To automatically map each subnet, please refer to the ‘Active Discovery’ + section on the subnet details page. + +Bugs fixed in this release +-------------------------- + +LP: #1392763 When changing sync-url via the UI, it's not obvious if syncing starts on its own or not +LP: #1508975 maas deletes products/images locally that do not exist remotely +LP: #1481285 1.8 Boot images tick boxes should be orange +LP: #1629402 [2.1] please cleanup log format for new interface monitoring state +LP: #1629011 Missing punctuation in disk erasing options +LP: #1629008 Missing preposition sentence disk erasing options +LP: #1629004 Typo: "futher" +LP: #1628052 [2.1, FUJ] Help text in input fields is missing 'e.g' +LP: #1459888 Too much spacing between checkboxes/releases in the 'Images' +LP: #1627039 [2.1] Discovery object and view doesn't set a flag when the device is the DHCP server +LP: #1627038 [2.1] SSH key import should use the specified HTTP proxy if one exists +LP: #1625714 DHCP services on rack controllers only publishes external NTP servers +LP: #1625711 Peer selection for NTP servers on region controllers is broken +LP: #1593388 Changing a boot source URL while images are being download doesn't interrupt current downloads to use the new URL +LP: #1623878 [2.1] mDNS label contains disallowed characters +LP: #1394792 MAAS could do a better job of reporting image download status +LP: #1623110 [2.1] Networks page doesn't load fully on yakkety +LP: #1629896 [2.1] Deployment defaulting to hwe-16.04 instead of ga-16.04 +LP: #1629491 [2.1] After upgrade to latest trunk (pre-beta1) and after updating images, machines fail to pxe boot due to missing hwe-x kernel +LP: #1629142 2.1 DHCP reported as enabled but not running +LP: #1629045 [2.1] When failing to download images, MAAS leaves old files in the fs +LP: #1629022 [2.1, UI] Broken 'images page' link +LP: #1629019 [2.1 ipv6] log_host needs to be ipv6 when booting ipv6-only +LP: #1628298 [2.1 UI] SSH keys not listed on user page and no button to add keys +LP: #1628213 [2.1 yakkety UI] First user journey doesn't display and can't be skipped +LP: #1627363 [2.1] 'NoneType' object has no attribute 'external_dhcp' +LP: #1627019 [2.1, rev5385] NTP services on region/rack keep showing as ON/OFF constantly +LP: #1623634 [2.1, UX] Trying to cancel an image import from the new Images page results on it not being cancelled on the backend. +LP: #1589640 [2.0b6] MAAS should validate a boot source path actually provides images + +Known issues and workarounds +Trusty images not available on fresh installs +The MAAS Images V3 streams do not yet have Ubuntu Trusty available. These are currently being built to be made available. + +User’s upgrading from a previous version of MAAS that had originally imported Trusty images will continue to be able to deploy Trusty. Once the images are made available, MAAS will automatically update (if so configured). -LP: #1562214 [2.0a4] If external proxy is being used, status from maas-proxy shouldn't be surfaced +LP: #1627362 - expected string or bytes-like object +In some situations after an upgrade, accessing the dashboard might yield error above. This is a difficult to easily reproduce issue. If you come across it please contact a MAAS developer immediately. -LP: #1555392 [2.0a1] python3-maas-client needs to send data as bytes() +https://bugs.launchpad.net/maas/+bug/1627362 -LP: #1563807 Systemd units need to reflect updated MAAS names -LP: #1563799 [2.0a4] Permission error for boot-resources/cache - -LP: #1563779 [2.0a4] maas-rackd missing presumed lost - - -2.0.0 (alpha4) +2.1.0 (alpha4) ============== -Important annoucements ----------------------- +Important Announcements +----------------------- + +**MAAS Landing page - Let’s see what’s on your network!** + As of MAAS 2.1 alpha 4, administrative users have a new landing page. Once + administrators log in they will be redirected to the MAAS dashboard. -**maas-region-controller-min has been renamed to maas-region-api** - The `maas-region-controller-min` package has now been renamed to - `maas-region-api`. This package provides the API services for MAAS - (maas-regiond) and can be used to scale out the API front-end of - your MAAS region controller. + This dashboard is where administrators will have some basic information + and the ability to see the observed and discovered devices. Major new features ------------------ -**DHCP Snippets Backend & API** - MAAS 2.0 alpha 4 introduces the ability to define DHCP snippets. This - feature allows administrators to manage DHCP directly from MAAS’, removing - the need to manually modify template files. Snippets can be defined as: - - * `Host snippets`, allowing to define configuration for a particular node in MAAS. - * `Subnet snippets`, allowing to define configuration for a specific subnet in MAAS. - * `Global snippets`, allowing to define configuration that will affect DHCP (isc-dhcp) as a whole. - - For more information, see :ref:`DHCP Snippets `. +**Device discovery UI** + MAAS 2.1 alpha 4 introduces the MAAS Device Discovery UI. As part of the + dashboard, administrative users will be able to see all the observed and + discovered devices. + + MAAS will also allow administrator to properly register those discoveries + as MAAS known devices, and be able to select the IP address allocation for + them, if MAAS is to manage them. + +**Active Device Discovery - map your network (API only)** + As of MAAS 2.1 alpha 2, networks attached to rack controllers are observed + for device discovery purposes. MAAS listens to ARP requests and replies to + determine which IPv4 addresses are in-use on attached networks, and will + resolve their hostnames if possible (when advertised using the mDNS + protocol). + + As of MAAS 2.1 alpha 4, MAAS now has the ability to actively probe subnets. + This allows MAAS to keep its knowledge of which devices are on the network + up-to-date, and discover “quiet” devices that MAAS would not be able to + observe passively. If ‘nmap’ is installed, MAAS will prefer to use it for + scanning (since the scan is faster and will transmit fewer packets). If + ‘nmap’ is not installed, MAAS will fall back to using parallel ‘ping’ requests. + + Scanning is available using the API at the following URL: + + POST /MAAS/api/2.0/discovery/?op=scan + + To scan using the command-line interface, you can use the following syntax: + + maas discoveries scan [cidr= [cidr=....] [force=true] [always_use_ping=true] [slow=true] [threads=] + + If you want to scan particular subnets, specify one or more using the cidr + option. For example, ‘cidr=192.168.0.0/24’ would scan for neighbours on + 192.168.0.0/24 on any rack controller configured with an address in that + network. The cidr option can be specified multiple times, such as + ‘cidr=192.168.0.0/24 cidr=192.168.1.0/24’. + + If you want to scan all networks attached to all rack controllers, you must + specify the “force=true” option. (This is not allowed by default, since some + network operators do not allow active neighbour scanning.) + + If your organization has a policy against using ‘nmap’, you will want to use + the ‘always_use_ping’ option, in case ‘nmap’ has been installed on a rack + controller by mistake. + + If quickly scanning your network using ‘nmap’ may raise alerts with an + intrusion detection system, you can use the ‘slow=true’ argument to slow + down scanning. This option has no effect when using ‘ping’, since scanning + using ‘ping’ is already slower. If using ‘ping’, scans can be slowed down or + sped up, if desired, by using the threads option, such as by specifying + “threads=2”. Using the threads option has less impact on nmap threads, which + use a single thread to scan an entire network. Minor new features ------------------ -**Rack Controller Web UI Improvements** - MAAS 2.0 alpha 4 adds the UI for Served VLANs and Service Tracking, allowing users - to see what VLANs are being currently served by a rack controller, and the status - of the services in those Rack Controllers. - -**Rsyslog during enlistment and commissioning** - MAAS 2.0 alpha 4 now enables rsyslog for the enlistment and commissioning - environment when using Xenial as the Commissioning image. This allows users - to see all cloud-init’s syslog information in /var/log/maas/rsyslog/. - -Known issues and work arounds ------------------------------ - -**DHCP snippets are not validated before committed** - When DHCP snippets are created, MAAS is not validating the DHCP snippet against - isc-dhcp config. This means that if users input invalid isc-dhcp configuration, - this will cause the DHCP config to be generated anyway, yielding maas-dhcp to - not be working properly or started at all. - - See bug `1562888`_ for more information. - -.. _1562888: - http://launchpad.net/bugs/1562888 - -Issues fixed in this release ----------------------------- - -LP: #1561816 Rack controller 'None' disconnected. - -LP: #1557616 [2.0a2] UI provides no way to disable DHCP - -LP: #1559332 [2.0a3] Server VLAN's UI is showing too many vlans - -LP: #1555679 [2.0a1] bridges with same mac as physical interfaces prevent rack interface discovery +**First User Journey - Import your SSH keys from Launchpad or Github** + The ability to import SSH keys from Launchpad or Github was introduced in + MAAS alpha 3. As of alpha 4, you can do so via the Front-end. + + All users will now have the ability to import their SSH keys from the UI. + All users who log-in to MAAS for the first time will be prompted to import + their SSH keys, if they so desire. Alternatively, users can do so via their + user profile page. -LP: #1560233 [2.0a3] maas-regiond not available right after install. - -LP: #1559330 [2.0a3] maas-rackd attemps to connect to regiond, constantely, without stop - -LP: #1559361 [2.0a3] maas-dhcpd is being restarted constantly while enlisting/commissioning multiple machines - -LP: #1559327 [2.0a3] dhcpd is configured incorrectly when two subnets are incorrectly placed in the same VLAN - -LP: #1549843 [2.0a1] Failed to update this region's process and endpoints; unleashed:pid=28940 record's may be out of date - -LP: #1559398 [2.0a3] Can't commission too many machines at a time +Other notable changes +--------------------- -LP: #1556366 [2.0a1] PXE interface incorrectly displayed on the UI +**NTP Improvements - MAAS NTP vs External** + MAAS now provides the ability to decide between using solely an external NTP + server or a MAAS run NTP server. MAAS run NTP services is the preferred + configuration, but, in order to maintain backwards compatibility, + administrators can chose to use external NTP organizations. This will only + be suitable for scenarios where administrators have restricted communication + between their machines and the MAAS rack controllers. + +Bugs fixed in this release +-------------------------- + +#1625668 [2.1] When trying to add SSH keys for a GH user that doesn't exist, there's no feedback +#1626748 [2.1] maas admin discoveries scan API output shows rack controller ids instead of names +#1626722 [2.1] DHPv6 addresses do not have netmasks: do not create /128 subnets for them +#1625812 [2.1] Error message is not user friendly +#1625689 [2.1] default gateway cannot be set to fe80::/64 via web ui +#1626727 [2.1] You can define distribution or component for 'ubuntu archive' or 'ubuntu extra architectures' +#1625671 [2.1] Need better error message when trying to add SSH keys for LP/GH user that doesn't exist +#1623994 [2.1] DHCP configuration breaks when NTP servers are unresolvable. +#1626669 [2.1] Can't logout, create users and do other actions +#1625674 [2.1] No feedback when there are no keys to import from LP/GH + +Known issues and workarounds +---------------------------- + +**LP: #1623634: Unable to cancel the image import.** + When downloading images, MAAS will fail to cancel the import of all or + any of the images being imported. MAAS will first download all the images + before the user is able to remove them. + + See bug `1617596`_ for more information. + +.. _1617596: + http://launchpad.net/bugs/1617596 + +**LP: 1624693: Rack failed to run/register on fresh install** + The MAAS Rack Controller is unable to register after a fresh install due to + being unable to parse network interfaces. After manual restart of maas-rackd, + the rack was successfully registered. + See bug `1624693`_ for more information. -2.0.0 (alpha3) -============== +.. _1624693: + http://launchpad.net/bugs/1624693 -Important Announcements ------------------------ -**Debian Installer Files are no longer installed** - Following the full drop of support for the Debian Installer (DI) in - 1.9, MAAS no longer downloads the DI related files from simplestreams - and on upgrade all DI related files will be removed both from the - region and all rack controllers. +2.1.0 (alpha 3) +=============== Major new features ------------------ -**Networks WebUI** - MAAS 2.0.0 alpha 3 is introducing a few new Web UI features that were - not available in MAAS 1.9 or MAAS 1.10. - - * Add Fabric and Space details pages - MAAS 2.0.0 now displays more detailed information of the Fabric and - Space, by introducing the details page for each. - - * Add ability to add/remove (create/delete) new Fabrics, Spaces, Subnets and VLANs - MAAS 2.0.0 now provides the ability to add new Fabrics, Spaces, Subnets and VLANs. - This can be done as actions under the Networks listing page. - - The ability to delete such Fabrics, Spaces, Subnets and VLANs is also available, - however, this is only possible for the non-default components and from the - component’s details page. - -**WebUI for new storage features** - MAAS 2.0.0 alpha 3 provides the ability to add mount options via the WebUI. - MAAS 2.0.0 alpha 3 also provides the ability to create new swap partitions - via the WebUI. As a reminder, previous MAAS releases would automatically - create a swap file, but starting from MAAS 2.0, users will have the - ability to create a swap partition instead, if so desired. +**First User Configuration Journey (UI)** + Starting from alpha 3, MAAS now provides the ability for administrators to + perform some initial configuration when they log-in into the UI for the + first time. The configuration includes: + + * Ability to change the name of your MAAS. + * Ability to configure options that affect connectivity: + * Option to select an Upstream DNS Server (Optional) + * Option to input different Ubuntu Mirrors (Required). + * Option to input an external proxy (Optional) + * Ability to select additional images to download. + +**MAAS time sync, NTP services and configuration** + Starting from alpha 3, MAAS now provides managed NTP services (with ntpd) in + both the Region and Rack controller. This allows MAAS to not only keep its + own controllers time synced, but the deployed machines as well. + + * Region Controller time syncs from external source + The Region Controller configures the NTP service (ntpd) to keep its time + sync from one or various external sources. By default, the MAAS region + controller syncs its time from ntp.ubuntu.com. The default can be changed + by one or multiple external NTP servers from the Settings page, under the + Network Configuration section. + + * Rack Controller time syncs from the Region Controller + The Rack Controllers also configure the NTP service (ntpd). Unlike the + Region Controllers, the Rack Controllers sync their time from the Region + Controller(s) instead of accessing directly to the external time source. + + Additionally, the Rack Controllers also configure DHCP with the correct + NTP information, so that any machine on the network that DHCP’s from MAAS + can benefit of the NTP configuration. + + * Machines configured to sync time from external NTP (transitional). + MAAS also configures deployed machines with NTP configuration. This is done + by cloud-init via MAAS vendor data. + + During the transition period, MAAS will configure machines to use the + external time source (configured under the Settings page). Note that this + is transitional, as in future releases the machines will default to the + Rack Controller for NTP. + +**MAAS Images page re-written in AngularJS** + Continuing the transition from YUI to AngularJS, the MAAS Images page has now + been completely redesigned and reimplemented in AngularJS. Improvements to + the Image page include: + + * Ability to select the image source (maas.io or custom repository). + Show the releases and architectures available in the custom repository + before the import starts. + + * Ability to view the status of the image in the import process. + Show percentage based progress on the image import. + + Additionally, the ‘Boot Images’ section in the Settings page has been removed. + +**Minor new features** + + * (Backend) Ability to import SSH keys from Launchpad and Github + MAAS now provides the ability to import SSH keys for a user from Launchpad + and Github. This is currently supported via the API or via the user + creation process. Users can import their SSH keys when creating their user + for Launchpad or Github: + + maas createadmin --ssh-import lp: + maas createadmin --ssh-import gh: + + Or via the API based CLI with: + + maas sshkeys import protocol=lp auth_id= + maas sshkeys import protocol=gh auth_id= + + * MAAS now provides cloud-init vendor data for NTP + As of MAAS 2.1 alpha 3, MAAS now provide cloud-init vendor data. Vendor + data allows cloud-init to do some initial configurations on the system + before user data is being run. As of 2.1, MAAS will provide NTP + configuration which is delivered via vendor data. Note that this is + dependent on the latest version of cloud-init (0.7.8-1-g3705bb5-0ubuntu1). + This is currently available in Yakkety and is in progress to be available + in Xenial. + + * Add ability to enable or disable network discovery + MAAS now provides the ability to disable the discovery of networks and + devices. By default, discovery is enabled. This setting can be changed + under the Settings page, or via the MAAS CLI and API using the + “network_discovery” configuration key. (Accepted values are “enabled” and + “disabled”.) When discovery is disabled, mDNS records and ARP requests will + no longer be stored in MAAS, and the listening processes on each rack + controller will be shut down. -Minor new features ------------------- +Other notable changes +--------------------- -**Ability to change a machine’s domain name from the UI** - MAAS 2.0.0 alpha 3 introduces the ability to change a machine’s DNS domain - via the WebUI. It was previously supported on the API only. +**HTML template updates** + In MAAS 2.1 alpha 3, the HTML templates and SCSS framework has been + completely rebuilt and using the current Vanilla CSS framework as its base. + This includes all design patterns and utility classes which would be expected + of a powerful frontend GUI framework. -**Rack Controller details page now shows served VLANs** - The Rack Controller details page now shows what VLANs are being served on - this Rack Controller, and whether it is the primary or secondary Rack - providing services for such VLAN. + HTML and CSS templates have been completely redesigned to use the new + “Vanilla” styles. This brings a refreshed look of icons and interactions that + benefit the UI. While users may not see much difference, it has been + completely re-implemented in the backend. -**Added `maas-rack support-dump` command** - For increased support observability, users can now dump the contents of - several commonly-needed data structures by executing `sudo maas-rack support-dump`. - This command will dump networking diagnostics, rack configuration, and image - information. Information can be restricted to a particular category by using - the `--networking`, `--config`, or `--images` options. + Thank you the design and web teams for their contribution to MAAS. -Known issues and work arounds ------------------------------ +Known issues and workarounds +---------------------------- -**Rack Controller tries to constantly reconnect** - In some situations, the MAAS Rack Controller will try to constantly re-connect - to the region controller after a restart, causing the Rack Controller to be - unavailable for a period of time. +**Unable to cancel the image import.** + When downloading images, MAAS will fail to cancel the import of all or any of + the images being imported. MAAS will first download all the images before the + user is able to remove them. - At the moment, there's no work around other than to wait for a few minutes - until the Rack Controller has been fully connected. + See bug `1623634`_ for more information. - See bug `1559330`_ for more information. +.. _1623634: + http://launchpad.net/bugs/1623634 -.. _1559330: - http://launchpad.net/bugs/1559330 +**Unable to enable DHCP if NTP server is unresolvable.** + If the NTP server(s) are unresolvable, DHCP will fail to enable. This is + because DHCP doesn’t accept DNS names for DHCP’s NTP configuration, and as + such, MAAS tries to resolve the domain before it is able to set it in the + configuration. -Major bugs fixed in this release --------------------------------- + See bug `1623994`_ for more information. -LP: #1555393 python3-maas-client API 2.0 seems to no longer use op but MAASClient.post requires it and incorectly passes it along +.. _1623994: + http://launchpad.net/bugs/1623994 -LP: #1554566 Fail to commission when Fabric on Machine Interface and Rack Interface dont match +**Rack failed to run/register on fresh install** + The MAAS Rack Controller is unable to register after a fresh install due to + being unable to parse network interfaces. After manual restart of maas-rackd, + the rack was successfully registered. -LP: #1553848 TFTP back-end crashes + See bug `1624693`_ for more information. -LP: #1554999 Can't deploy a node (no interfaces on rack controller) +.. _1624693: + http://launchpad.net/bugs/1624693 -2.0.0 (alpha2) +2.1.0 (alpha2) ============== Important Announcements ----------------------- -**maas-region-admin command has been replaced** - The MAAS Region command, `maas-region-admin` has now been replaced - by the `maas-region` command. - -**maas-provision command has been replaced** - The MAAS Rack Controller command, `maas-provision`, has now been - replaced by the `maas-rack` command. +**commissioning-user-data and pxe/uefi templates no longer available** + In the past, MAAS stored commissioning-user-data and pxe/uefi templates + in `/etc/maas/templates`. As of MAAS 2.1.0 Alpha 2, these templates are + no longer available under /etc/maas. -Major new features +Major New Features ------------------ -**Networks listing page** - A new Networks listing page has been introduced, that allows users - users to have a better view of MAAS networking concepts under the - 'Networks' tab. It allows users to filter by `Fabric` and `Space`. +**(Backend) Device Discovery** + As of MAAS 2.1.0 Alpha 2, MAAS will automatically listen to the network + and report any observed devices. + + * New discovery API can be used to get information about what MAAS has + discovered. This API can be used from the command line interface as + follows: + + * maas discoveries read - Lists all MAC, IP bindings + (discoveries) that MAAS has seen, and attempts to correlate those + discoveries with hostnames advertised by mDNS. + * maas discoveries by-unknown-mac - Lists all discoveries, + but filters out discoveries where the MAC belongs to an interface + known to MAAS. + * maas discoveries by-unknown-ip - Lists all discoveries, + but filters out discoveries where the IP address is known to MAAS + (such as reserved by a user, or assigned to a node). + * maas discoveries by-unknown-ip-and-mac - Lists all discoveries, + but applies the filters for both unknown MACs and unknown IP addresses. + + * Note that the discovery API is currently read-only. It brings together + data from several different sources, including observed network neighbours, + resolved mDNS hostnames, and controller interface information. + * New maas-rack commands have been added, which are called internally by + MAAS in order to gather information about observed devices on the network. + MAAS administrators should not normally need to use these commands + (although they could be helpful for supportability). + + * maas-rack observe-mdns [--verbose] + * sudo maas-rack observe-arp [--verbose] + + * Note: this feature intentionally does not place any network devices into + “promiscuous mode”, or actively probe. MAAS controllers listen to ARP + traffic they would have received anyway. Therefore, if a MAAS admin wants + to keep MAAS’s knowledge of the network up-to-date, a command such as one + of the following could be run periodically (such as from a script invoked + by a crontab); MAAS will listen to any ARP replies and update its knowledge + of the network: + + * To actively probe one or more subnet CIDRs on an interface: + sudo nmap -e -sn -n -oX - -PR [cidr2] [...] + + * To actively probe for a single IP address from a particular interface + (regardless of whether or not the IP address is routable on-link on that + interface): + ping -r -I -c 3 -w 1 -i 0.2 -D -O + + * MAAS now depends on the avahi-utils and tcpdump packages in order to provide + this functionality. (Before MAAS 2.1.0 is released, the MAAS team will consider + making these optional dependencies, in case MAAS administrators do not want + to run the avahi daemon, or require that tcpdump not be installed.) + +Important Bugs Fixed in this Release +------------------------------------ + +**Bug #1617596: [2.1] Rack(relay) Controller is rejected after upgrade to 2.1** + Fixes a regression regarding registering rack controllers which have bonds + interfaces which are not currently bonding any interfaces. + + See bug `1617596`_ for more information. + +.. _1617596: + http://launchpad.net/bugs/1617596 + +**Bug #1615618: [2.1] 'SERVICE_STATE' object has no attribute 'getStatusInfo'** + Fixes a regression in the service tracking mechanism, where it would fail to + successfully track the status of some services. -**Service Tracking** - MAAS is now fully tracking the status of the services for the different - services that MAAS uses, as defined by systemd. These services are: + See bug `1615618`_ for more information. - * maas-proxy - * bind - * maas-dhcpd and maas-dhcpd6 - * tgt +.. _1615618: + http://launchpad.net/bugs/1615618 -Known issues & work arounds ---------------------------- -**Failure to commission when Machine interfaces are not in the same fabric as DHCP** - Machines fail to commission when its interfaces are in a different fabric from the - one DHCP is running on. - - For example, if DHCP is enabled on `fabric-2`, and the machine's PXE interface is on - `fabric-0`, the machine will fail to commission. To work around this, you can update - the Rack Controller interface connected to `fabric-2`, to be under `fabric-0`, and - enabling DHCP on the `untagged` VLAN under `fabric-0`. - - See bug `1553617`_ for more information. - -.. _1554566: - https://launchpad.net/bugs/1554566 - - -2.0.0 (alpha1) -============== - -Important Announcements ------------------------ - -**MAAS 2.0 supported on Ubuntu 16.04 LTS (Xenial)** - MAAS version 2.0 will be supported on Ubuntu 16.04 LTS. MAAS 2.0 (and - the transitional 1.10 release) will NOT be supported on Ubuntu 14.04 LTS. - MAAS versions 1.9 and earlier will continue to be supported on Ubuntu - 14.04 LTS (Trusty) until they reach end-of-life. - - Upgrades are supported for users running Ubuntu 14.04 systems running - MAAS 1.9 or earlier. Upon upgrading to Ubuntu 16.04, the MAAS - database and configuration will be seamlessly migrated to the supported - MAAS version. - - Please see the “Other Notable Changes” section below for more details - regarding the reasons for this change. - -**API 1.0 has been deprecated, introducing API 2.0** - Starting from MAAS 2.0, the API 1.0 has now been deprecated and a new - MAAS 2.0 API is being introduced. With the introduction of the new - API version, various different endpoints have now been deprecated - and new end-points have been introduced. API users will need to update - their client tools to reflect the changes of the new API 2.0. - - For more information on API 2.0, refer to :ref:`API documentation `. - -**Cluster Controllers have now been deprecated. Introducing Rack Controllers** - Starting from MAAS 2.0, MAAS Cluster Controllers have been deprecated - alongside with the NodeGroups API. The Cluster Controllers have been - replaced with Rack Controllers, and the RackController API have now - been introduced. Thehe new Rack Controllers currently provides feature - parity with earlier versions of MAAS. - - For more information on Rack Controllers, refer to the `Major new Features` - section bellow or refer to :ref:`rack-configuration`. - -**MAAS Static Range has been deprecated** - Starting from MAAS 2.0, the MAAS Static Range has now been deprecated, - and MAAS assumes total control of a subnet. MAAS will auto-assign IP - addresses to deployed machines that are not within a dynamic or a reserved - range. Users are now only required to (continue to) specify the dynamic - range, which continues to be used for auto-enlistment, commissioning, - and any other systems configured for DHCP. - -Major new features -------------------- - -**MAAS Rack Controllers** - Starting for MAAS 2.0, MAAS has introduced Rack Controllers that completely - replace Cluster Controllers. - - * NodeGroups and NodeGroupInterfaces API endpoints are now deprecated. - RackControllers API endpoint has been introduced. - - * Clusters tab is no longer available in the WebUI. - Controllers can now be found under the Nodes tab, where each cluster - interface can be found. Other cluster interface properties have been - moved to the Subnet and VLAN details page under the “Networks” tab. - - * Machines no longer belong to Rack Controllers. - In earlier versions of MAAS, Machines would directly belong to a Cluster - Controller in order for them to be managed. The Cluster Controller that - the machine belonged to would not only perform DHCP for that machine, - but also all the PXE/TFTP booting, and power management. - - As of MAAS 2.0, Machines no longer belong to a Rack Controller. Multiple - Rack Controllers could potentially manage the machine. This is now - automatically determined. - - * DHCP now configured per VLAN - In earlier versions of MAAS, DHCP was directly linked and configured - per Cluster Controller Interface. As of MAAS 2.0, DHCP is now configured - and managed per VLAN, allowing the ability for any Rack Controller in a - VLAN to manage DHCP. - - * Rack Controllers now provide High Availability - Provided that machines no longer belong to a Rack Controller, and that - DHCP is managed on the VLAN bases, multiple Rack Controllers can manage - the same set of machines. Starting from MAAS 2.0, Rack Controllers in the - same VLAN become candidates to manage DHCP, PXE/TFTP, and power for the - machines connected to the VLAN. - - As such, Rack Controllers now support high availability. MAAS supports - the concept of Primary and Secondary Rack Controller. In the event that - the Primary Rack Controller is unavailable, the Secondary Rack Controller - can take over the services provided providing High Availability. - -**DNS Management** - MAAS 2.0 extends DNS management and provides the ability to: - - * Ability to create multiple DNS domains. - * Ability to add multiple records (CNAME, TXT, MX, SRV ) per - domain. (API only) - * Ability to select Domain for Machines and Devices. (API only, WebUI - in progress) - * Ability to assign (additional) names to IP addresses (API only) - * For deployed machines, A records continue to be create specifying - the IP of the PXE interface. - * Additional PTR records and now created for all the other interfaces in - the form of: . - * Reverse DNS is now generated for only the subnet specified, rather - than the parent /24 or /16. By default, RFC2137 glue is provided - for networks smaller than /24. This can be disabled or changed - on a per-subnet basis via the API. - -**IP Ranges** - Previous versions of MAAS used the concepts of a “dynamic range” and - “static range”, which were properties of each cluster interface. This - has been redesigned for MAAS 2.0 as follows: - - * Dynamic ranges have been migrated from MAAS 1.10 and earlier as-is. - - * Because static ranges have been removed from MAAS, each static - range has been migrated to one or more reserved ranges, which - represent the opposite of the previous static range. (MAAS now - assumes it has full control of each managed subnet, and is free - to assign IP addresses as it sees fit, unless told otherwise.) - - For example, if in MAAS 1.10 or earlier you configured a cluster - interface on 192.168.0.1/24, with a dynamic range of 192.168.0.2 - through 192.168.0.99, and a static range of 192.168.0.100 through - 192.168.0.199, this will be migrated to: - - IP range #1 (dynamic): 192.168.0.2 - 192.168.0.99 - IP range #2 (reserved): 192.168.0.200 - 192.168.0.254 - - Since 192.168.0.100 - 192.168.0.199 (the previous static range) - is not accounted for, MAAS assumes it is free to allocate static - IP addresses from that range. - - * Scalability is now possible by means of adding a second dynamic - IP range to a VLAN. (To deal with IP address exhaustion, MAAS - supports multiple dynamic ranges on one or more subnets within - a DHCP-enabled VLAN.) - - * Reserved ranges can now be allocated to a particular MAAS user. - - * A comment field has been added, so that users can indicate why - a particular range of IP addresses is reserved. - -**API 2.0 and MAAS CLI Updates** - MAAS 2.0 introduces a new API version, fully deprecating the - MAAS 1.0 API. As such, new endpoints and commands have been introduced: - - * RackControllers - This endpoint/command has the following operations - in addition to the base operations provided by nodes: - - * import-boot-images - Import the boot images on all rack - controllers - * describe-power-types - Query all of the rack controllers for - power information - - * RackController - This endpoint/command has the following operations - in addition to the base operations provided by nodes - - * import-boot-images - Import boot images on the given rack - controller - * refresh - refresh the hardware information for the given rack - controller - - * Machines - This endpoint/command replaces many of the operations - previously found in the nodes endpoint/command. The machines - endpoint/command has the following operations in addition to the - base operations provided by nodes. - - * power-parameters - Retrieve power parameters for multiple - machines - * list-allocated - Fetch machines that were allocated to the - user/oauth token. - * allocate - Allocate an available machine for deployment. - * accept - Accept declared machine into MAAS. - * accept-all - Accept all declared machines into MAAS. - * create - Create a new machine. - * add-chassis - Add special hardware types. - * release - Release multiple machines. - - * Machine - This endpoint/command replaces many of the operations - previously found in the node endpoint/command. The machine - endpoint/command has the following operations in addition to the - base operations provided by node. - - * power-parameters - Obtain power parameters for the given machine. - * deploy - Deploy an operating system to a given machine. - * abort - Abort the machines current operation. - * get-curtin-config - Return the rendered curtin configuration for - the machine. - * power-off - Power off the given machine. - * set-storage-layout - Change the storage layout of the given - machine. - * power-on -Turn on the given machine. - * release - Release a given machine. - * clear-default-gateways - Clear any set default gateways on the - machine. - * update - Change machine configuration. - * query-power-state - Query the power state of a machine. - * commission - Begin commissioning process for a machine - - Other endpoints/commands have changed: - - * All list commands/operations have been converted to read - * All new and add commands/operations have been converted to create - * Nodes - The nodes endpoint/command is now a base endpoint/command - for all other node types(devices, machines, and rack-controllers). - As such most operations have been moved to the machines - endpoint/command.The following operations remain as they can be - used on all node types. - - * is-registered - Returns whether or not the given MAC address is - registered with this MAAS. - * set-zone - Assign multiple nodes to a physical zone at once. - * read - List nodes visible to the user, optionally filtered by - criteria. - - * Node - The node endpoint/command is now a base endpoint/command for - all other node types(devices, machines, and rack-controllers). As - such most operations have been moved to the machine endpoint/command. - The following operations remain as they can be used on all node types. - - * read - Read information about a specific node - * details - Obtain various system details. - * delete - Delete a specific node. - - * With the migration of nodes to machines the following items previously - outputted with the list command have been changed or removed from the - machines read command: - - * status - Will now show all status types - * substatus, substatus_action, substatus_message, substatus_name - - Replaced by status, status_action, status_message, status_name. - * boot_type - Removed, MAAS 2.0 only supports fastpath. - * pxe_mac - Replaced by boot_interface. - * hostname - Now only displays the hostname, without the domain, of - the machine. To get the fully qualified domain name the fqdn and - domain are now also outputted. - - * And other endpoints/commands have been deprecated: - - * NodeGroups - Replacement operations are found in the - RackControllers, Machines, and BootResources endpoints/commands. - * NodeGroupInterfaces - replacement operations are found in the - RackController, IPRanges, Subnets, and VLANS endpoints/commands. - -**Extended Storage Support** - MAAS 2.0 Storage Model has been extended to support: - - * XFS as a filesystem. - * Mount Options. - * Swap partitions. MAAS 1.9 only supported the creation of a swap - file in the filesystem. - * tmps/ramfs Support. +Other Notable Changes +--------------------- - All of these options are currently available over the CLI. +**WebUI - Better error surfacing for DHCP snippets and Package Repositories** + Both the DHCP Snippets Section and the Package Repositories section have now + been improvement and will surface better errors. -Other notable changes ---------------------- +Ongoing Work +------------ -**MAAS 2.0 Requires Python 3.5** - Starting from MAAS 1.10 transitional release, MAAS has now been - ported to Python 3. The Python 3 version ported against is 3.5, - which is default in Ubuntu Xenial. - -**MAAS 2.0 now fully supports native Django 1.8 migration system** - Starting from the MAAS 1.10 transitional release, MAAS has added - support for Django 1.8. Django 1.8 has dropped support for the - south migration system in favor of the native Django migration - system, breaking backwards compatibility. As such, MAAS 2.0 has - inherited such support and moving forward migrations will be run - with the native migration system. - - Provided that Django 1.8 breaks backwards compatibility with the - south migration system, the MAAS team has put significant effort - in ensuring MAAS continues to support an upgrade path, and as - such, users from 1.5, 1.7, 1.8, 1.9 and 1.10 will be able to - upgrade seamlessly to MAAS 2.0. - -**Instant DHCP Lease Notifications** - We no longer scan the leases file every 5 minutes. ISC-DHCP now - directly notifies MAAS if a lease is committed, released, or expires. - -**Host entries in DHCP** - Host entries are now rendered in the DHCP configuration instead - of placed in the leases file. This removes any state that used - to previously exist in the leases file on the cluster controller. - Now deleting the dhcpd.leases file will not cause an issue with - MAAS static mappings. - -**Modeling BMCs** - We select one of the available rack controllers to power control - or query a BMC. The same rack controller that powers the BMC does - not need to be the rack controller that the machine PXE boots from. + * First User Journery - WebUI + * Device Discovery - WebUI + * Improved IPv6 Support + * MAAS Services - NTP + * MAAS Image Consolidation + * Support for HWE Rolling Kernels -Known Problems & Workarounds +Known Issues and Workarounds ---------------------------- -**Rack Controllers will fail to register when bond interfaces are present** - Registering Rack Controller that have bond interfaces will fail. +**Configuring APT key’s in ephemeral environment (overlayfs) fails.** + A regression preventing cloud-init from configuring APT's key in a + ephemeral environment, prevents MAAS from enlisting, commissioning and + deploying `only` when using Derived Repositories or Custom Mirrors that + require a new key. - See bug `1553617`_ for more information. + See bug `1618572`_ for more information. -.. _1553617: - https://launchpad.net/bugs/1553617 +.. _1618572: + http://launchpad.net/bugs/1618572 diff -Nru maas-2.0.0+bzr5189/docs/development/lease-scanning-and-dns.rst maas-2.1.1+bzr5544/docs/development/lease-scanning-and-dns.rst --- maas-2.0.0+bzr5189/docs/development/lease-scanning-and-dns.rst 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/development/lease-scanning-and-dns.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,36 +0,0 @@ -.. -*- mode: rst -*- - -*************************** -DHCP lease scanning and DNS -*************************** - -Overview -======== - -In a MAAS system, cluster controllers may optionally manage the DHCP, and the -region controller may optionally manage the DNS. - -The region controller periodically tells the cluster controllers to report -their DCHP leases. When a cluster controller reports new leases, the region -controller creates DNS records for them, and instructs the cluster controller -to convert the leases to static host mappings. - - -Leases scanning -=============== - -MAAS will periodically scan the DHCP leases file using the -``LeaseUploadService()`` pserv service. - -As leases are discovered, it calls the RPC function ``UpdateLeases`` which -stores the active leases in the DHCPLease table. - - -Updating one or more DNS zone files -=================================== - -If a new lease is found then the dns.dns_update_zones() function gets called -which takes two steps:: - - #. Write out updated zone files. - #. Ask BIND to reload the zone. diff -Nru maas-2.0.0+bzr5189/docs/development/rpc.rst maas-2.1.1+bzr5544/docs/development/rpc.rst --- maas-2.0.0+bzr5189/docs/development/rpc.rst 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/development/rpc.rst 2016-11-08 19:56:20.000000000 +0000 @@ -4,7 +4,7 @@ ========= MAAS contains an RPC mechanism such that every process in the region is -connected to every process in the cluster (strictly, every pserv +connected to every process in the cluster (strictly, every rackd process). It's based on AMP_, specifically `Twisted's implementation`_. .. _AMP: diff -Nru maas-2.0.0+bzr5189/docs/index.rst maas-2.1.1+bzr5544/docs/index.rst --- maas-2.0.0+bzr5189/docs/index.rst 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/index.rst 2016-11-08 19:56:20.000000000 +0000 @@ -71,6 +71,7 @@ proxy devices dhcpsnippets + packagerepositories power-driver-capabilities @@ -137,7 +138,6 @@ development/cluster-registration development/cluster-bootstrap development/tagging - development/lease-scanning-and-dns development/preseeds development/metadata development/rpc diff -Nru maas-2.0.0+bzr5189/docs/install.rst maas-2.1.1+bzr5544/docs/install.rst --- maas-2.0.0+bzr5189/docs/install.rst 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/install.rst 2016-11-08 19:56:20.000000000 +0000 @@ -254,11 +254,12 @@ Third, edit the container profile (`lxc profile edit maas`) with:: - raw.lxc: |- - lxc.cgroup.devices.allow = c 10:237 rwm - lxc.aa_profile = unconfined - lxc.cgroup.devices.allow = b 7:* rwm - security.privileged: "true" + config: + raw.lxc: |- + lxc.cgroup.devices.allow = c 10:237 rwm + lxc.aa_profile = unconfined + lxc.cgroup.devices.allow = b 7:* rwm + security.privileged: "true" And lastly, ensure that the LXC container has loop devices added:: @@ -277,7 +278,7 @@ Once the container is running, you can now install MAAS. First you need to access the container with:: - $ lxc exec bash xenial-maas + $ lxc exec xenial-maas bash And you can proceed with the installation as above, :ref:`From a package repository. ` diff -Nru maas-2.0.0+bzr5189/docs/packagerepositories.rst maas-2.1.1+bzr5544/docs/packagerepositories.rst --- maas-2.0.0+bzr5189/docs/packagerepositories.rst 1970-01-01 00:00:00.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/packagerepositories.rst 2016-11-08 19:56:20.000000000 +0000 @@ -0,0 +1,71 @@ +.. -*- mode: rst -*- + +.. _packagerepositories: + +==================== +Package Repositories +==================== + +.. note:: + + This feature is available in MAAS versions 2.0 and above. + +MAAS allows the configuring of multiple additional package repositories, which +will find their way into the /etc/apt/sources.list on MAAS deployed machines. + +Creating a Package Repository +----------------------------- + +Administrators can create Package Repositories over the API using the following command::: + + $ maas package-repositories create name= url= + +These are the minimally required parameters - see the online API help, +described below, for the complete list of parameters. + +Package Repository Enablement +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +Package Repositories can be turned off by using the enabled flag option as follows::: + + $ maas package-repositories create name= url= enabled=false + +The enabled flag can be modified on an existing repository by using the update +API, described below. + +Listing Package Repositories +---------------------------- + +To list all Package Repositories use the following command::: + + $ maas package-repositories read + +To list a particular Package Repository use the following command::: + + $ maas package-repository read + +Updating a Package Repository +----------------------------- + +Administrators can update the Package Repository attributes using the following +command::: + + $ maas package-repository update + +Deleting a Package Repository +----------------------------- + +Administrators can delete a Package Repository using the following command::: + + $ maas package-repository delete + +Getting Help +------------ + +Online help is available for all API's in MAAS. For example::: + + $ maas package-repository --help + $ maas package-repository --help + + $ maas package-repositories --help + $ maas package-repositories --help diff -Nru maas-2.0.0+bzr5189/docs/sstreams-mirror.rst maas-2.1.1+bzr5544/docs/sstreams-mirror.rst --- maas-2.0.0+bzr5189/docs/sstreams-mirror.rst 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/sstreams-mirror.rst 2016-11-08 19:56:20.000000000 +0000 @@ -12,16 +12,22 @@ $ sudo apt-get install simplestreams ubuntu-cloudimage-keyring apache2 Now you can pull the images over using the mirroring tools for simplestreams. -This example gets the daily trusty (14.04) and precise (12.04) images for the -amd64/generic and amd64/hwe-t architectures:: +This example gets the daily trusty (14.04) and xenial (16.04) images for the +amd64 architecture:: - $ sudo sstream-mirror --keyring=/usr/share/keyrings/ubuntu-cloudimage-keyring.gpg https://images.maas.io/ephemeral-v2/daily/ /var/www/html/maas/images/ephemeral-v2/daily 'arch=amd64' 'subarch~(generic|hwe-t)' 'release~(trusty|precise)' --max=1 + $ sudo sstream-mirror --keyring=/usr/share/keyrings/ubuntu-cloudimage-keyring.gpg https://images.maas.io/ephemeral-v3/daily/ /var/www/html/maas/images/ephemeral-v3/daily 'arch=amd64' 'release~(trusty|xenial)' --max=1 This may take a while as hundreds of megabytes will be downloaded. +As of MAAS 2.1 bootloaders are now included in the simplestream. In order for +MAAS to work bootloaders must be mirrored as well. It is recommended that all +bootloaders are mirrored:: + + $ sudo sstream-mirror --keyring=/usr/share/keyrings/ubuntu-cloudimage-keyring.gpg https://images.maas.io/ephemeral-v3/daily/ /var/www/html/maas/images/ephemeral-v3/daily 'os~(grub*|pxelinux)' --max=1 + The images will be written to the local disk and you can verify their presence by browsing to -``http:///maas/images/ephemeral-v2/daily/streams/v1/index.sjson`` +``http:///maas/images/ephemeral-v3/daily/streams/v1/index.sjson`` (replace ```` with your own server's name). It is a good idea to configure a ``cron`` job to repeat this import on a @@ -35,13 +41,13 @@ can use the ``maas`` (see :doc:`maascli`) command, logged in as the admin user:: - $ maas boot-sources create url=http:///images/ephemeral-v2/daily/ keyring_filename=/usr/share/keyrings/ubuntu-cloudimage-keyring.gpg + $ maas boot-sources create url=http:///images/ephemeral-v3/daily/ keyring_filename=/usr/share/keyrings/ubuntu-cloudimage-keyring.gpg Note that if you wish to use older images (which change far less frequently, but will be lacking security updates), you can use the ``releases`` stream, such as:: - $ maas boot-sources create url=http:///images/ephemeral-v2/releases/ keyring_filename=/usr/share/keyrings/ubuntu-cloudimage-keyring.gpg + $ maas boot-sources create url=http:///images/ephemeral-v3/releases/ keyring_filename=/usr/share/keyrings/ubuntu-cloudimage-keyring.gpg And then initiate the download with:: diff -Nru maas-2.0.0+bzr5189/docs/_templates/maas/layout.html maas-2.1.1+bzr5544/docs/_templates/maas/layout.html --- maas-2.0.0+bzr5189/docs/_templates/maas/layout.html 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/docs/_templates/maas/layout.html 2016-11-08 19:56:20.000000000 +0000 @@ -1,6 +1,15 @@ {%- extends "basic/layout.html" %} {% set css_files = ['https://assets.ubuntu.com/sites/guidelines/css/latest/ubuntu-styles.css', 'https://assets.ubuntu.com/sites/ubuntu/latest/u/css/global.css', '_static/css/main.css'] %} +{% block rootrellink %} + + +{% endblock %} + {% block sidebarlogo %} MAAS logo

MAAS

diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_api_helper.py maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_api_helper.py --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_api_helper.py 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_api_helper.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,111 +0,0 @@ -from email.utils import parsedate -import sys -import time -import urllib.error -import urllib.parse -import urllib.request - -import oauthlib.oauth1 as oauth -import yaml - - -__all__ = [ - 'geturl', - 'read_config', - ] - - -def read_config(url, creds): - """Read cloud-init config from given `url` into `creds` dict. - - Updates any keys in `creds` that are None with their corresponding - values in the config. - - Important keys include `metadata_url`, and the actual OAuth - credentials. - """ - if url.startswith("http://") or url.startswith("https://"): - cfg_str = urllib.request.urlopen(urllib.request.Request(url=url)) - else: - if url.startswith("file://"): - url = url[7:] - cfg_str = open(url, "r").read() - - cfg = yaml.safe_load(cfg_str) - - # Support reading cloud-init config for MAAS datasource. - if 'datasource' in cfg: - cfg = cfg['datasource']['MAAS'] - - for key in creds.keys(): - if key in cfg and creds[key] is None: - creds[key] = cfg[key] - - -def oauth_headers(url, consumer_key, token_key, token_secret, consumer_secret, - clockskew=0): - """Build OAuth headers using given credentials.""" - timestamp = int(time.time()) + clockskew - client = oauth.Client( - consumer_key, - client_secret=consumer_secret, - resource_owner_key=token_key, - resource_owner_secret=token_secret, - signature_method=oauth.SIGNATURE_PLAINTEXT, - timestamp=str(timestamp)) - uri, signed_headers, body = client.sign(url) - return signed_headers - - -def authenticate_headers(url, headers, creds, clockskew): - """Update and sign a dict of request headers.""" - if creds.get('consumer_key', None) is not None: - headers.update(oauth_headers( - url, - consumer_key=creds['consumer_key'], - token_key=creds['token_key'], - token_secret=creds['token_secret'], - consumer_secret=creds['consumer_secret'], - clockskew=clockskew)) - - -def warn(msg): - sys.stderr.write(msg + "\n") - - -def geturl(url, creds, headers=None, data=None): - # Takes a dict of creds to be passed through to oauth_headers, - # so it should have consumer_key, token_key, ... - if headers is None: - headers = {} - else: - headers = dict(headers) - - clockskew = 0 - - error = Exception("Unexpected Error") - for naptime in (1, 1, 2, 4, 8, 16, 32): - authenticate_headers(url, headers, creds, clockskew) - try: - req = urllib.request.Request(url=url, data=data, headers=headers) - return urllib.request.urlopen(req).read() - except urllib.error.HTTPError as exc: - error = exc - if 'date' not in exc.headers: - warn("date field not in %d headers" % exc.code) - pass - elif exc.code in (401, 403): - date = exc.headers['date'] - try: - ret_time = time.mktime(parsedate(date)) - clockskew = int(ret_time - time.time()) - warn("updated clock skew to %d" % clockskew) - except: - warn("failed to convert date '%s'" % date) - except Exception as exc: - error = exc - - warn("request to %s failed. sleeping %d.: %s" % (url, naptime, error)) - time.sleep(naptime) - - raise error diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_enlist.sh maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_enlist.sh --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_enlist.sh 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_enlist.sh 1970-01-01 00:00:00.000000000 +0000 @@ -1,231 +0,0 @@ -#!/bin/sh -# -# maas-enlist: MAAS Enlistment Tool -# -# Copyright (C) 2014-2016 Canonical Ltd. -# -# Authors: Andres Rodriguez -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, version 3 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -get_mac_addresses() { - local macs - local pxe_mac - local mac_addresses - macs=`ip addr | egrep 'link/ether' | cut -d' ' -f6` - # Obtain the BOOTIF MAC address from the kernel command line. - # Note that BOOTIF stores the MAC in the format of - # '01-AA-BB-CC-DD-EE-FF", or "01-AA:BB:CC:DD:EE:FF", - # and we remove the '01-'. - pxe_mac=`cat /proc/cmdline | egrep 'BOOTIF=' | sed -e 's/.*[[:space:]]BOOTIF=\([-:0-9A-Fa-f]\+\).*/\1/g' -e 's,^01-,,g' -e 's,-,:,g'` - # Initialize the mac_address variable with "$pxe_mac", - # otherwise "$pxe_mac" will be empty. - mac_addresses="$pxe_mac" - - for mac in $macs; - do - # We only add more mac's if "$mac" is different - # from "$pxe_mac" - if [ "$mac" != "$pxe_mac" ]; then - if [ -z "$mac_addresses" ]; then - mac_addresses="$mac" - else - mac_addresses="$mac_addresses,$mac" - fi - fi - done - echo "$mac_addresses" -} - -get_mac_address_by_interface() { - iface="$1" - mac=`ip addr sh "$iface" | egrep -m1 'link/ether' | cut -d' ' -f6` - echo "$mac" -} - -get_mac_address_curl_parms() { - local args="" input_string="$1" - OIFS=$IFS; IFS=","; set -- $input_string; IFS=$OIFS - for i in "$@"; - do - args="${args} --data-urlencode mac_addresses=${i}" - #mac_address="$mac_address""&mac_addresses=""${i}"; - done - echo "${args# }" -} - -get_host_architecture() { - if grep "flags" /proc/cpuinfo | grep -qs "\ lm\ "; then - # if /proc/cpuinfo Flags has 'lm', it is x86_64 - arch="amd64" - else - arch=`archdetect | cut -d'/' -f1` - fi - echo "$arch" -} - -get_host_subarchitecture() { - local arch=$1 - case $arch in - i386|amd64|arm64|ppc64el) - # Skip the call to archdetect as that's what - # get_host_architecture does - echo generic - ;; - *) - archdetect | cut -d'/' -f2 - ;; - esac -} - -get_server_name() { - local servername="$1"; - _RET=${servername#*://}; - _RET=${_RET%%/*}; - echo "$_RET"; -} - -enlist_node() { - serverurl="${1}" - mac="${2}" - arch="${3}" - subarch="${4}" - hostname="${5}" - power_type="${6}" - power_params="${7}" - - local macparms="" - macparms=$(get_mac_address_curl_parms "$mac") - - curl \ - --fail \ - --header "Accept: application/json" \ - --data-urlencode "hostname=${hostname}" \ - --data-urlencode "architecture=${arch}" \ - --data-urlencode "subarchitecture=${subarch}" \ - --data-urlencode "power_type=${power_type}" \ - --data-urlencode "power_parameters=${power_params}" \ - ${macparms} \ - "${serverurl}" - -} - -Error () { - echo "ERROR: $1" - exit 1 -} - -Usage() { - cat <&2; [ $# -eq 0 ] || Error "$@"; exit 1; } - -short_opts="hs:n:i:a:t:p:" -long_opts="help,serverurl:,hostname:,interface:,arch:,subarch:,power-type:,power-params:" -getopt_out=$(getopt --name "${0##*/}" \ - --options "${short_opts}" --long "${long_opts}" -- "$@") && - eval set -- "${getopt_out}" || - bad_Usage - -while [ $# -ne 0 ]; do - cur=${1}; next=${2}; - case "$cur" in - -h|--help) Usage ; exit 0;; - -s|--serverurl) serverurl=${2}; shift;; - -n|--hostname) hostname=${2}; shift;; - -i|--interface) iface=${2}; shift;; - -a|--arch) arch=${2}; shift;; - --subarch) subarch=${2}; shift;; - -t|--power-type) power_type=${2}; shift;; - -p|--power-params) power_parameters=${2}; shift;; - --) shift; break;; - esac - shift; -done - -## check arguments here -#[ $# -eq 0 ] && bad_Usage - -# If no interface is specified. obtain the MAC from all interfaces -if [ -z "$iface" ]; then - mac_addrs=$(get_mac_addresses) -else - mac_addrs=$(get_mac_address_by_interface "$iface") -fi - -protocol= -servername=$(get_server_name "$serverurl") -if echo "$serverurl" | egrep -q '^[a-z]+://' ; then - protocol=`echo "$serverurl" | sed 's#^\([a-z]\+\)://.*#\\1#'` -else - protocol="http" -fi - -if [ "$protocol" != "http" ] && [ "$protocol" != "https" ]; then - Error "Invalid protocol '$protocol'" -fi - -if [ -z "$servername" ]; then - serverurl="maas.local" - servername="$serverurl" -fi -if echo "$serverurl" | egrep -q '(^[a-z]+://|^)[a-z0-9\.\-]+($|/$)'; then - api_url="MAAS/api/2.0/machines/" -else - api_url=`echo $serverurl | sed 's#^\(\|[a-z]\+://\)[a-zA-Z0-9\.\-]\+\(\|\:[0-9]\+\)/##'` -fi - -#TODO: Auto-detect hostname? -if [ -z "$hostname" ]; then - continue - #Error "No hostname has been provided" -fi - -if [ -z "$arch" ]; then - arch=$(get_host_architecture) -fi - -if [ -z "$subarch" ]; then - subarch=$(get_host_subarchitecture $arch) -fi - -if [ -n "$power_type" ]; then - case $power_type in - ipmi) continue ;; - virsh) continue ;; - etherwake) continue ;; - moonshot) continue ;; - *) Error "Invalid power type: [$power_type]" - esac -fi - -enlist_node "$protocol://$servername/$api_url" "${mac_addrs}" "$arch" "$subarch" "$hostname" "$power_type" "$power_parameters" diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_get.py maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_get.py --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_get.py 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_get.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,47 +0,0 @@ -#!/usr/bin/python3 - -import sys - -from maas_api_helper import ( - geturl, - read_config, -) - - -MD_VERSION = "2012-03-01" - - -def main(): - """Authenticate, and download file from MAAS metadata API.""" - import argparse - - parser = argparse.ArgumentParser( - description="GET file from MAAS metadata API.") - parser.add_argument( - "--config", metavar="file", - help="Config file containing MAAS API credentials", default=None) - parser.add_argument( - "--apiver", metavar="version", help="Use given API version", - default=MD_VERSION) - parser.add_argument('path') - - args = parser.parse_args() - - creds = { - 'consumer_key': None, - 'token_key': None, - 'token_secret': None, - 'consumer_secret': '', - 'metadata_url': None, - } - read_config(args.config, creds) - url = "%s/%s/%s" % ( - creds['metadata_url'], - args.apiver, - args.path, - ) - - sys.stdout.buffer.write(geturl(url, creds)) - -if __name__ == '__main__': - main() diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect.py maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect.py --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect.py 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,306 +0,0 @@ -#!/usr/bin/python3 -# -# maas-ipmi-autodetect - autodetect and autoconfigure IPMI. -# -# Copyright (C) 2013-2016 Canonical -# -# Authors: -# Andres Rodriguez -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, version 3 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . - -from collections import OrderedDict -import json -import os -import platform -import random -import re -import string -import subprocess -import time - - -class IPMIError(Exception): - """An error related to IPMI.""" - - -def run_command(command_args): - """Run a command. Return output if successful or raise exception if not.""" - output = subprocess.check_output(command_args, stderr=subprocess.STDOUT) - return output.decode('utf-8') - - -def bmc_get(key): - """Fetch the output of a key via bmc-config checkout.""" - command = ('bmc-config', '--checkout', '--key-pair=%s' % key) - output = run_command(command) - return output - - -def bmc_set(key, value): - """Set the value of a key via bmc-config commit.""" - command = ('bmc-config', '--commit', '--key-pair=%s=%s' % (key, value)) - run_command(command) - - -def format_user_key(user_number, parameter): - """Format a user key string.""" - return '%s:%s' % (user_number, parameter) - - -def bmc_user_get(user_number, parameter): - """Get a user parameter via bmc-config commit.""" - key = format_user_key(user_number, parameter) - raw = bmc_get(key) - pattern = r'^\s*%s(?:[ \t])+([^#\s]+[^\n]*)$' % (re.escape(parameter)) - match = re.search(pattern, raw, re.MULTILINE) - if match is None: - return None - return match.group(1) - - -def bmc_user_set(user_number, parameter, value): - """Set a user parameter via bmc-config commit.""" - key = format_user_key(user_number, parameter) - bmc_set(key, value) - - -def bmc_list_sections(): - """Retrieve the names of config sections from the BMC.""" - command = ('bmc-config', '-L') - output = run_command(command) - return output - - -def list_user_numbers(): - """List the user numbers on the BMC.""" - output = bmc_list_sections() - pattern = r'^(User\d+)$' - users = re.findall(pattern, output, re.MULTILINE) - - return users - - -def pick_user_number_from_list(search_username, user_numbers): - """Pick the best user number for a user from a list of user numbers. - - If any any existing user's username matches the search username, pick - that user. - - Otherwise, pick the first user that has no username set. - - If no users match those criteria, raise an IPMIError. - """ - first_unused = None - - for user_number in user_numbers: - # The IPMI spec reserves User1 as anonymous. - if user_number == 'User1': - continue - - username = bmc_user_get(user_number, 'Username') - - if username == search_username: - return user_number - - # Usually a BMC won't include a Username value if the user is unused. - # Some HP BMCs use "(Empty User)" to indicate a user in unused. - if username in [None, '(Empty User)'] and first_unused is None: - first_unused = user_number - - return first_unused - - -def pick_user_number(search_username): - """Pick the best user number for a username.""" - user_numbers = list_user_numbers() - user_number = pick_user_number_from_list(search_username, user_numbers) - - if not user_number: - raise IPMIError('No IPMI user slots available.') - - return user_number - - -def is_ipmi_dhcp(): - output = bmc_get('Lan_Conf:IP_Address_Source') - show_re = re.compile('IP_Address_Source\s+Use_DHCP') - return show_re.search(output) is not None - - -def set_ipmi_network_source(source): - bmc_set('Lan_Conf:IP_Address_Source', source) - - -def get_ipmi_ip_address(): - output = bmc_get('Lan_Conf:IP_Address') - show_re = re.compile('([0-9]{1,3}[.]?){4}') - res = show_re.search(output) - return res.group() - - -def verify_ipmi_user_settings(user_number, user_settings): - """Verify user settings were applied correctly.""" - - bad_values = {} - - for key, expected_value in user_settings.items(): - # Password isn't included in checkout. Plus, - # some older BMCs may not support Enable_User. - if key not in ['Enable_User', 'Password']: - value = bmc_user_get(user_number, key) - if value != expected_value: - bad_values[key] = value - - if len(bad_values) == 0: - return - - errors_string = ' '.join([ - "for '%s', expected '%s', actual '%s';" % ( - key, user_settings[key], actual_value) - for key, actual_value in bad_values.items() - ]).rstrip(';') - message = "IPMI user setting verification failures: %s." % (errors_string) - raise IPMIError(message) - - -def apply_ipmi_user_settings(user_settings): - """Commit and verify IPMI user settings.""" - username = user_settings['Username'] - ipmi_user_number = pick_user_number(username) - - for key, value in user_settings.items(): - bmc_user_set(ipmi_user_number, key, value) - - verify_ipmi_user_settings(ipmi_user_number, user_settings) - - -def make_ipmi_user_settings(username, password): - """Factory for IPMI user settings.""" - # Some BMCs care about the order these settings are applied in. - # - # - Dell Poweredge R420 Systems require the username and password to - # be set prior to the user being enabled. - # - # - Supermicro systems require the LAN Privilege Limit to be set - # prior to enabling LAN IPMI msgs for the user. - user_settings = OrderedDict(( - ('Username', username), - ('Password', password), - ('Enable_User', 'Yes'), - ('Lan_Privilege_Limit', 'Administrator'), - ('Lan_Enable_IPMI_Msgs', 'Yes'), - )) - return user_settings - - -def configure_ipmi_user(username, password): - """Create or configure an IPMI user for remote use.""" - user_settings = make_ipmi_user_settings(username, password) - apply_ipmi_user_settings(user_settings) - - -def commit_ipmi_settings(config): - run_command(('bmc-config', '--commit', '--filename', config)) - - -def get_maas_power_settings(user, password, ipaddress, version): - return "%s,%s,%s,%s" % (user, password, ipaddress, version) - - -def get_maas_power_settings_json(user, password, ipaddress, version): - power_params = { - "power_address": ipaddress, - "power_pass": password, - "power_user": user, - "power_driver": version, - } - return json.dumps(power_params) - - -def generate_random_password(min_length=8, max_length=15): - length = random.randint(min_length, max_length) - letters = string.ascii_letters + string.digits - return ''.join([random.choice(letters) for _ in range(length)]) - - -def bmc_supports_lan2_0(): - """Detect if BMC supports LAN 2.0.""" - output = run_command(('ipmi-locate')) - if 'IPMI Version: 2.0' in output or platform.machine() == 'ppc64le': - return True - return False - - -def main(): - import argparse - - parser = argparse.ArgumentParser( - description='send config file to modify IPMI settings with') - parser.add_argument( - "--configdir", metavar="folder", help="specify config file directory", - default=None) - parser.add_argument( - "--dhcp-if-static", action="store_true", dest="dhcp", - help="set network source to DHCP if Static", default=False) - parser.add_argument( - "--commission-creds", action="store_true", dest="commission_creds", - help="Create IPMI temporary credentials", default=False) - - args = parser.parse_args() - - # Check whether IPMI is being set to DHCP. If it is not, and - # '--dhcp-if-static' has been passed, Set it to IPMI to DHCP. - if not is_ipmi_dhcp() and args.dhcp: - set_ipmi_network_source("Use_DHCP") - # allow IPMI 120 seconds to obtain an IP address - time.sleep(120) - # create user/pass - IPMI_MAAS_USER = "maas" - IPMI_MAAS_PASSWORD = generate_random_password() - - configure_ipmi_user(IPMI_MAAS_USER, IPMI_MAAS_PASSWORD) - - # Commit other IPMI settings - if args.configdir: - for file in os.listdir(args.configdir): - commit_ipmi_settings(os.path.join(args.configdir, file)) - - # get the IP address - IPMI_IP_ADDRESS = get_ipmi_ip_address() - if IPMI_IP_ADDRESS == "0.0.0.0": - # if IPMI_IP_ADDRESS is 0.0.0.0, wait 60 seconds and retry. - set_ipmi_network_source("Static") - time.sleep(2) - set_ipmi_network_source("Use_DHCP") - time.sleep(60) - IPMI_IP_ADDRESS = get_ipmi_ip_address() - - if IPMI_IP_ADDRESS is None or IPMI_IP_ADDRESS == "0.0.0.0": - # Exit (to not set power params in MAAS) if no IPMI_IP_ADDRESS - # has been detected - exit(1) - - if bmc_supports_lan2_0(): - IPMI_VERSION = "LAN_2_0" - else: - IPMI_VERSION = "LAN" - if args.commission_creds: - print(get_maas_power_settings_json( - IPMI_MAAS_USER, IPMI_MAAS_PASSWORD, IPMI_IP_ADDRESS, IPMI_VERSION)) - else: - print(get_maas_power_settings( - IPMI_MAAS_USER, IPMI_MAAS_PASSWORD, IPMI_IP_ADDRESS, IPMI_VERSION)) - -if __name__ == '__main__': - main() diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect_tool.py maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect_tool.py --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect_tool.py 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect_tool.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,49 +0,0 @@ -#!/usr/bin/python3 - -import glob -import re -import subprocess - - -def detect_ipmi(): - # XXX: andreserl 2013-04-09 bug=1064527: Try to detect if node - # is a Virtual Machine. If it is, do not try to detect IPMI. - with open('/proc/cpuinfo', 'r') as cpuinfo: - for line in cpuinfo: - if line.startswith('model name') and 'QEMU' in line: - return (False, None) - - (status, output) = subprocess.getstatusoutput('ipmi-locate') - show_re = re.compile('(IPMI\ Version:) (\d\.\d)') - res = show_re.search(output) - if res is None: - found = glob.glob("/dev/ipmi[0-9]") - if len(found): - return (True, "UNKNOWN: %s" % " ".join(found)) - return (False, "") - return (True, res.group(2)) - - -def is_host_moonshot(): - output = subprocess.check_output(['ipmitool', 'raw', '06', '01']) - # 14 is the code that identifies a machine as a moonshot - if output.split()[0] == "14": - return True - return False - - -def main(): - # Check whether IPMI exists or not. - (status, ipmi_version) = detect_ipmi() - if not status: - # if False, then failed to detect ipmi - exit(1) - - if is_host_moonshot(): - print("moonshot") - else: - print("ipmi") - - -if __name__ == '__main__': - main() diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_moonshot_autodetect.py maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_moonshot_autodetect.py --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_moonshot_autodetect.py 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_moonshot_autodetect.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,98 +0,0 @@ -#!/usr/bin/python3 - -import argparse -import json -import re -import subprocess - - -IPMI_MAAS_USER = 'Administrator' -IPMI_MAAS_PASSWORD = 'password' - - -def get_local_address(): - output = subprocess.getoutput('ipmitool raw 0x2c 1 0') - return "0x%s" % output.split()[2] - - -def get_cartridge_address(local_address): - # obtain address of Cartridge Controller (parent of the system node): - output = subprocess.getoutput( - 'ipmitool -t 0x20 -b 0 -m %s raw 0x2c 1 0' % local_address) - return "0x%s" % output.split()[2] - - -def get_channel_number(address, output): - # channel number (routing to this system node) - show = re.compile( - r'Device Slave Address\s+:\s+%sh(.*?)Channel Number\s+:\s+\d+' - % address.replace('0x', '').upper(), - re.DOTALL) - res = show.search(output) - return res.group(0).split()[-1] - - -def get_ipmi_ip_address(local_address): - output = subprocess.getoutput( - 'ipmitool -B 0 -T 0x20 -b 0 -t 0x20 -m %s lan print 2' % local_address) - show_re = re.compile('IP Address\s+:\s+([0-9]{1,3}[.]?){4}') - res = show_re.search(output) - return res.group().split()[-1] - - -def get_maas_power_settings(user, password, ipaddress, hwaddress): - return "%s,%s,%s,%s" % (user, password, ipaddress, hwaddress) - - -def get_maas_power_settings_json(user, password, ipaddress, hwaddress): - power_params = { - "power_address": ipaddress, - "power_pass": password, - "power_user": user, - "power_hwaddress": hwaddress, - } - return json.dumps(power_params) - - -def main(): - parser = argparse.ArgumentParser( - description='send config file to modify IPMI settings with') - parser.add_argument( - "--commission-creds", action="store_true", dest="commission_creds", - help="Create IPMI temporary credentials", default=False) - - args = parser.parse_args() - - local_address = get_local_address() - node_address = get_cartridge_address(local_address) - - # Obtaining channel numbers: - output = subprocess.getoutput( - 'ipmitool -b 0 -t 0x20 -m %s sdr list mcloc -v' % local_address) - - local_chan = get_channel_number(local_address, output) - cartridge_chan = get_channel_number(node_address, output) - - # ipmitool -I lanplus -H 10.16.1.11 -U Administrator -P password -B 0 - # -T 0x88 -b 7 -t 0x72 -m 0x20 power status - IPMI_HW_ADDRESS = "-B %s -T %s -b %s -t %s -m 0x20" % ( - cartridge_chan, - node_address, - local_chan, - local_address, - ) - - IPMI_IP_ADDRESS = get_ipmi_ip_address(local_address) - - if args.commission_creds: - print(get_maas_power_settings_json( - IPMI_MAAS_USER, IPMI_MAAS_PASSWORD, IPMI_IP_ADDRESS, - IPMI_HW_ADDRESS)) - else: - print(get_maas_power_settings( - IPMI_MAAS_USER, IPMI_MAAS_PASSWORD, IPMI_IP_ADDRESS, - IPMI_HW_ADDRESS)) - - -if __name__ == '__main__': - main() diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_signal.py maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_signal.py --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/maas_signal.py 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/maas_signal.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,237 +0,0 @@ -#!/usr/bin/python3 - -import json -import mimetypes -import os.path -import random -import socket -import string -import sys -import urllib.error -import urllib.parse -import urllib.request - -from maas_api_helper import ( - geturl, - read_config, -) - - -MD_VERSION = "2012-03-01" -VALID_STATUS = ("OK", "FAILED", "WORKING") -POWER_TYPES = ("ipmi", "virsh", "manual", "moonshot") - - -def _encode_field(field_name, data, boundary): - assert isinstance(field_name, bytes) - assert isinstance(data, bytes) - assert isinstance(boundary, bytes) - return ( - b'--' + boundary, - b'Content-Disposition: form-data; name=\"' + field_name + b'\"', - b'', data, - ) - - -def _encode_file(name, fileObj, boundary): - assert isinstance(name, str) - assert isinstance(boundary, bytes) - byte_name = name.encode("utf-8") - return ( - b'--' + boundary, - ( - b'Content-Disposition: form-data; name=\"' + byte_name + b'\"; ' + - b'filename=\"' + byte_name + b'\"' - ), - b'Content-Type: ' + _get_content_type(name).encode("utf-8"), - b'', - fileObj.read(), - ) - - -def _random_string(length): - return b''.join( - random.choice(string.ascii_letters).encode("ascii") - for ii in range(length + 1) - ) - - -def _get_content_type(filename): - return mimetypes.guess_type(filename)[0] or 'application/octet-stream' - - -def encode_multipart_data(data, files): - """Create a MIME multipart payload from L{data} and L{files}. - - @param data: A mapping of names (ASCII strings) to data (byte string). - @param files: A mapping of names (ASCII strings) to file objects ready to - be read. - @return: A 2-tuple of C{(body, headers)}, where C{body} is a a byte string - and C{headers} is a dict of headers to add to the enclosing request in - which this payload will travel. - """ - boundary = _random_string(30) - - lines = [] - for name in data: - lines.extend(_encode_field(name, data[name], boundary)) - for name in files: - lines.extend(_encode_file(name, files[name], boundary)) - lines.extend((b'--' + boundary + b'--', b'')) - body = b'\r\n'.join(lines) - - headers = { - 'Content-Type': ( - 'multipart/form-data; boundary=' + boundary.decode("ascii")), - 'Content-Length': str(len(body)), - } - - return body, headers - - -def fail(msg): - sys.stderr.write("FAIL: %s" % msg) - sys.exit(1) - - -def main(): - """ - Call with single argument of directory or http or https url. - If url is given additional arguments are allowed, which will be - interpreted as consumer_key, token_key, token_secret, consumer_secret. - """ - import argparse - - parser = argparse.ArgumentParser( - description='Send signal operation and optionally post files to MAAS') - parser.add_argument( - "--config", metavar="file", help="Specify config file", default=None) - parser.add_argument( - "--ckey", metavar="key", help="The consumer key to auth with", - default=None) - parser.add_argument( - "--tkey", metavar="key", help="The token key to auth with", - default=None) - parser.add_argument( - "--csec", metavar="secret", help="The consumer secret (likely '')", - default="") - parser.add_argument( - "--tsec", metavar="secret", help="The token secret to auth with", - default=None) - parser.add_argument( - "--apiver", metavar="version", - help="The apiver to use (\"\" can be used)", default=MD_VERSION) - parser.add_argument( - "--url", metavar="url", help="The data source to query", default=None) - parser.add_argument( - "--file", dest='files', help="File to post", action='append', - default=[]) - parser.add_argument( - "--post", dest='posts', help="name=value pairs to post", - action='append', default=[]) - parser.add_argument( - "--power-type", dest='power_type', help="Power type.", - choices=POWER_TYPES, default=None) - parser.add_argument( - "--power-parameters", dest='power_parms', help="Power parameters.", - default=None) - parser.add_argument( - "--script-result", metavar="retval", type=int, dest='script_result', - help="Return code of a commissioning script.") - - parser.add_argument( - "status", help="Status", choices=VALID_STATUS, action='store') - parser.add_argument( - "message", help="Optional message", default="", nargs='?') - - args = parser.parse_args() - - creds = { - 'consumer_key': args.ckey, - 'token_key': args.tkey, - 'token_secret': args.tsec, - 'consumer_secret': args.csec, - 'metadata_url': args.url, - } - - if args.config: - read_config(args.config, creds) - - url = creds.get('metadata_url', None) - if not url: - fail("URL must be provided either in --url or in config\n") - url = "%s/%s/" % (url, args.apiver) - - params = { - b"op": b"signal", - b"status": args.status.encode("utf-8"), - b"error": args.message.encode("utf-8"), - } - - if args.script_result is not None: - params[b'script_result'] = str(args.script_result).encode("utf-8") - - for ent in args.posts: - try: - (key, val) = ent.split("=", 2) - except ValueError: - sys.stderr.write("'%s' had no '='" % ent) - sys.exit(1) - params[key.encode("utf-8")] = val.encode("utf-8") - - if args.power_parms is not None: - params[b"power_type"] = args.power_type.encode("utf-8") - if params[b"power_type"] == b"moonshot": - user, passwd, address, hwaddress = args.power_parms.split(",") - power_parms = dict( - power_user=user, - power_pass=passwd, - power_address=address, - power_hwaddress=hwaddress - ) - else: - user, passwd, address, driver = args.power_parms.split(",") - power_parms = dict( - power_user=user, - power_pass=passwd, - power_address=address, - power_driver=driver - ) - params[b"power_parameters"] = json.dumps(power_parms).encode() - - files = {} - for fpath in args.files: - files[os.path.basename(fpath)] = open(fpath, "rb") - - data, headers = encode_multipart_data(params, files) - - error = None - msg = "" - - try: - payload = geturl(url, creds=creds, headers=headers, data=data) - if payload != b"OK": - raise TypeError("Unexpected result from call: %s" % payload) - else: - msg = "Success" - except urllib.error.HTTPError as exc: - error = exc - msg = "http error [%s]" % exc.code - except urllib.error.URLError as exc: - error = exc - msg = "url error [%s]" % exc.reason - except socket.timeout as exc: - error = exc - msg = "socket timeout [%s]" % exc - except TypeError as exc: - error = exc - msg = str(exc) - except Exception as exc: - error = exc - msg = "unexpected error [%s]" % exc - - sys.stderr.write("%s\n" % msg) - sys.exit((error is None)) - -if __name__ == '__main__': - main() diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/tests/test_maas_ipmi_autodetect.py maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/tests/test_maas_ipmi_autodetect.py --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/snippets/tests/test_maas_ipmi_autodetect.py 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/snippets/tests/test_maas_ipmi_autodetect.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,491 +0,0 @@ -# Copyright 2014-2016 Canonical Ltd. This software is licensed under the -# GNU Affero General Public License version 3 (see the file LICENSE). - -"""Tests for maas_ipmi_autodetect.py.""" - -__all__ = [] - -from collections import OrderedDict -import platform -import subprocess -from unittest.mock import call - -from maastesting.factory import factory -from maastesting.matchers import ( - MockAnyCall, - MockCalledOnceWith, - MockCallsMatch, -) -from maastesting.testcase import MAASTestCase -from snippets import maas_ipmi_autodetect -from snippets.maas_ipmi_autodetect import ( - apply_ipmi_user_settings, - bmc_list_sections, - bmc_supports_lan2_0, - bmc_user_get, - commit_ipmi_settings, - configure_ipmi_user, - format_user_key, - IPMIError, - list_user_numbers, - make_ipmi_user_settings, - pick_user_number, - pick_user_number_from_list, - run_command, - verify_ipmi_user_settings, -) - - -class TestRunCommand(MAASTestCase): - """Tests for the run_command method.""" - - def test_output_returned(self): - """Ensure output from stdout/stderr is returned to caller.""" - - test_stdout = factory.make_string() - test_stderr = factory.make_string() - command = 'echo %s >&1 && echo %s >&2' % (test_stdout, test_stderr) - - output = run_command(['bash', '-c', command]) - - self.assertEqual( - [test_stdout, test_stderr], - output.split()) - - def test_exception_on_failure(self): - """"Failed commands should raise an exception.""" - - self.assertRaises(subprocess.CalledProcessError, run_command, 'false') - - -class TestFormatUserKey(MAASTestCase): - """Tests the format_user_key method.""" - - def test_format_user_key(self): - """Ensure user key strings are properly constructed.""" - - user = factory.make_string() - field = factory.make_string() - - user_key = format_user_key(user, field) - - expected = '%s:%s' % (user, field) - - self.assertEqual(expected, user_key) - - -class TestBMCKeyPairMethods(MAASTestCase): - """Tests for methods that use bmc-config --key-pair""" - - scenarios = [ - ('bmc_get', dict( - method_name='bmc_get', args=['Test:Key'], - key_pair_fmt='--key-pair=%s', direction='--checkout')), - ('bmc_set', dict( - method_name='bmc_set', args=['Test:Key', 'myval'], - key_pair_fmt='--key-pair=%s=%s', direction='--commit')), - ('bmc_user_get', dict( - method_name='bmc_user_get', args=['User10', 'Username'], - key_pair_fmt='--key-pair=%s:%s', direction='--checkout')), - ('bmc_user_set', dict( - method_name='bmc_user_set', args=['User10', 'Username', 'maas'], - key_pair_fmt='--key-pair=%s:%s=%s', direction='--commit')) - ] - - def test_runs_bmc_config(self): - """Ensure bmc-config is run properly.""" - - recorder = self.patch(maas_ipmi_autodetect, 'run_command') - recorder.return_value = 'foo' - - # Grab the method from the class module where it lives. - method = getattr(maas_ipmi_autodetect, self.method_name) - - method(*self.args) - - # Note that the fmt string must use positional argument specifiers - # if the order of appearance of args in the fmt string doesn't match - # the order of args to the method. - key_pair_string = self.key_pair_fmt % tuple(self.args) - - expected_args = ('bmc-config', self.direction, key_pair_string) - self.assertThat(recorder, MockCalledOnceWith(expected_args)) - - -class TestBMCListSections(MAASTestCase): - """Tests for bmc_list_sections().""" - - def test_bmc_list_sections(self): - """Ensure bmc-config is called with the correct args.""" - recorder = self.patch(maas_ipmi_autodetect, 'run_command') - bmc_list_sections() - self.assertThat(recorder, MockCalledOnceWith(('bmc-config', '-L'))) - - -class TestListUserNumbers(MAASTestCase): - """Tests for list_user_numbers().""" - - section_names = ( - "User1\n" - "User4\n" - "User3\n" - "User16\n" - "User7more\n" - "Userworld\n" - "Otherwise\n" - "4User5\n" - "4User\n" - "User\n" - "3" - ) - - def test_matching(self): - """Ensure only properly formatted User sections match.""" - self.patch(maas_ipmi_autodetect, - 'bmc_list_sections').return_value = self.section_names - expected = ['User1', 'User4', 'User3', 'User16'] - user_numbers = list_user_numbers() - self.assertEqual(expected, user_numbers) - - def test_empty(self): - """Ensure an empty list is handled correctly.""" - self.patch(maas_ipmi_autodetect, 'bmc_list_sections').return_value = '' - results = list_user_numbers() - self.assertEqual([], results) - - -class TestBMCUserGet(MAASTestCase): - """Tests for bmc_user_get().""" - - scenarios = [ - ('No Leading Space', dict( - text="Username Bob", key='Username', value='Bob')), - ('Normal line.', dict( - text="\tUsername\t\tJoe", key='Username', value='Joe')), - ('Leading space, not tab', dict( - text=" Enable_User\t\tNo", key='Enable_User', value='No')), - ('Multiple leading tabs', dict( - text="\t\tPassword\t\tPass", key='Password', value='Pass')), - ('Separating space, not tab', dict( - text="\tAnother Value", key='Another', value='Value')), - ('Gunk', dict( - text="\tCharacters\t,./;:'\"[]{}|\\`~!@$%^&*()-_+=", - key='Characters', value=",./;:'\"[]{}|\\`~!@$%^&*()-_+=")), - ('More than two words', dict( - text="\tThree\tWord Line", key='Three', value='Word Line')), - ('Blank line', dict( - text="", key='Key', value=None)), - ('Single word', dict( - text="\tNotMe", key='NotMe', value=None)), - ('Comment line', dict( - text="\t#Or Me", key='Key', value=None)), - ('Word followed by comment', dict( - text="\tMe #Neither", key='Key', value=None)), - ('Word followed by two spaces', dict( - text="\tMe ", key='Me', value=None)), - ('Two words followed by space', dict( - text="\tMe Two ", key='Me', value='Two ')), - ('One character value', dict( - text="\tMe T", key='Me', value='T')), - ] - - def test_matching(self): - """Ensure only properly formatted record lines match.""" - user_number = 'User2' - response = ( - "Section %s\n" - "%s\n" - "EndSection" - ) % (user_number, self.text) - - self.patch( - maas_ipmi_autodetect, 'bmc_get').return_value = response - - value = bmc_user_get(user_number, self.key) - self.assertEqual(self.value, value) - - -def make_user(update=None): - """Make a simple user record.""" - - base = {'Lan_Enable_IPMI_Msgs': 'No'} - - if update: - base.update(update) - - return base - - -def make_attributes(*attributes_update): - """Base user records with updates in an OrderedDict.""" - - attributes_template = { - 'User1': { - 'Enable_User': 'Yes' - }, - 'User2': { - 'Username': 'admin', - 'Enable_User': 'Yes' - } - } - - base = OrderedDict(attributes_template) - base.update(attributes_update) - - return base - - -class TestPickUserNumberFromList(MAASTestCase): - """Tests for pick_user_number_from_list().""" - - scenarios = [ - ('Empty user list', dict( - user_attributes={}, - expected=None)), - ('Existing MAAS user', dict( - user_attributes=make_attributes( - ('User4', make_user()), - ('User5', {'Username': 'maas'}) - ), - expected='User5')), - ('One blank user', dict( - user_attributes=make_attributes( - ('User7', make_user()), - ), - expected='User7')), - ('Multiple blank users', dict( - user_attributes=make_attributes( - ('User7', make_user()), - ('User8', make_user()), - ), - expected='User7')), - ('One not blank user', dict( - user_attributes=make_attributes( - ('User7', make_user({'Username': 'foo'})), - ), - expected=None)), - ('Username is (Empty User)', dict( - user_attributes=make_attributes( - ('User7', make_user({'Username': '(Empty User)'})), - ), - expected='User7')), - ('One enabled blank user', dict( - user_attributes=make_attributes( - ('User7', {'Enable_User': 'Yes'}), - ), - expected='User7')), - ('Skip User1', dict( - user_attributes=make_attributes( - ('User1', make_user()), - ), - expected=None)) - ] - - def bmc_user_get(self, user_number, parameter): - """Return mock user data.""" - return self.user_attributes[user_number].get(parameter) - - def test_user_choice(self): - """Ensure the correct user, if any, is chosen.""" - self.patch(maas_ipmi_autodetect, - 'bmc_user_get').side_effect = self.bmc_user_get - current_users = list(self.user_attributes.keys()) - user = pick_user_number_from_list('maas', current_users) - self.assertEqual(self.expected, user) - - -class TestPickUserNumber(MAASTestCase): - """Tests for pick_user_number().""" - - def test_pick_user_number(self): - """Ensure proper listing and selection of a user.""" - self.patch(maas_ipmi_autodetect, - 'list_user_numbers').return_value = ['User1', 'User2'] - self.patch(maas_ipmi_autodetect, - 'pick_user_number_from_list').return_value = 'User2' - user_number = pick_user_number('maas') - self.assertEqual('User2', user_number) - - def test_fail_raise_exception(self): - """Ensure an exception is raised if no acceptable user is found.""" - self.patch(maas_ipmi_autodetect, 'list_user_numbers').return_value = [] - self.assertRaises(IPMIError, pick_user_number, 'maas') - - -class TestVerifyIpmiUserSettings(MAASTestCase): - """Tests for verify_ipmi_user_settings().""" - - def test_fail_missing_key(self): - """Ensure missing settings cause raise an IPMIError.""" - key = 'Username' - value = factory.make_name('username') - expected_settings = {key: value} - self.patch(maas_ipmi_autodetect, 'bmc_user_get').return_value = None - ipmi_error = self.assertRaises(IPMIError, verify_ipmi_user_settings, - 'User2', expected_settings) - - expected_message = ( - "IPMI user setting verification failures: " - "for '%s', expected '%s', actual 'None'." - ) % (key, value) - self.assertEqual(expected_message, str(ipmi_error)) - - def test_fail_incorrect_keys(self): - """Ensure settings that don't match raise an IPMIError.""" - bad_settings = { - 'Enable_Bad': 'Yes', - 'Enable_Bad2': 'Yes', - } - good_settings = { - 'Enable_Good': 'No', - 'Enable_Good2': 'No', - } - - expected_settings = bad_settings.copy() - expected_settings.update(good_settings) - - self.patch(maas_ipmi_autodetect, 'bmc_user_get').return_value = 'No' - ipmi_error = self.assertRaises(IPMIError, verify_ipmi_user_settings, - 'User2', expected_settings) - - self.assertRegex( - str(ipmi_error), - r'^IPMI user setting verification failures: ') - - for setting, expected_value in bad_settings.items(): - expected_match = r"for '%s', expected '%s', actual 'No" % ( - setting, expected_value) - self.assertRegex(str(ipmi_error), expected_match) - - for setting in good_settings: - unexpected_match = r"for '%s'" % (setting) - self.assertNotRegexpMatches(str(ipmi_error), unexpected_match) - - def test_accept_some_missing_keys(self): - """Ensure no exception is raised if these keys are missing. - - Password and Enable_User are both missing on some systems so we - don't try to verify them. - """ - expected_settings = {'Password': 'bar', 'Enable_User': 'yes'} - value = verify_ipmi_user_settings('User2', expected_settings) - self.assertIsNone(value) - - -class TestApplyIpmiUserSettings(MAASTestCase): - """Tests for apply_ipmi_user_settings().""" - - def test_use_username(self): - """Ensure the username provided is used.""" - user_number = 'User2' - pun_mock = self.patch(maas_ipmi_autodetect, 'pick_user_number') - pun_mock.return_value = user_number - self.patch(maas_ipmi_autodetect, 'bmc_user_set') - self.patch(maas_ipmi_autodetect, 'verify_ipmi_user_settings') - username = 'foo' - apply_ipmi_user_settings({'Username': username}) - self.assertThat(pun_mock, MockCalledOnceWith(username)) - - def test_verify_user_settings(self): - """Ensure the user settings are committed and verified.""" - user_number = 'User2' - self.patch(maas_ipmi_autodetect, - 'pick_user_number').return_value = user_number - bus_mock = self.patch(maas_ipmi_autodetect, 'bmc_user_set') - vius_mock = self.patch(maas_ipmi_autodetect, - 'verify_ipmi_user_settings') - user_settings = {'Username': user_number, 'b': 2} - apply_ipmi_user_settings(user_settings) - - for key, value in user_settings.items(): - self.assertThat(bus_mock, MockAnyCall(user_number, key, value)) - - self.assertThat( - vius_mock, - MockCalledOnceWith(user_number, user_settings)) - - def test_preserves_settings_order(self): - """Ensure user settings are applied in order of iteration.""" - user_number = 'User2' - self.patch(maas_ipmi_autodetect, - 'pick_user_number').return_value = user_number - bus_mock = self.patch(maas_ipmi_autodetect, 'bmc_user_set') - self.patch(maas_ipmi_autodetect, 'verify_ipmi_user_settings') - user_settings = OrderedDict((('Username', 1), ('b', 2), ('c', 3))) - apply_ipmi_user_settings(user_settings) - expected_calls = ( - call(user_number, key, value) - for key, value in user_settings.items() - ) - self.assertThat(bus_mock, MockCallsMatch(*expected_calls)) - - -class TestMakeIPMIUserSettings(MAASTestCase): - """Tests for make_ipmi_user_settings().""" - - def test_settings_ordered_correctly(self): - """Ensure user settings are listed in the right order.""" - settings = make_ipmi_user_settings('user', 'pass') - expected = [ - 'Username', 'Password', 'Enable_User', - 'Lan_Privilege_Limit', 'Lan_Enable_IPMI_Msgs' - ] - self.assertEqual(expected, list(settings.keys())) - - def test_uses_username_and_password(self): - """Ensure username and password supplied are used.""" - username = 'user' - password = 'pass' - settings = make_ipmi_user_settings(username, password) - self.assertEqual(username, settings['Username']) - self.assertEqual(password, settings['Password']) - - -class TestConfigureIPMIUser(MAASTestCase): - """Tests for configure_ipmi_user().""" - - def test_preserves_setting_order(self): - """Ensure the order of user settings isn't modified.""" - expected = OrderedDict((('a', 1), ('b', 2), ('c', 3))) - self.patch(maas_ipmi_autodetect, - 'make_ipmi_user_settings').return_value = expected.copy() - recorder = self.patch(maas_ipmi_autodetect, 'apply_ipmi_user_settings') - configure_ipmi_user('DC', 'DC') - self.assertThat(recorder, MockCalledOnceWith(expected)) - - -class TestCommitIPMISettings(MAASTestCase): - """Test commit_ipmi_settings().""" - - def test_commit_ipmi_settings(self): - """Ensure bmc-config is run properly.""" - recorder = self.patch(maas_ipmi_autodetect, 'run_command') - filename = 'foo' - commit_ipmi_settings(filename) - self.assertThat(recorder, MockCalledOnceWith( - ('bmc-config', '--commit', '--filename', filename))) - - -class TestBMCSupportsLANPlus(MAASTestCase): - """Tests for bmc_supports_lan2_0().""" - - scenarios = [ - ('Supports LAN 2.0', dict(output='IPMI Version: 2.0', support=True)), - ('Supports LAN 1.5', dict(output='IPMI Version: 1.5', support=False)), - ] - - def test_support_detection(self): - """Test for positive and negative matches.""" - run_command = self.patch(maas_ipmi_autodetect, 'run_command') - run_command.return_value = self.output - detected = bmc_supports_lan2_0() - self.assertEqual(self.support, detected) - - def test_support_detection_ppc64el(self): - """Test that ppc64el returns 2.0""" - run_command = self.patch(maas_ipmi_autodetect, 'run_command') - run_command.return_value = '' - ppc64le_platform = self.patch(platform, 'machine') - ppc64le_platform.return_value = 'ppc64le' - detected = bmc_supports_lan2_0() - self.assertEqual(True, detected) diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/user_data_config.template maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/user_data_config.template --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/user_data_config.template 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/user_data_config.template 1970-01-01 00:00:00.000000000 +0000 @@ -1,17 +0,0 @@ -#cloud-config -system_info: - package_mirrors: - - arches: [i386, amd64] - search: - primary: ["http://{{main_archive_hostname}}/{{main_archive_directory}}"] - security: ["http://{{main_archive_hostname}}/{{main_archive_directory}}"] - failsafe: - primary: "http://archive.ubuntu.com/ubuntu" - security: "http://security.ubuntu.com/ubuntu" - - arches: [default] - search: - primary: ["http://{{ports_archive_hostname}}/{{ports_archive_directory}}"] - security: ["http://{{ports_archive_hostname}}/{{ports_archive_directory}}"] - failsafe: - primary: "http://ports.ubuntu.com/ubuntu-ports" - security: "http://ports.ubuntu.com/ubuntu-ports" diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/user_data_disk_erasing.template maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/user_data_disk_erasing.template --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/user_data_disk_erasing.template 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/user_data_disk_erasing.template 1970-01-01 00:00:00.000000000 +0000 @@ -1,128 +0,0 @@ -#!/bin/sh -# -# This script carries inside it multiple files. When executed, it creates -# the files into a temporary directory, then uses them to report status -# back to MAAS. - -#### script setup ###### -TEMP_D=$(mktemp -d "${TMPDIR:-/tmp}/${0##*/}.XXXXXX") -BIN_D="${TEMP_D}/bin" -OUT_D="${TEMP_D}/out" -PATH="$BIN_D:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" -trap cleanup EXIT - -mkdir -p "$BIN_D" "$OUT_D" - -# Ensure that invocations of apt-get are not interactive by default, -# here and in all subprocesses. -export DEBIAN_FRONTEND=noninteractive - -### some utility functions #### -aptget() { - apt-get --assume-yes -q "$@" "${BIN_D}/$1" - chmod "${2:-755}" "${BIN_D}/$1" -} - -cleanup() { - [ -n "${TEMP_D}" ] || rm -Rf "${TEMP_D}" -} - -find_creds_cfg() { - local config="" file="" found="" - - # If the config location is set in environment variable, trust it. - [ -n "${COMMISSIONING_CREDENTIALS_URL}" ] && - _RET="${COMMISSIONING_CREDENTIALS_URL}" && return - - # Go looking for local files written by cloud-init. - for file in /etc/cloud/cloud.cfg.d/*cmdline*.cfg; do - [ -f "$file" ] && _RET="$file" && return - done - - local opt="" cmdline="" - if [ -f /proc/cmdline ] && read cmdline < /proc/cmdline; then - # Search through /proc/cmdline arguments: - # cloud-config-url trumps url= - for opt in $cmdline; do - case "$opt" in - url=*) - found=${opt#url=};; - cloud-config-url=*) - _RET="${opt#*=}" - return 0;; - esac - done - [ -n "$found" ] && _RET="$found" && return 0 - fi - return 1 -} - -# Invoke the "signal()" API call to report progress. -# Usage: signal -signal() { - maas-signal "--config=${CRED_CFG}" "$@" -} - -fail() { - [ -z "$CRED_CFG" ] || signal FAILED "$1" - echo "FAILED: $1" 1>&2; - exit 1 -} - -erase_disks() { - for disk in `lsblk -d -n -oKNAME,TYPE,RO | grep '^\w*\s*disk\s*0' | awk {'print $1'}` - do - echo "Erasing $disk..." - bytes=$(blockdev --getsize64 /dev/$disk) - head -c $bytes /dev/zero > /dev/$disk - done -} - -main() { - # Install tools and load modules. - aptget update - aptget install python3-yaml python3-oauthlib - - # The main function, actually execute stuff that is written below. - local creds="" - - find_creds_cfg || - fail "failed to find credential config" - creds="$_RET" - - # Get remote credentials into a local file. - case "$creds" in - http://*|https://*) - wget "$creds" -O "${TEMP_D}/my.creds" || - fail "failed to get credentials from $cred_cfg" - creds="${TEMP_D}/my.creds" - ;; - esac - - # Use global name read by signal() and fail. - CRED_CFG="$creds" - - set -e -u - - echo "Erasing disks." - erase_disks - - signal OK "Disks erased." -} - -### begin writing files ### - -add_bin "maas_api_helper.py" <<"END_MAAS_API_HELPER" -{{maas_api_helper_py}} -END_MAAS_API_HELPER - -add_bin "maas-signal" <<"END_MAAS_SIGNAL" -{{maas_signal_py}} -END_MAAS_SIGNAL - -main -exit diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/user_data_poweroff.template maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/user_data_poweroff.template --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/user_data_poweroff.template 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/user_data_poweroff.template 1970-01-01 00:00:00.000000000 +0000 @@ -1,10 +0,0 @@ -#!/bin/sh - -main() { - echo "Powering node off." - - # Cloud-init will handle powering off the node. Nothing to do. -} - -main -exit diff -Nru maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/user_data.template maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/user_data.template --- maas-2.0.0+bzr5189/etc/maas/templates/commissioning-user-data/user_data.template 2016-08-18 11:27:24.000000000 +0000 +++ maas-2.1.1+bzr5544/etc/maas/templates/commissioning-user-data/user_data.template 1970-01-01 00:00:00.000000000 +0000 @@ -1,253 +0,0 @@ -#!/bin/sh -# -# This script carries inside it multiple files. When executed, it creates -# the files into a temporary directory, downloads and extracts commissioning -# scripts from the metadata service, and then processes the scripts. -# -# The commissioning scripts get run by a close equivalent of run-parts. -# For each, the main script calls home to maas with maas-signal, posting -# the script's output as a separate file. -# -#### IPMI setup ###### -# If IPMI network settings have been configured statically, you can -# make them DHCP. If 'true', the IPMI network source will be changed -# to DHCP. -IPMI_CHANGE_STATIC_TO_DHCP="false" - -# In certain hardware, the parameters for the ipmi_si kernel module -# might need to be specified. If you wish to send parameters, uncomment -# the following line. -#IPMI_SI_PARAMS="type=kcs ports=0xca2" - -#### script setup ###### -TEMP_D=$(mktemp -d "${TMPDIR:-/tmp}/${0##*/}.XXXXXX") -SCRIPTS_D="${TEMP_D}/commissioning.d" -IPMI_CONFIG_D="${TEMP_D}/ipmi.d" -BIN_D="${TEMP_D}/bin" -OUT_D="${TEMP_D}/out" -PATH="$BIN_D:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" -trap cleanup EXIT - -mkdir -p "$BIN_D" "$OUT_D" "$SCRIPTS_D" "$IPMI_CONFIG_D" - -# Ensure that invocations of apt-get are not interactive by default, -# here and in all subprocesses. -export DEBIAN_FRONTEND=noninteractive - -### some utility functions #### -aptget() { - apt-get --assume-yes -q "$@" "${BIN_D}/$1" - chmod "${2:-755}" "${BIN_D}/$1" -} -add_ipmi_config() { - cat > "${IPMI_CONFIG_D}/$1" - chmod "${2:-644}" "${IPMI_CONFIG_D}/$1" -} -cleanup() { - [ -n "${TEMP_D}" ] || rm -Rf "${TEMP_D}" -} - -find_creds_cfg() { - local config="" file="" found="" - - # If the config location is set in environment variable, trust it. - [ -n "${COMMISSIONING_CREDENTIALS_URL}" ] && - _RET="${COMMISSIONING_CREDENTIALS_URL}" && return - - # Go looking for local files written by cloud-init. - for file in /etc/cloud/cloud.cfg.d/*cmdline*.cfg; do - [ -f "$file" ] && _RET="$file" && return - done - - local opt="" cmdline="" - if [ -f /proc/cmdline ] && read cmdline < /proc/cmdline; then - # Search through /proc/cmdline arguments: - # cloud-config-url trumps url= - for opt in $cmdline; do - case "$opt" in - url=*) - found=${opt#url=};; - cloud-config-url=*) - _RET="${opt#*=}" - return 0;; - esac - done - [ -n "$found" ] && _RET="$found" && return 0 - fi - return 1 -} - -# Invoke the "signal()" API call to report progress. -# Usage: signal -signal() { - maas-signal "--config=${CRED_CFG}" "$@" -} - -# Report result of a commissioning script: output file, error output -# file if there was any error output, and return code. -# Usage: signal -signal_result() { - local result=$1 message="$2" stdout="$3" stderr="$4" - local files="--file=$stdout" - if [ -f "$stderr" -a -s "$stderr" ] - then - files="$files --file=$stderr" - fi - maas-signal \ - "--config=${CRED_CFG}" \ - "--script-result=$result" \ - $files \ - WORKING "$message" -} - -fail() { - [ -z "$CRED_CFG" ] || signal FAILED "$1" - echo "FAILED: $1" 1>&2; - exit 1 -} - -write_block_poweroff() { - touch /tmp/block-poweroff -} - -main() { - {{if node.enable_ssh}} - write_block_poweroff - {{endif}} - - # Install tools and load modules. - aptget update - aptget install python3-yaml python3-oauthlib freeipmi-tools openipmi ipmitool - load_modules - - # The main function, actually execute stuff that is written below. - local script total=0 creds="" - - find_creds_cfg || - fail "failed to find credential config" - creds="$_RET" - - # Get remote credentials into a local file. - case "$creds" in - http://*|https://*) - wget "$creds" -O "${TEMP_D}/my.creds" || - fail "failed to get credentials from $cred_cfg" - creds="${TEMP_D}/my.creds" - ;; - esac - - # Use global name read by signal() and fail. - CRED_CFG="$creds" - - # Power settings. - local pargs="" - if $IPMI_CHANGE_STATIC_TO_DHCP; then - pargs="--dhcp-if-static" - fi - power_type=$(maas-ipmi-autodetect-tool) - case "$power_type" in - ipmi) - power_settings=$(maas-ipmi-autodetect --configdir "$IPMI_CONFIG_D" ${pargs}) - ;; - moonshot) - power_settings=$(maas-moonshot-autodetect) - ;; - esac - if [ ! -z "$power_settings" ]; then - signal "--power-type=${power_type}" "--power-parameters=${power_settings}" WORKING "finished [maas-ipmi-autodetect]" - fi - - # Download and extract commissioning scripts. It will contain a - # commissioning.d directory, so this is how $SCRIPTS_D is created. - maas-get --config="${CRED_CFG}" maas-commissioning-scripts | tar -C "${TEMP_D}" -x - - # Just get a count of how many scripts there are for progress reporting. - for script in "${SCRIPTS_D}/"*; do - [ -x "$script" -a -f "$script" ] || continue - total=$(($total+1)) - done - - local cur=1 numfailed=0 name="" failed="" separator="" - for script in "${SCRIPTS_D}/"*; do - [ -f "$script" -a -f "$script" ] || continue - name=${script##*/} - signal WORKING "starting ${name} [$cur/$total]" - "$script" > "${OUT_D}/${name}.out" 2> "${OUT_D}/${name}.err" - ret=$? - signal_result \ - "$ret" "finished $name [$cur/$total]: $ret" \ - "${OUT_D}/${name}.out" \ - "${OUT_D}/${name}.err" - if [ $ret -ne 0 ]; then - numfailed=$(($numfailed+1)) - failed="${failed}${separator}${name}" - separator=", " - fi - cur=$(($cur+1)) - done - - if [ $numfailed -eq 0 ]; then - ( cd "${OUT_D}" && - signal OK "finished [$total/$total]" ) - return 0 - else - ( cd "${OUT_D}" && - signal FAILED "failed [$numfailed/$total] ($failed)" ) - return $numfailed - fi - -} - -load_modules() { - modprobe ipmi_msghandler - modprobe ipmi_devintf - modprobe ipmi_si ${IPMI_SI_PARAMS} - modprobe ipmi_ssif - udevadm settle -} - -### begin writing files ### - -# Example config: enable BMC remote access (on some systems.) -#add_ipmi_config "02-global-config.ipmi" <<"END_IPMI_CONFIG" -#Section Lan_Channel -# Volatile_Access_Mode Always_Available -# Volatile_Enable_User_Level_Auth Yes -# Volatile_Channel_Privilege_Limit Administrator -# Non_Volatile_Access_Mode Always_Available -# Non_Volatile_Enable_User_Level_Auth Yes -# Non_Volatile_Channel_Privilege_Limit Administrator -#EndSection -#END_IPMI_CONFIG - -add_bin "maas-ipmi-autodetect-tool" <<"END_MAAS_IPMI_AUTODETECT_TOOL" -{{maas_ipmi_autodetect_tool_py}} -END_MAAS_IPMI_AUTODETECT_TOOL - -add_bin "maas-ipmi-autodetect" <<"END_MAAS_IPMI_AUTODETECT" -{{maas_ipmi_autodetect_py}} -END_MAAS_IPMI_AUTODETECT - -add_bin "maas-moonshot-autodetect" <<"END_MAAS_MOONSHOT_AUTODETECT" -{{maas_moonshot_autodetect_py}} -END_MAAS_MOONSHOT_AUTODETECT - -add_bin "maas_api_helper.py" <<"END_MAAS_API_HELPER" -{{maas_api_helper_py}} -END_MAAS_API_HELPER - -add_bin "maas-signal" <<"END_MAAS_SIGNAL" -{{maas_signal_py}} -END_MAAS_SIGNAL - -add_bin "maas-get" < + + + + + + @@ -11,6 +18,8 @@ + +