[Labs-l] Labs datacenter migration

Andrew Bogott abogott at wikimedia.org
Wed Nov 20 18:09:06 UTC 2013


On 11/20/13 10:01 AM, Petr Bena wrote:
> Can you please elaborate more on what we need to do in case we have
> instances with selfhosted puppet master?

Yep!  Also note that I do not at all mind doing this myself, so if you 
have a problematic instance just let me know and I can clean things up.  
I recently visited almost all of the self-hosted instances and organized 
things, so probably your instances are in reasonable shape already.

To update yourself:

First, figure out if you have local changes, and if they're already 
organized into patches:

$ cd /var/lib/git/operations/puppet
$ git diff .

Is there a diff?  If so you need to organize it into one or more patches 
and get them committed.  Until 'git diff' runs cleanly the next step 
will fail.

Now that your local repo is organized, we want to rebase against 
gerrit.  Assuming you haven't done anything dramatic, this should do the 
trick:

$ sudo GIT_SSH=/var/lib/git/ssh git pull --rebase

That rebase may fail with conflicts, depending on what local patches you 
have.  If so, you need to resolve the conflicts as you would with any 
git rebase.

Once things are rebasing properly...

$ sudo puppetd -tv

And look for errors or warnings, and fix them :)

Doing all of this will get your instance so that it's clean and ready 
for updates, but we'll still need to repeat the rebase by hand when the 
actual migration happens.  I'm not yet entirely sure how that procedure 
will go, but I guarantee it will be much easier if you follow the above 
steps ahead of time.

-Andrew


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wikimedia.org/pipermail/labs-l/attachments/20131120/3f8d4682/attachment.html>


More information about the Labs-l mailing list