landscape-client cron job is broken

Bug #421707 reported by Ben Jencks on 2009-08-31
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Landscape Client
Undecided
Unassigned
Ubuntu on EC2
Undecided
Unassigned
Hardy
Undecided
Unassigned
landscape-client (Ubuntu)
Medium
Unassigned
Hardy
Medium
Scott Moser
Intrepid
Medium
Unassigned

Bug Description

The official EC2 hardy image doesn't have a value for RUN set in /etc/default/landscape-client. This causes the /etc/cron.hourly/landscape-client script to exit with an error, `[: 10: Illegal number: '.

It took a while to realize this problem because there's no MTA installed by default, so I only got the mails from some instances that had MTAs installed.

Andreas Hasenack (ahasenack) wrote :

Thanks, this is fixed in the new landscape-client package which needs to get added to the hardy image whenever a new one is generated.

Andreas Hasenack (ahasenack) wrote :

Ups, sorry, "duplicate" was not the right resolution. The landscape part is addressed in bug #362355, which is committed.

Changed in landscape-client:
status: New → Fix Committed
Scott Moser (smoser) wrote :

this isn't an issue in karmic, only in hardy. We plan to fix it there.

Changed in ubuntu-on-ec2:
status: New → Invalid
Andreas Hasenack (ahasenack) wrote :

Please take the landscape-client package built for hardy from this ppa:

https://launchpad.net/~landscape/+archive

You will need to grab an updated smartpm package as well and its dependencies. It's all in that ppa. So, to be clear:

landscape-client - 1.3.2.3-0ubuntu0.8.04.0~landscape1 and landscape-common
smart - 1.2-0ubuntu1.8.04.2 and its subpackages (smartpm-core, python-smartpm)

Please let me know as soon as you have a candidate AMI for testing.

Scott Moser (smoser) on 2009-09-09
tags: added: ec2-images uec-images
Soren Hansen (soren) wrote :

Is there any reason this couldn't land in Ubuntu proper (throug the SRU process)?

Scott Moser (smoser) on 2009-09-09
Changed in landscape-client (Ubuntu):
status: New → Triaged
Changed in landscape-client (Ubuntu Hardy):
status: New → Triaged
Changed in landscape-client (Ubuntu):
importance: Undecided → Medium
Changed in landscape-client (Ubuntu Intrepid):
status: New → Triaged
Changed in landscape-client (Ubuntu Hardy):
importance: Undecided → Medium
Changed in landscape-client (Ubuntu Intrepid):
importance: Undecided → Medium
Changed in landscape-client (Ubuntu):
status: Triaged → Invalid
status: Invalid → Fix Released
Scott Moser (smoser) on 2009-09-09
Changed in landscape-client (Ubuntu Hardy):
assignee: nobody → Scott Moser (smoser)

> Is there any reason this couldn't land in Ubuntu proper (throug the SRU
> process)?

I've verified that this bug is present in released images of both hardy
and intrepid. On the intrepid image, i did an
  apt-get install launchpad-client
there were no updates available.

I think we really need to pursue proper (SRU) updates for this, and stop
maintaining/using ppa builds of landscape-client in our ec2/uec images. I
apologize for anything I said previously that implied anything else.

One other thing to note, this is fairly easily worked around by a
user-data script (or other post-boot configuration).

I verified that 'sudo /etc/cron.hourly/landscape-client' is functional on
a system after booting with:
  xc2-run-instances --user-data-file=user-data.sh ami-5059be39

and 'user-data.sh' as below.

--- user-data.sh ---
#!/bin/sh

RUN=""
conf=/etc/default/landscape-client
. ${conf}
if [ -n "${RUN}" ]; then
   echo "run set to ${RUN} in ${conf}"
else
   echo "fixing ${conf}, setting RUN=1"
   echo "RUN=1" >> ${conf} ||
      { echo "failed."; exit 1; }
   echo "updated ${conf}"
fi
--- end user-data.sh ---

Andreas Hasenack (ahasenack) wrote :

The SRU ticket is #347983

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Scott Moser wrote:
>> Is there any reason this couldn't land in Ubuntu proper (throug the SRU
>> process)?
>
> I've verified that this bug is present in released images of both hardy
> and intrepid. On the intrepid image, i did an
> apt-get install launchpad-client
> there were no updates available.

Hardy doesn't have landscape-client in the distro, so we released it through
our own repository at http://landscape.canonical.com/packages/. That's where we
also release it for dapper, which we still maintain.

It's only from Intrepid onward that landscape-client is in ubuntu main proper.

- --
Andreas Hasenack
<email address hidden>

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkqn2Q4ACgkQeEJZs/PdwpCVdgCeLqNXS8JKZS7lPv+r7sUwwn4O
nYIAoOce8EvS+3O6f9HfcNbG5RC3sZMq
=cyaz
-----END PGP SIGNATURE-----

Scott Moser (smoser) wrote :

Andreas,
   I'm finally able to spend some time on hardy images. There are new daily builds put together and available in ec2. I was looking at the trying to add the required landscape updates to the ubuntu-on-ec2 ppa.
   It seems there are no 'smart' builds for hardy there.
https://launchpad.net/~landscape/+archive/ppa?field.series_filter=hardy

Just to be sure, I added the ppa to the running ec2 image and tried:

$ sudo apt-get install landscape-client
...
The following packages have unmet dependencies:
  landscape-client: Depends: landscape-common (>= 1.3.2.3-0ubuntu0.8.04.0~landscape1) but 1.0.30~ls3.1-0ubuntu0.8.04.0 is to be installed
...
$ sudo apt-get install landscape-common
...
  landscape-common: Depends: python-smartpm (>= 1.2-0ubuntu1) but 1.1.1~bzr20081010-0ubuntu0.8.10.1~ppa1 is to be installed

If we can get this sorted out, I can copy the needed packages to ubuntu-on-ec2 ppa, and nightly builds should then pick them up.

Scott Moser (smoser) wrote :

I just chatted with Free, and he's in the process of sorting this out. Once the packages appear in the landscape ppa, I'll copy to ubuntu-on-ec2 and they shoudl get picked up there.

Scott Moser (smoser) wrote :

https://launchpad.net/~landscape/+archive/ppa?field.series_filter=hardy
is updated now, verified that adding that ppa to the 20091109 hardy ami , and then 'apt-get install landscape-client' worked successfully. It got
Get:1 http://ppa.launchpad.net hardy/main python-smartpm 1.1.1~bzr20081010-0ubuntu1.8.04.0 [425kB]
Get:2 http://ppa.launchpad.net hardy/main landscape-common 1.3.2.3-0ubuntu0.8.04.1~landscape1 [169kB]
Get:3 http://ppa.launchpad.net hardy/main landscape-client 1.3.2.3-0ubuntu0.8.04.1~landscape1 [27.8kB]

Note the installation did say:
Installing new version of config file /etc/init.d/landscape-client ...
 * Reloading system message bus config... [ OK ]
landscape-client is not configured, please run landscape-config.

Free, or someone, does the above look right? if so, and this is solid, then I'd like to copy those source packages to the ubuntu-on-ec2 ppa.

Yes, it's right. Please just go ahead.

Andreas Hasenack (ahasenack) wrote :

This is fixed in ami-06ac4e6f. The cron job is no longer there:
root@domU-12-31-39-00-88-91:~# ls -la /etc/cron.hourly/
total 12
drwxr-xr-x 2 root root 4096 2009-11-12 16:00 .
drwxr-xr-x 73 root root 4096 2009-11-12 17:21 ..
-rw-r--r-- 1 root root 102 2009-05-12 21:48 .placeholder
root@domU-12-31-39-00-88-91:~# dpkg -l landscape-client
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Installed/Config-f/Unpacked/Failed-cfg/Half-inst/t-aWait/T-pend
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name Version Description
+++-=============================================-=============================================-==========================================================================================================
ii landscape-client 1.3.2.3-0ubuntu0.8.04.1~landscape1 The Landscape administration system client
root@domU-12-31-39-00-88-91:~#

In addition to that, landscape-client is working fine. There is a minor problem we found but it's not relevant enough to block this release.

Scott Moser (smoser) on 2009-11-12
Changed in landscape-client (Ubuntu Hardy):
status: Triaged → Fix Committed
Scott Moser (smoser) wrote :

fixed in released hardy images

Changed in landscape-client (Ubuntu Hardy):
status: Fix Committed → Fix Released
Alex Valavanis (valavanisalex) wrote :

Intrepid Ibex reached end-of-life on 30 April 2010 so I am closing the report. The bug has been fixed in newer releases of Ubuntu.

Changed in landscape-client (Ubuntu Intrepid):
status: Triaged → Invalid
Changed in landscape-client:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers