Issue #22375 has been updated by Josh Cooper.

>From Charlie Sharpsteen:

Re-produced on Centos 6.3 w/ Puppet 3.1.1. Used the following site.pp:

<pre>
node 'puppetagent.boxnet' {
  filebucket { 'bkup':
    server => 'puppetmaster.boxnet',
    path   => false,
  }

  File { backup => 'bkup' }

  file { '/usr/local/puppet':
    ensure => directory,
    purge => true,
    recurse => true,
  }
}
</pre>

Then, copied the contents of /usr/bin/* to /usr/local/puppet/. puppet agent 
dutifully purged each binary and sent copies up to the master for backup. 
However, when the agent reached emacs, it croaked with the regexp buffer 
overflow from the server while executing the save method in the indirector 
against—-exactly as reported earlier. The URI being accessed was:

<pre>
/production/file_bucket_file/md5/8db5f58ee234bb1b366aecb061604e97//usr/local/puppet/emacs
</pre>

Here is the server log with --trace:

<pre>
Mon Apr 08 12:20:27 -0700 2013 Puppet (info): Could not find file_bucket_file 
for 'md5/8db5f58ee234bb1b366aecb061604e97/usr/local/puppet/emacs'
Mon Apr 08 12:20:35 -0700 2013 Puppet (err): Could not intern from pson: Caught 
StringScanner::Error: regexp buffer overflow
/usr/lib/ruby/site_ruby/1.8/puppet/external/pson/pure/parser.rb:153:in 
`parse_string'
/usr/lib/ruby/site_ruby/1.8/puppet/external/pson/pure/parser.rb:168:in 
`parse_value'
/usr/lib/ruby/site_ruby/1.8/puppet/external/pson/pure/parser.rb:232:in 
`parse_object'
/usr/lib/ruby/site_ruby/1.8/puppet/external/pson/pure/parser.rb:97:in `parse'
/usr/lib/ruby/site_ruby/1.8/puppet/external/pson/common.rb:133:in `parse'
/usr/lib/ruby/site_ruby/1.8/puppet/network/formats.rb:105:in `intern'
/usr/lib/ruby/site_ruby/1.8/puppet/network/format_handler.rb:12:in `send'
/usr/lib/ruby/site_ruby/1.8/puppet/network/format_handler.rb:12:in `protect'
/usr/lib/ruby/site_ruby/1.8/puppet/network/format_handler.rb:26:in `intern'
/usr/lib/ruby/site_ruby/1.8/puppet/network/format_handler.rb:108:in 
`convert_from'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/handler.rb:167:in `do_save'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/handler.rb:71:in `send'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/handler.rb:71:in `process'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/webrick/rest.rb:24:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/webrick.rb:33:in `listen'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `call'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/webrick.rb:30:in `listen'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/webrick.rb:29:in `initialize'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/webrick.rb:29:in `new'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/webrick.rb:29:in `listen'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/webrick.rb:26:in `synchronize'
/usr/lib/ruby/site_ruby/1.8/puppet/network/http/webrick.rb:26:in `listen'
/usr/lib/ruby/site_ruby/1.8/puppet/network/server.rb:92:in `listen'
/usr/lib/ruby/site_ruby/1.8/puppet/network/server.rb:104:in `start'
/usr/lib/ruby/site_ruby/1.8/puppet/daemon.rb:136:in `start'
/usr/lib/ruby/site_ruby/1.8/puppet/application/master.rb:207:in `main'
/usr/lib/ruby/site_ruby/1.8/puppet/application/master.rb:157:in `run_command'
/usr/lib/ruby/site_ruby/1.8/puppet/application.rb:364:in `run'
/usr/lib/ruby/site_ruby/1.8/puppet/application.rb:456:in `plugin_hook'
/usr/lib/ruby/site_ruby/1.8/puppet/application.rb:364:in `run'
/usr/lib/ruby/site_ruby/1.8/puppet/util.rb:504:in `exit_on_fail'
/usr/lib/ruby/site_ruby/1.8/puppet/application.rb:364:in `run'
/usr/lib/ruby/site_ruby/1.8/puppet/util/command_line.rb:132:in `run'
/usr/lib/ruby/site_ruby/1.8/puppet/util/command_line.rb:86:in `execute'
/usr/bin/puppet:4
Mon Apr 08 12:20:35 -0700 2013 Puppet (debug): Finishing transaction -611259548
Mon Apr 08 12:20:35 -0700 2013 Puppet (debug): Received report to process from 
puppetagent.boxnet
Mon Apr 08 12:20:35 -0700 2013 Puppet (debug): Processing report from 
puppetagent.boxnet with processor Puppet::Reports::Store
</pre>

The odd thing about this bug is that 833 other files from /usr/bin were 
successfully backed up and deleted. Emacs was the only executable that Puppet 
had a problem with. Emacs was also the largest executable at 6.1 MB—-the second 
largest executable was 3.2 MB and was deleted successfully.

Will poke around some more.

----------------------------------------
Bug #22375: (#8229) File bucket and Puppet File resource: fails with "regexp 
buffer overflow" when backing up binary file
https://projects.puppetlabs.com/issues/22375#change-97071

* Author: Josh Cooper
* Status: Accepted
* Priority: Normal
* Assignee: Josh Cooper
* Category: 
* Target version: 
* Affected Puppet version: 2.6.0
* Keywords: puppet inspect upload archive customer
* Branch: 
----------------------------------------
This is a duplicate of bug #8229, which I accidentally deleted.

When uploading files using puppet inspect I often get this on the managed node 
side of the equation:

<pre>
/usr/lib/ruby/1.8/timeout.rb:64:in `rbuf_fill': execution expired 
(Timeout::Error)
        from /usr/lib/ruby/1.8/net/protocol.rb:134:in `rbuf_fill'
        from /usr/lib/ruby/1.8/net/protocol.rb:116:in `readuntil'
        from /usr/lib/ruby/1.8/net/protocol.rb:126:in `readline'
        from /usr/lib/ruby/1.8/net/http.rb:2028:in `read_status_line'
        from /usr/lib/ruby/1.8/net/http.rb:2017:in `read_new'
        from /usr/lib/ruby/1.8/net/http.rb:1051:in `request'
        from /usr/lib/ruby/1.8/net/http.rb:1037:in `request'
        from /usr/lib/ruby/1.8/net/http.rb:543:in `start'
        from /usr/lib/ruby/1.8/net/http.rb:1035:in `request'
        from /usr/lib/ruby/1.8/net/http.rb:857:in `put'
        from /usr/lib/ruby/site_ruby/1.8/puppet/indirector/rest.rb:107:in `save'
        from 
/usr/lib/ruby/site_ruby/1.8/puppet/indirector/indirection.rb:264:in `save'
        from /usr/lib/ruby/site_ruby/1.8/puppet/indirector.rb:68:in `save'
        from /usr/lib/ruby/site_ruby/1.8/puppet/file_bucket/dipper.rb:43:in 
`backup'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application/inspect.rb:157:in 
`run_command'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application/inspect.rb:117:in 
`each'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application/inspect.rb:117:in 
`run_command'
        from /usr/lib/ruby/site_ruby/1.8/puppet/util.rb:193:in `benchmark'
        from /usr/lib/ruby/1.8/benchmark.rb:308:in `realtime'
        from /usr/lib/ruby/site_ruby/1.8/puppet/util.rb:192:in `benchmark'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application/inspect.rb:101:in 
`run_command'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application.rb:305:in `run'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application.rb:420:in `hook'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application.rb:305:in `run'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application.rb:411:in 
`exit_on_fail'
        from /usr/lib/ruby/site_ruby/1.8/puppet/application.rb:305:in `run'
        from /usr/lib/ruby/site_ruby/1.8/puppet/util/command_line.rb:62:in 
`execute'
        from /usr/bin/puppet:4
</pre>

On the master side, I saw this error message but did not have trace enabled:

<pre>
err: Could not intern from pson: regexp buffer overflow
</pre>


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to