Error: Could not back up /etc/localtime: Got passed new contents for sum {md5}...

447 views
Skip to first unread message

jaambros

unread,
Feb 7, 2015, 4:06:27 PM2/7/15
to railsmachin...@googlegroups.com
Hi All,
I have been deploying with no problem for the last 3 months to a staging and production server (Ubuntu 12.04).
Rails 3.2.17, Ruby 2.1.2, I updated moonshine on Nov'04.
The production server was created using the image of the staging server (once it was setup) so they are virtually identincal.
$ uname -a
Linux tek32live 3.2.0-75-generic #110-Ubuntu SMP Tue Dec 16 19:11:55 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

This last tuesday night I deployed a bug fix to the staging server with no problem.
After the testing team OKd it on thursday I tried deploying to the production server and I got the following errors:

** [out :: tek32] Error: Could not back up /etc/localtime: Got passed new contents for sum {md5}685e6cae6f7d63e690bf35b955ff4afb
 ** [out :: tek32]
 ** [out :: tek32] Error: Could not back up /etc/localtime: Got passed new contents for sum {md5}685e6cae6f7d63e690bf35b955ff4afb
 ** [out :: tek32]
 ** [out :: tek32] Error: /File[/etc/localtime]/ensure: change from file to link failed: Could not back up /etc/localtime: Got passed new contents for sum {md5}685e6cae6f7d63e690bf35b955ff4afb

In my attempts to try to figure out the problem I tried deploying again the same release to the staging server, and to my surprise I got the same error; ie, the exact same release that worked fine two days before, now was failing.
Puppet::Util::Log.level = :debug  did not reveal any more useful information.
I find it very puzzling to have the same bug show up in two different servers, that days before were fine ...

I haven't found anything relevant in my web searches, so I would be very grateful to anyone for help in resolving this problem.

Thanks in advance,
Jose



Bryan Traywick

unread,
Feb 7, 2015, 4:30:59 PM2/7/15
to railsmachin...@googlegroups.com
Hey Jose,

This problem is caused when the timezone package (tzdata) is automatically updated due to unattended upgrades. When the updated package is installed the contents of /etc/localtime is changed and no longer matches the entry that Puppet maintains in its clientbucket. The only fix is to remove the client bucket entry for /etc/localtime manually. If you have multiple servers in a particular stage the easiest way to remove the entry from all of the servers is to run `cap staging shell` (replace staging with production to remove the entry on the production servers). This will open a `cap>` prompt that allows you to run arbitrary shell commands on all staging servers just as if you had logged in via SSH. To remove the client bucket entry just run `sudo rm -rf /var/shadow_puppet/clientbucket/6/8/5/e/6/c/a/e/685e6cae6f7d63e690bf35b955ff4afb`. After that you should be able to deploy successfully again.

Thanks,
— Bryan Traywick

--
You received this message because you are subscribed to the Google Groups "Moonshine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to railsmachine-moon...@googlegroups.com.
To post to this group, send email to railsmachin...@googlegroups.com.
Visit this group at http://groups.google.com/group/railsmachine-moonshine.
For more options, visit https://groups.google.com/d/optout.

jaambros

unread,
Feb 7, 2015, 7:35:17 PM2/7/15
to railsmachin...@googlegroups.com
Hey Bryan,

That did the trick!
Thanks a lot for your help.

Jose
To unsubscribe from this group and stop receiving emails from it, send an email to railsmachine-moonshine+unsub...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages