Re: [Puppet Users] File resource fails on Windows 7 x64 (other resources with different file works)

69 views
Skip to first unread message

Rob Reynolds

unread,
Feb 7, 2014, 5:35:32 PM2/7/14
to puppet...@googlegroups.com
First question - what version of puppet?

Second question - can you run puppet apply (or agent) with --trace --debug --verbose and post the relevant results? We have some recent fixes related to this.


On Thu, Feb 6, 2014 at 3:27 PM, jmp242 <jp1...@gmail.com> wrote:

I'm really lost as to why this is failing.

file{ 'openvpn.exe':
path => 'C:/ProgramData/puppetfiles/openvpn.exe',
source => "puppet:///modules/openvpn/openvpn.exe",
owner => 'SYSTEM',
group => 'Administrators',
mode => 0770,
provider => windows,
ensure => present,
}

gives me this error:

ReplaceFile(C:/ProgramData/puppetfiles/openvpn.exe, C:/ProgramData/puppetfiles/openvpn.exe20140206-5012-wvhezn): The system cannot find the file specified.


change from absent to file failed: ReplaceFile(C:/ProgramData/puppetfiles/openvpn.exe, C:/ProgramData/puppetfiles/openvpn.exe20140206-5012-wvhezn): The system cannot find the file specified.


I have no idea why. I'm using Puppet agent 3.4.2. A very similar resource:

file { 'fusion.exe':
path => 'C:/ProgramData/puppetfiles/fusion.exe',
source => "puppet:///modules/fusionagent/fusion.exe",
owner => 'SYSTEM',
group => 'Administrators',
mode => 0770,
provider => windows,
ensure => present,
}

works...


--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/8a72f9a1-1402-4e2d-80fb-703a5133e50e%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.



--
Rob Reynolds
Developer, Puppet Labs

Join us at PuppetConf 2014September 23-24 in San Francisco - http://bit.ly/pupconf14

José Luis Ledesma

unread,
Feb 7, 2014, 6:13:53 PM2/7/14
to puppet...@googlegroups.com

I'm a Unix guy, and perhaps this is a silly question but...

Does C:/ProgramData/puppetfiles/ directory exists?

Regards

Laurent Lepinay

unread,
Feb 10, 2014, 1:51:51 PM2/10/14
to puppet...@googlegroups.com
I have a similar issue here, i'm sourcing files from a directory recursively: some files get copied but some throw the same error as yours.
I'm on windows too.

jmp242

unread,
Feb 18, 2014, 7:06:43 PM2/18/14
to puppet...@googlegroups.com
Puppet 3.4.2, as specified. I've attached a log file.
puppet.log

Rob Reynolds

unread,
Feb 18, 2014, 7:51:01 PM2/18/14
to puppet...@googlegroups.com
Is this the correct log file for the error you described?



For more options, visit https://groups.google.com/groups/opt_out.

jmp242

unread,
Feb 18, 2014, 7:54:46 PM2/18/14
to puppet...@googlegroups.com
As far as I can tell. I'm on Windows, and it scrolls off the screen. It didn't seem to capture much when I tried to redirect to a file.

Rob Reynolds

unread,
Feb 18, 2014, 8:26:23 PM2/18/14
to puppet...@googlegroups.com
I didn't see the error that you described (your log notes an issue with forking), but have a look at https://tickets.puppetlabs.com/browse/PUP-1389 (which speaks of the require_file issues you describe). We've recently fixed that issue and it will be in the next release. I'm not sure these are the same issues, however.



For more options, visit https://groups.google.com/groups/opt_out.

jmp242

unread,
Feb 18, 2014, 8:31:54 PM2/18/14
to puppet...@googlegroups.com
Here's another test where I just added --test to your command, and passed to a log file. It should show my issue. Anyway, it does look very similar an error, though I can't figure out why any of the string manipulation would fail on openvpn.exe and not on fusion.exe ...
puppet2.log

Josh Cooper

unread,
Feb 25, 2014, 6:42:09 PM2/25/14
to puppet...@googlegroups.com
There are actually two different issues here:

On Tue, Feb 18, 2014 at 12:31 PM, jmp242 <jp1...@gmail.com> wrote:
Here's another test where I just added --test to your command, and passed to a log file. It should show my issue. Anyway, it does look very similar an error, though I can't figure out why any of the string manipulation would fail on openvpn.exe and not on fusion.exe ...

On Tuesday, February 18, 2014 3:26:23 PM UTC-5, Rob Reynolds wrote:
I didn't see the error that you described (your log notes an issue with forking), but have a look at https://tickets.puppetlabs.com/browse/PUP-1389 (which speaks of the require_file issues you describe). We've recently fixed that issue and it will be in the next release. I'm not sure these are the same issues, however.


On Tue, Feb 18, 2014 at 1:54 PM, jmp242 <jp1...@gmail.com> wrote:
As far as I can tell. I'm on Windows, and it scrolls off the screen. It didn't seem to capture much when I tried to redirect to a file.


On Tuesday, February 18, 2014 2:51:01 PM UTC-5, Rob Reynolds wrote:
Is this the correct log file for the error you described?


On Tue, Feb 18, 2014 at 1:06 PM, jmp242 <jp1...@gmail.com> wrote:
Puppet 3.4.2, as specified. I've attached a log file.



From the log file: "Error: Could not run: fork() function is unimplemented on this machine"

This is https://tickets.puppetlabs.com/browse/PUP-1275. You either need to explicitly specify --onetime, or --test (which automatically sets onetime). Unfortunately this means you cannot setup a listening puppet agent and use kick on it. This is a regression introduced in http://projects.puppetlabs.com/issues/17361




On Friday, February 7, 2014 12:35:32 PM UTC-5, Rob Reynolds wrote:
First question - what version of puppet?

Second question - can you run puppet apply (or agent) with --trace --debug --verbose and post the relevant results? We have some recent fixes related to this.


On Thu, Feb 6, 2014 at 3:27 PM, jmp242 <jp1...@gmail.com> wrote:

I'm really lost as to why this is failing.

file{ 'openvpn.exe':
path => 'C:/ProgramData/puppetfiles/openvpn.exe',
source => "puppet:///modules/openvpn/openvpn.exe",
owner => 'SYSTEM',
group => 'Administrators',
mode => 0770,
provider => windows,
ensure => present,
}

gives me this error:

ReplaceFile(C:/ProgramData/puppetfiles/openvpn.exe, C:/ProgramData/puppetfiles/openvpn.exe20140206-5012-wvhezn): The system cannot find the file specified.


change from absent to file failed: ReplaceFile(C:/ProgramData/puppetfiles/openvpn.exe, C:/ProgramData/puppetfiles/openvpn.exe20140206-5012-wvhezn): The system cannot find the file specified.

This is https://tickets.puppetlabs.com/browse/PUP-1389. This was due to memory corruptions in the windows gems we use (https://tickets.puppetlabs.com/browse/PUP-1368), and a ruby bug with wide-character NULLs (http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?revision=41920&view=revision) that will sometimes cause this error. This issue is resolved in the 3.4.3 release. 

For more options, visit https://groups.google.com/groups/opt_out.



--
Josh Cooper
Developer, Puppet Labs

Join us at PuppetConf 2014September 23-24 in San Francisco - http://bit.ly/pupconf14
Register now and save $350! 
Reply all
Reply to author
Forward
0 new messages