[Bug 1828259] Re: [rocky][19.04] Upgrading a deployment from Queens to Rocky resulted in purging of neutron-l3-agent package

Dmitrii Shcherbakov 1828259 at bugs.launchpad.net
Wed May 8 16:35:24 UTC 2019


Priority usage of python2 dependencies is reproducible on a clean
environment:


lxc launch ubuntu:bionic neutrontest          
Creating neutrontest
Starting neutrontest

lxc exec neutrontest bash

root at neutrontest:~# sudo add-apt-repository cloud-archive:rocky
 Ubuntu Cloud Archive for OpenStack Rocky
 More info: https://wiki.ubuntu.com/ServerTeam/CloudArchive
Press [ENTER] to continue or Ctrl-c to cancel adding it.

Reading package lists...
Building dependency tree...
Reading state information...
The following package was automatically installed and is no longer required:
  libfreetype6
Use 'sudo apt autoremove' to remove it.
The following NEW packages will be installed:
  ubuntu-cloud-keyring
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 6008 B of archives.
After this operation, 22.5 kB of additional disk space will be used.
Get:1 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 ubuntu-cloud-keyring all 2018.09.18.1~18.04.0 [6008 B]
Fetched 6008 B in 1s (8364 B/s)
Selecting previously unselected package ubuntu-cloud-keyring.
(Reading database ... 28640 files and directories currently installed.)
Preparing to unpack .../ubuntu-cloud-keyring_2018.09.18.1~18.04.0_all.deb ...
Unpacking ubuntu-cloud-keyring (2018.09.18.1~18.04.0) ...
Setting up ubuntu-cloud-keyring (2018.09.18.1~18.04.0) ...
Hit:1 http://archive.ubuntu.com/ubuntu bionic InRelease
Get:2 http://archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]             
Get:3 http://archive.ubuntu.com/ubuntu bionic-backports InRelease [74.6 kB]                     
Get:4 http://archive.ubuntu.com/ubuntu bionic/universe amd64 Packages [8570 kB]                                  
Get:5 http://security.ubuntu.com/ubuntu bionic-security InRelease [88.7 kB]                                                          
Get:6 http://security.ubuntu.com/ubuntu bionic-security/main amd64 Packages [332 kB]                                                            
Get:7 http://archive.ubuntu.com/ubuntu bionic/universe Translation-en [4941 kB]                                                               
Get:8 http://security.ubuntu.com/ubuntu bionic-security/main Translation-en [119 kB]                                                                             
Get:9 http://security.ubuntu.com/ubuntu bionic-security/universe amd64 Packages [242 kB]                                                                             
Get:10 http://security.ubuntu.com/ubuntu bionic-security/universe Translation-en [139 kB]                                                                            
Get:11 http://security.ubuntu.com/ubuntu bionic-security/multiverse amd64 Packages [4008 B]                                                                          
Get:12 http://security.ubuntu.com/ubuntu bionic-security/multiverse Translation-en [2060 B]                                                                          
Get:13 http://archive.ubuntu.com/ubuntu bionic/multiverse amd64 Packages [151 kB]                                                                                 
Get:14 http://archive.ubuntu.com/ubuntu bionic/multiverse Translation-en [108 kB]
Get:15 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages [597 kB]   
Get:16 http://archive.ubuntu.com/ubuntu bionic-updates/main Translation-en [220 kB]
Get:17 http://archive.ubuntu.com/ubuntu bionic-updates/universe amd64 Packages [930 kB]
Ign:18 http://ubuntu-cloud.archive.canonical.com/ubuntu bionic-updates/rocky InRelease
Get:19 http://archive.ubuntu.com/ubuntu bionic-updates/universe Translation-en [270 kB]
Get:20 http://archive.ubuntu.com/ubuntu bionic-updates/multiverse amd64 Packages [6636 B]
Get:21 http://archive.ubuntu.com/ubuntu bionic-updates/multiverse Translation-en [3556 B]
Get:22 http://archive.ubuntu.com/ubuntu bionic-backports/main amd64 Packages [1024 B] 
Get:23 http://archive.ubuntu.com/ubuntu bionic-backports/main Translation-en [448 B]  
Get:24 http://archive.ubuntu.com/ubuntu bionic-backports/universe amd64 Packages [3492 B]
Get:25 http://ubuntu-cloud.archive.canonical.com/ubuntu bionic-updates/rocky Release [7879 B]
Get:26 http://archive.ubuntu.com/ubuntu bionic-backports/universe Translation-en [1604 B]
Get:27 http://ubuntu-cloud.archive.canonical.com/ubuntu bionic-updates/rocky Release.gpg [543 B]
Get:28 http://ubuntu-cloud.archive.canonical.com/ubuntu bionic-updates/rocky/main amd64 Packages [116 kB]
Fetched 17.0 MB in 4s (4333 kB/s)                        
Reading package lists... Done
root at neutrontest:~# sudo apt install neutron-l3-agent
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  alembic conntrack docutils-common docutils-doc formencode-i18n haproxy ieee-data ipset iputils-arping ipvsadm javascript-common keepalived libice6 libipset3
  libjbig0 libjpeg-turbo8 libjpeg8 libjs-jquery libjs-sphinxdoc libjs-underscore liblcms2-2 liblua5.3-0 libnl-3-200 libnl-genl-3-200 libnl-route-3-200
  libpaper-utils libpaper1 libpython-stdlib libpython2.7-minimal libpython2.7-stdlib libsensors4 libsm6 libsnmp-base libsnmp30 libtiff5 libwebp6 libwebpdemux2
  libwebpmux3 libxmu6 libxt6 neutron-common neutron-fwaas-common neutron-metadata-agent pycadf-common python python-alembic python-amqp python-anyjson
  python-appdirs python-asn1crypto python-babel python-babel-localedata python-blinker python-bs4 python-cachetools python-ceilometerclient python-certifi
  python-cffi python-cffi-backend python-chardet python-cliff python-cmd2 python-concurrent.futures python-contextlib2 python-crypto python-cryptography
  python-dateutil python-dbus python-debtcollector python-decorator python-deprecation python-designateclient python-dnspython python-docutils python-dogpile.cache
  python-enum34 python-eventlet python-extras python-fasteners python-fixtures python-formencode python-funcsigs python-functools32 python-futurist python-gi
  python-greenlet python-html5lib python-httplib2 python-idna python-ipaddress python-iso8601 python-jinja2 python-jmespath python-json-pointer python-jsonpatch
  python-jsonschema python-jwt python-keyring python-keyrings.alt python-keystoneauth1 python-keystoneclient python-keystonemiddleware python-kombu
  python-linecache2 python-logutils python-lxml python-mako python-markupsafe python-memcache python-migrate python-mimeparse python-minimal python-mock
  python-monotonic python-msgpack python-munch python-netaddr python-netifaces python-neutron python-neutron-fwaas python-neutron-lib python-neutronclient
  python-novaclient python-oauthlib python-olefile python-openid python-openssl python-openstacksdk python-openvswitch python-os-client-config
  python-os-service-types python-os-xenapi python-osc-lib python-oslo.cache python-oslo.concurrency python-oslo.config python-oslo.context python-oslo.db
  python-oslo.i18n python-oslo.log python-oslo.messaging python-oslo.middleware python-oslo.policy python-oslo.privsep python-oslo.reports python-oslo.rootwrap
  python-oslo.serialization python-oslo.service python-oslo.utils python-oslo.versionedobjects python-osprofiler python-ovsdbapp python-paramiko python-paste
  python-pastedeploy python-pastedeploy-tpl python-pastescript python-pbr python-pecan python-pil python-pkg-resources python-ply python-posix-ipc
  python-prettytable python-psutil python-pyasn1 python-pycadf python-pycparser python-pygments python-pyinotify python-pymysql python-pyparsing python-pyperclip
  python-pyroute2 python-repoze.lru python-requests python-requestsexceptions python-rfc3986 python-roman python-routes python-ryu python-scgi python-secretstorage
  python-setuptools python-simplegeneric python-simplejson python-singledispatch python-six python-sortedcontainers python-sqlalchemy python-sqlalchemy-ext
  python-sqlparse python-statsd python-stevedore python-tempita python-tenacity python-testresources python-testscenarios python-testtools python-tinyrpc
  python-traceback2 python-tz python-unicodecsv python-unittest2 python-urllib3 python-vine python-waitress python-weakrefmethod python-webencodings python-webob
  python-webtest python-wrapt python-yaml python2.7 python2.7-minimal python3-alembic python3-dateutil python3-mako python3-sqlalchemy python3-sqlalchemy-ext radvd
  sgml-base x11-common xclip xml-core
Suggested packages:
  vim-haproxy haproxy-doc heartbeat ldirectord apache2 | lighttpd | httpd liblcms2-utils lm-sensors snmp-mibs-downloader python-doc python-tk python-editor
  python-amqp-doc python-blinker-doc python-ceilometerclient-doc python-dev python-cliff-doc python-crypto-doc python-cryptography-doc python-cryptography-vectors
  python-dbus-dbg python-dbus-doc python-debtcollector-doc fonts-linuxlibertine | ttf-linux-libertine texlive-lang-french texlive-latex-base
  texlive-latex-recommended python-enum34-doc python-eventlet-doc python-egenix-mxdatetime python-funcsigs-doc python-futurist-doc python-gi-cairo
  python-greenlet-doc python-greenlet-dev python-greenlet-dbg python-genshi python-jinja2-doc gnome-keyring libkf5wallet-bin gir1.2-gnomekeyring-1.0 python-fs
  python-gdata python-keyczar python-keystoneauth1-doc python-requests-kerberos python-beanstalkc python-boto python-couchdb python-django python-kombu-doc
  python-pika python-pymongo python-redis python-lxml-dbg python-lxml-doc python-beaker python-mako-doc memcached python-migrate-doc python-mock-doc ipython
  python-netaddr-docs python-zmq python-neutron-lib-doc python-openssl-doc python-openssl-dbg python-openstacksdk-doc python-os-client-config-doc
  python-os-service-types-doc python-os-xenapi-doc python-osc-lib-doc python-oslo.cache-doc python-oslo.concurrency-doc python-oslo.log-doc python-kafka
  python-oslo.middleware-doc python-oslo.policy-doc python-oslo.privsep-doc python-oslo.reports-doc python-oslo.service-doc python-oslo.versionedobjects-doc
  python-ovsdbapp-doc python-gssapi httpd-wsgi libapache2-mod-python libapache2-mod-scgi libjs-mochikit python-pastewebkit python-cheetah python-cherrypy
  python-flup python-pecan-doc python-pil-doc python-pil-dbg python-ply-doc python-psutil-doc cpp ttf-bitstream-vera python-pyinotify-doc python-pymysql-doc
  python-pyparsing-doc python-pyroute2-doc python-socks python-ryu-doc python-secretstorage-doc python-setuptools-doc python-sortedcontainers-doc
  python-sqlalchemy-doc python-psycopg2 python-pymysql python-fdb python-pymssql python-sqlparse-doc python-tenacity-doc python-testtools-doc python-twisted
  python-tinyrpc-doc python-ntlm python-waitress-doc python-webob-doc python-webtest-doc python-pyquery python2.7-doc binutils binfmt-support python3-editor
  python3-beaker python3-psycopg2 python3-mysqldb python3-fdb sgml-base-doc debhelper
