-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
Ubuntu 12.04 LTS
Background:
- I had Hudson installed from http://hudson-ci.org/debian.
- I upgraded Ubuntu from 10.04 LTS to 12.04 LTS.
- I installed Jenkins 1.424 from stock Ubuntu repos (and ended up with both Hudson and Jenkins installed side by side, which was kind of nice for a gradual migration)
- I moved all the jobs from Hudson to Jenkins manually, cleaning them up as I went, then shut down Hudson and disabled its startup script
- As time passed I kept making changes to Jenkins (new jobs, etc.)
Summary of the situation:
- a hudson package is still installed from the old hudson-ci repo
- jenkins and jenkins-common packages are installed from Ubuntu repos
- /var/lib/hudson exists with old configuration
- /var/lib/jenkins exists with new configuration
- /var/lib/jenkins is a mountpoint for an ext4 filesystem (/var was too small)
What I did next:
- added http://pkg.jenkins-ci.org/debian to apt sources
- tried to apt-get dist-upgrade to get the latest jenkins
What I expected:
- jenkins is upgraded and doesn't destroy my working configuration in /var/lib/jenkins
What actually happened:
- important configuration files like /var/lib/jenkins/config.xml and /var/lib/jenkins/.gitconfig were overwritten with stale copies from /var/lib/hudson
It's a good thing I had a backup!
There were other speedbumps along the road, and I'll file separate bugs for them:
- a conflict with a file from Ubuntu's jenkins-common, which I had to resolve by manually apt-get removing jenkins-common, after which I could run apt-get install jenkins again to continue the upgrade
- jenkins's post-install script failed with a bunch of errors like
mv: inter-device move failed: `/var/lib/hudson/jobs' to `/var/lib/jenkins/jobs'; unable to remove target: Is a directory
and to continue I had to mv /var/lib/hudson /var/lib/hudson.DO-NOT-TOUCH and run dpkg --configure --pending.