blob: ca53067c6e2183936e35515a115f44c6ef4e2bb9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
|
<!DOCTYPE html>
<html>
<head>
<title>
The Codex »
Notes on upgrading Puppet from 2.7 to 3.1
</title>
<link
rel='stylesheet'
type='text/css'
href='http://fonts.googleapis.com/css?family=Buenard:400,700&subset=latin,latin-ext'>
<link
rel="stylesheet"
type="text/css"
href="../media/css/reset.css">
<link
rel="stylesheet"
type="text/css"
href="../media/css/grimoire.css">
</head>
<body>
<div id="shell">
<ol id="breadcrumbs">
<li class="crumb-0 not-last">
<a href="../">index</a>
</li>
<li class="crumb-1 not-last">
<a href="./">devops</a>
</li>
<li class="crumb-2 last">
puppet-2.7-to-3.1
</li>
</ol>
<div id="article">
<h1 id="notes-on-upgrading-puppet-from-27-to-31">Notes on upgrading Puppet from 2.7 to 3.1</h1>
<h2 id="bad">Bad</h2>
<ul>
<li>
<p>As usual, you have to upgrade the puppet master first. 2.7 agents can speak
to 3.1 masters just fine, but 3.1 agents cannot speak to 2.7 masters.</p>
</li>
<li>
<p>I tried to upgrade the Puppet master using both <code>puppet agent</code> (failed when
package upgrades shut down the puppet master) and <code>puppet apply</code> (failed for
Ubuntu-specific reasons outlined below)</p>
</li>
<li>
<p><a href="https://projects.puppetlabs.com/issues/19308">This bug</a>.</p>
</li>
<li>
<p>You more or less can't upgrade Puppet using Puppet.</p>
</li>
</ul>
<h2 id="good">Good</h2>
<ul>
<li>
<p>My 2.7 manifests worked perfectly under 3.1.</p>
</li>
<li>
<p>Puppet's CA and SSL certs survived intact and required no maintenance after
the upgrade.</p>
</li>
<li>
<p>The Hiera integration into class parameters works as advertised and really
does help a lot.</p>
</li>
<li>
<p>Once I figured out how to execute it, the upgrade was pretty smooth.</p>
</li>
<li>
<p>No Ruby upgrade!</p>
</li>
<li>
<p>Testing the upgrade in a VM sandbox meant being able to fuck up safely.
<a href="http://www.vagrantup.com">Vagrant</a> is super awesome.</p>
</li>
</ul>
<h2 id="package-management-sucks">Package Management Sucks</h2>
<p>Asking Puppet to upgrade Puppet went wrong on Ubuntu because of the way Puppet
is packaged: there are three (ish) Puppet packages, and Puppet's resource
evaluation bits try to upgrade and install one package at a time. Upgrading
only “puppetmaster” upgraded “puppet-common” but not “puppet,” causing Apt to
remove “puppet”; upgrading only “puppet” similarly upgraded “puppet-copmmon”
but not “puppetmaster,” causing Apt to remove “puppetmaster.”</p>
<p>The Puppet aptitude provider (which I use instead of apt-get) for Package
resources also doesn't know how to tell aptitude what to do with config files
during upgrades. This prevented Puppet from being able to upgrade pacakges
even when running standalone (via <code>puppet apply</code>).</p>
<p>Finally, something about the switchover from Canonical's Puppet .debs to
Puppetlabs' .debs caused aptitude to consider all three packages “broken”
after a manual upgrade ('aptitude upgrade puppet puppetmaster'). Upgrading the
packages a second time corrected it; this is the path I eventually took with
my production puppetmaster and nodes.</p>
</div>
<div id="comments">
<div id="disqus_thread"></div>
<script type="text/javascript">
/* * * CONFIGURATION VARIABLES: EDIT BEFORE PASTING INTO YOUR WEBPAGE * * */
var disqus_shortname = 'grimoire'; // required: replace example with your forum shortname
/* * * DON'T EDIT BELOW THIS LINE * * */
(function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = 'http://' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})();
</script>
<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
</div>
<div id="footer">
<p>
The Codex —
Powered by <a href="http://markdoc.org/">Markdoc</a>.
<a href="https://bitbucket.org/ojacobson/grimoire.ca/src/master/wiki/devops/puppet-2.7-to-3.1.md">See this page on Bitbucket</a> (<a href="https://bitbucket.org/ojacobson/grimoire.ca/history-node/master/wiki/devops/puppet-2.7-to-3.1.md">history</a>).
</p>
</div>
</div>
</body>
</html>
|