The following NEW packages will be installed:
  alembic conntrack docutils-common docutils-doc formencode-i18n haproxy ieee-data ipset iputils-arping ipvsadm javascript-common keepalived libice6 libipset3
  libjbig0 libjpeg-turbo8 libjpeg8 libjs-jquery libjs-sphinxdoc libjs-underscore liblcms2-2 liblua5.3-0 libnl-3-200 libnl-genl-3-200 libnl-route-3-200
  libpaper-utils libpaper1 libpython-stdlib libpython2.7-minimal libpython2.7-stdlib libsensors4 libsm6 libsnmp-base libsnmp30 libtiff5 libwebp6 libwebpdemux2
  libwebpmux3 libxmu6 libxt6 neutron-common neutron-fwaas-common neutron-l3-agent neutron-metadata-agent pycadf-common python python-alembic python-amqp
  python-anyjson python-appdirs python-asn1crypto python-babel python-babel-localedata python-blinker python-bs4 python-cachetools python-ceilometerclient
  python-certifi python-cffi python-cffi-backend python-chardet python-cliff python-cmd2 python-concurrent.futures python-contextlib2 python-crypto
  python-cryptography python-dateutil python-dbus python-debtcollector python-decorator python-deprecation python-designateclient python-dnspython python-docutils
  python-dogpile.cache python-enum34 python-eventlet python-extras python-fasteners python-fixtures python-formencode python-funcsigs python-functools32
  python-futurist python-gi python-greenlet python-html5lib python-httplib2 python-idna python-ipaddress python-iso8601 python-jinja2 python-jmespath
  python-json-pointer python-jsonpatch python-jsonschema python-jwt python-keyring python-keyrings.alt python-keystoneauth1 python-keystoneclient
  python-keystonemiddleware python-kombu python-linecache2 python-logutils python-lxml python-mako python-markupsafe python-memcache python-migrate python-mimeparse
  python-minimal python-mock python-monotonic python-msgpack python-munch python-netaddr python-netifaces python-neutron python-neutron-fwaas python-neutron-lib
  python-neutronclient python-novaclient python-oauthlib python-olefile python-openid python-openssl python-openstacksdk python-openvswitch python-os-client-config
  python-os-service-types python-os-xenapi python-osc-lib python-oslo.cache python-oslo.concurrency python-oslo.config python-oslo.context python-oslo.db
  python-oslo.i18n python-oslo.log python-oslo.messaging python-oslo.middleware python-oslo.policy python-oslo.privsep python-oslo.reports python-oslo.rootwrap
  python-oslo.serialization python-oslo.service python-oslo.utils python-oslo.versionedobjects python-osprofiler python-ovsdbapp python-paramiko python-paste
  python-pastedeploy python-pastedeploy-tpl python-pastescript python-pbr python-pecan python-pil python-pkg-resources python-ply python-posix-ipc
  python-prettytable python-psutil python-pyasn1 python-pycadf python-pycparser python-pygments python-pyinotify python-pymysql python-pyparsing python-pyperclip
  python-pyroute2 python-repoze.lru python-requests python-requestsexceptions python-rfc3986 python-roman python-routes python-ryu python-scgi python-secretstorage
  python-setuptools python-simplegeneric python-simplejson python-singledispatch python-six python-sortedcontainers python-sqlalchemy python-sqlalchemy-ext
  python-sqlparse python-statsd python-stevedore python-tempita python-tenacity python-testresources python-testscenarios python-testtools python-tinyrpc
  python-traceback2 python-tz python-unicodecsv python-unittest2 python-urllib3 python-vine python-waitress python-weakrefmethod python-webencodings python-webob
  python-webtest python-wrapt python-yaml python2.7 python2.7-minimal python3-alembic python3-dateutil python3-mako python3-sqlalchemy python3-sqlalchemy-ext radvd
  sgml-base x11-common xclip xml-core
0 upgraded, 226 newly installed, 0 to remove and 31 not upgraded.
Need to get 31.8 MB of archives.
After this operation, 167 MB of additional disk space will be used.

-- 
You received this bug notification because you are a member of Ubuntu
OpenStack, which is subscribed to neutron in Ubuntu.
https://bugs.launchpad.net/bugs/1828259

Title:
  [rocky][19.04] Upgrading a deployment from Queens to Rocky resulted in
  purging of neutron-l3-agent package

Status in neutron package in Ubuntu:
  New

Bug description:
  Upgrading OpenStack from Queens to Rocky results in removal of
  neutron-l3-agent package which leads to a networking outage.

  The issue with the fact that first python3 packages are installed and
  then python2 packages are purged. The neutron-l3-agent package depends
  on both.

  At the same time neutron-dhcp-agent survives the upgrade while both
  packages seem to have identical "Depends" directives for
  python[3]-neutron:

  https://git.launchpad.net/~ubuntu-server-dev/ubuntu/+source/neutron/tree/debian/control?h=stable/rocky#n178
  Package: neutron-l3-agent
  Architecture: all
  Depends:
   conntrack,
   iputils-arping,
   keepalived,
   neutron-metadata-agent (= ${source:Version}),
   python-neutron (= ${source:Version}) | python3-neutron (= ${source:Version}),
   python-neutron-fwaas (>= 1:13.0.0~) | python3-neutron-fwaas (>= 1:13.0.0~),

  https://git.launchpad.net/~ubuntu-server-dev/ubuntu/+source/neutron/tree/debian/control?h=stable/rocky#n156
  Package: neutron-dhcp-agent
  Architecture: all
  Depends:
   dnsmasq-base (>= 2.76),
   dnsmasq-utils (>= 2.76),
   neutron-metadata-agent (= ${source:Version}),
   python-neutron (= ${source:Version}) | python3-neutron (= ${source:Version}),

  When I try to install neutron-l3-agent it tries to pull python2 dependencies again (even though the python3 ones are already there):
  https://paste.ubuntu.com/p/J7Vq8KKnBf/

  More info below:

  ------
  2019-05-07 16:42:41 DEBUG neutron-plugin-api-relation-changed Selecting previously unselected package neutron-l3-agent.
  2019-05-07 16:42:41 DEBUG neutron-plugin-api-relation-changed Preparing to unpack .../6-neutron-l3-agent_2%3a12.0.5-0ubuntu1_all.deb ...
  2019-05-07 16:42:41 DEBUG neutron-plugin-api-relation-changed Unpacking neutron-l3-agent (2:12.0.5-0ubuntu1) ...

  2019-05-07 16:42:47 DEBUG neutron-plugin-api-relation-changed Setting up neutron-l3-agent (2:12.0.5-0ubuntu1) ...
  2019-05-07 16:42:47 DEBUG neutron-plugin-api-relation-changed Created symlink /etc/systemd/system/multi-user.target.wants/neutron-l3-agent.service → /lib/systemd/syst
  em/neutron-l3-agent.service.

  /var/log/apt/term.log:

  update-alternatives: using /usr/bin/python3-nova-metadata-wsgi to provide /usr/bin/nova-metadata-wsgi (nova-metadata-wsgi) in auto mode
  (Reading database ... ^M(Reading database ... 5%^M(Reading database ... 10%^M(Reading database ... 15%^M(Reading database ... 20%^M(Reading database ... 25%^M(Reading database ... 30%^M(Reading database ... 35%^M(Reading database ... 40%^M(Reading database ... 45%^M(Reading database ... 50%^M(Reading database ... 55%^M(Reading database ... 60%^M(Reading database ... 65%^M(Reading database ... 70%^M(Reading database ... 75%^M(Reading database ... 80%^M(Reading database ... 85%^M(Reading database ... 90%^M(Reading database ... 95%^M(Reading database ... 100%^M(Reading database ... 113229 files and directories currently installed.)
  Purging configuration files for python-neutron (2:13.0.2-0ubuntu1~cloud0) ...
  Purging configuration files for neutron-l3-agent (2:13.0.2-0ubuntu1~cloud0) ...
  Purging configuration files for python-neutron-fwaas (1:13.0.1-0ubuntu1~cloud0) ...
  Purging configuration files for python-nova (2:18.1.0-0ubuntu1~cloud0) ...
  Processing triggers for ureadahead (0.100.0-21) ...
  Processing triggers for systemd (237-3ubuntu10.21) ...
  Log ended: 2019-05-08  13:46:55

  /var/log/apt/history.log:

  # install python3 packages
  Start-Date: 2019-05-08  13:45:18
  Commandline: apt-get --assume-yes --option=Dpkg::Options::=--force-confold install nova-compute genisoimage librbd1 xfsprogs nfs-common ceph-common nova-compute-kvm n
  ova-api-metadata python3-nova python3-memcache python3-rados python3-rbd python3-neutron

  # purge python2 packages
  Start-Date: 2019-05-08  13:46:40
  Commandline: apt-get --assume-yes purge python-neutron python-nova
  Purge: neutron-l3-agent:amd64 (2:13.0.2-0ubuntu1~cloud0), python-nova:amd64 (2:18.1.0-0ubuntu1~cloud0), python-neutron:amd64 (2:13.0.2-0ubuntu1~cloud0), python-neutron-fwaas:amd64 (1:13.0.1-0ubuntu1~cloud0)
  End-Date: 2019-05-08  13:46:55

  apt policy python3-neutron
  https://paste.ubuntu.com/p/3vKsFBf9Hn/

  apt-rdepends:

  neutron-l3-agent
    Depends: conntrack
    Depends: iputils-arping
    Depends: keepalived
    Depends: neutron-metadata-agent (= 2:13.0.2-0ubuntu1~cloud0)
    Depends: python-neutron (= 2:13.0.2-0ubuntu1~cloud0)
    Depends: python-neutron-fwaas (>= 1:13.0.0~)
    Depends: python3-neutron (= 2:13.0.2-0ubuntu1~cloud0)
    Depends: python3-neutron-fwaas (>= 1:13.0.0~)
  # ...

  neutron-dhcp-agent
    Depends: dnsmasq-base (>= 2.76)
    Depends: dnsmasq-utils (>= 2.76)
    Depends: neutron-metadata-agent (= 2:13.0.2-0ubuntu1~cloud0)
    Depends: python-neutron (= 2:13.0.2-0ubuntu1~cloud0)
    Depends: python3-neutron (= 2:13.0.2-0ubuntu1~cloud0)
  # ...

  Charm code:
  https://opendev.org/openstack/charm-neutron-openvswitch/src/branch/stable/19.04/hooks/neutron_ovs_utils.py#L323-L325

      if cmp_release >= 'rocky':
          return PURGE_PACKAGES
      return []

  https://opendev.org/openstack/charm-neutron-openvswitch/src/branch/master/hooks/neutron_ovs_utils.py#L119-L122
  PURGE_PACKAGES = [
      'python-neutron',
      'python-neutron-fwaas',
  ]

  https://opendev.org/openstack/charm-neutron-
  openvswitch/src/branch/master/hooks/neutron_ovs_hooks.py#L115-L124

      install_packages()
      install_tmpfilesd()

      # NOTE(jamespage): purge any packages as a result of py3 switch
      #                  at rocky.
      packages_to_purge = determine_purge_packages()
      request_nova_compute_restart = False
      if packages_to_purge:
          purge_packages(packages_to_purge)
          request_nova_compute_restart = True

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/neutron/+bug/1828259/+subscriptions



More information about the Ubuntu-openstack-bugs mailing list