[Bug 1167660] [NEW] maas-cluster-controller.postinst failing with an unterminated sed error
Diogo Matsubara
matsubara at canonical.com
Thu Apr 11 01:34:36 UTC 2013
Public bug reported:
maas-cluster-controller package is failing to install with the following
error:
Setting up maas-cluster-controller (0.2+1.2+bzr1373+dfsg-0+1373+168~ppa0~quantal
1) ...
sed: -e expression #1, char 23: unterminated `s' command
dpkg: error processing maas-cluster-controller (--configure):
subprocess installed post-installation script returned error exit status 1
Processing triggers for libc-bin ...
I added set -x to the /var/lib/dpkg/info/maas-cluster-controller.postint
script and re-run the command. Below is the output.
Notice there are two bugs here:
+ RET= http://192.168.21.5/MAAS which contains an leading whitespace
and the bug that's causing the error on line 86 of maas-cluster-
controller.postinst:
sed -i "s|MAAS_URL=.*|MAAS_URL="$RET"|"
/etc/maas/maas_cluster.conf
which works when it's like: sed -i "s|MAAS_URL=.*|MAAS_URL='$RET'|"
/etc/maas/maas_cluster.conf
ubuntu at autopkgtest:~$ sudo apt-get install maas-cluster-controller
Reading package lists... Done
Building dependency tree
Reading state information... Done
maas-cluster-controller is already the newest version.
The following packages were automatically installed and are no longer required:
linux-headers-3.5.0-22 linux-headers-3.5.0-22-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue [Y/n]? y
Setting up maas-cluster-controller (0.2+1.2+bzr1373+dfsg-0+1373+168~ppa0~quantal1) ...
+ . /usr/share/debconf/confmodule
+ [ ! ]
+ PERL_DL_NONLAZY=1
+ export PERL_DL_NONLAZY
+ [ ]
+ exec /usr/share/debconf/frontend /var/lib/dpkg/info/maas-cluster-controller.postinst configure
+ . /usr/share/debconf/confmodule
+ [ ! 1 ]
+ [ -z ]
+ exec
+ [ ]
+ exec
+ DEBCONF_REDIR=1
+ export DEBCONF_REDIR
+ db_version 2.0
+ _db_cmd VERSION 2.0
+ _db_internal_IFS=
+ IFS=
+ printf %s\n VERSION 2.0
+ IFS=
+ IFS=
read -r _db_internal_line
+ RET=2.0
+ return 0
+ [ configure = configure ]
+ [ -z ]
+ create_log_dir
+ [ ! -d /var/lib/maas ]
+ [ ! -d /var/log/maas/oops ]
+ chown -R maas:maas /var/lib/maas/
+ chown -R maas:maas /var/log/maas
+ chmod -R 775 /var/log/maas/oops
+ configure_maas_tgt
+ local tgtcfg=/etc/tgt/targets.conf
+ [ -d /etc/tgt/conf.d/ ]
+ mkdir -p /etc/tgt/conf.d/ /var/lib/maas/ephemeral/
+ ln -sf /var/lib/maas/ephemeral/tgt.conf /etc/tgt/conf.d/maas.conf
+ [ configure = configure ]
+ [ -z ]
+ dpkg --compare-versions lt 0.1+bzr1239+dfsg-0ubuntu1
+ create_log_dir
+ [ ! -d /var/lib/maas ]
+ [ ! -d /var/log/maas/oops ]
+ chown -R maas:maas /var/lib/maas/
+ chown -R maas:maas /var/log/maas
+ chmod -R 775 /var/log/maas/oops
+ db_get maas-cluster-controller/maas-url
+ _db_cmd GET maas-cluster-controller/maas-url
+ _db_internal_IFS=
+ IFS=
+ printf %s\n GET maas-cluster-controller/maas-url
+ IFS=
+ IFS=
read -r _db_internal_line
+ RET= http://192.168.21.5/MAAS
+ return 0
+ [ -n http://192.168.21.5/MAAS ]
+ sed -i s|MAAS_URL=.*|MAAS_URL= http://192.168.21.5/MAAS| /etc/maas/maas_cluster.conf
sed: -e expression #1, char 23: unterminated `s' command
dpkg: error processing maas-cluster-controller (--configure):
subprocess installed post-installation script returned error exit status 1
No apport report written because MaxReports is reached already
Errors were encountered while processing:
maas-cluster-controller
E: Sub-process /usr/bin/dpkg returned an error code (1)
** Affects: maas (Ubuntu)
Importance: Undecided
Status: New
** Branch linked: lp:~matsubara/maas/fix-maas-cluster-controller-sed
--
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to maas in Ubuntu.
https://bugs.launchpad.net/bugs/1167660
Title:
maas-cluster-controller.postinst failing with an unterminated sed
error
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/maas/+bug/1167660/+subscriptions
More information about the Ubuntu-server-bugs
mailing list