2016-01-22 45 views
0

厨师使用配方redisio安装Redis期间出现以下错误。你能帮我找个理由厨师:在资源'redisio_configure [redis-servers]上执行操作'运行''错误'

Recipe: redisio::configure 
    * redisio_configure[redis-servers] action run 

    ================================================================================ 
    Error executing action `run` on resource 'redisio_configure[redis-servers]' 
    ================================================================================ 

    TypeError 
    --------- 
    no implicit conversion of Fixnum into String 

    Cookbook Trace: 
    --------------- 
    /var/chef/cache/cookbooks/redisio/providers/configure.rb:87:in `+' 
    /var/chef/cache/cookbooks/redisio/providers/configure.rb:87:in `block in configure' 
    /var/chef/cache/cookbooks/redisio/providers/configure.rb:38:in `each' 
    /var/chef/cache/cookbooks/redisio/providers/configure.rb:38:in `configure' 
    /var/chef/cache/cookbooks/redisio/providers/configure.rb:22:in `block in class_from_file' 

    Resource Declaration: 
    --------------------- 
    # In /var/chef/cache/cookbooks/redisio/recipes/configure.rb 

     30: redisio_configure "redis-servers" do 
     31: version redis['version'] if redis['version'] 
     32: default_settings redis['default_settings'] 
     33: servers redis_instances 
     34: base_piddir redis['base_piddir'] 
     35: end 
     36: 

    Compiled Resource: 
    ------------------ 
    # Declared in /var/chef/cache/cookbooks/redisio/recipes/configure.rb:30:in `from_file' 

    redisio_configure("redis-servers") do 
     action :run 
     retries 0 
     retry_delay 2 
     default_guard_interpreter :default 
     declared_type :redisio_configure 
     cookbook_name "redisio" 
     recipe_name "configure" 
     version "2.8.17" 
     default_settings {"user"=>"redis", "group"=>"redis", "homedir"=>"/redis", "shell"=>"/bin/sh", "systemuser"=>true, "ulimit"=>0, "configdir"=>"/etc/redis", "name"=>nil, "address"=>nil, "databases"=>"16", "backuptype"=>"rdb", "datadir"=>"/var/lib/redis", "unixsocket"=>nil, "unixsocketperm"=>nil, "timeout"=>"0", "keepalive"=>"0", "loglevel"=>"notice", "logfile"=>nil, "syslogenabled"=>"yes", "syslogfacility"=>"local0", "shutdown_save"=>false, "save"=>nil, "stopwritesonbgsaveerror"=>"yes", "slaveof"=>nil, "masterauth"=>nil, "slaveservestaledata"=>"yes", "replpingslaveperiod"=>"10", "repltimeout"=>"60", "requirepass"=>"password", "maxclients"=>"512", "maxmemory"=>"1073741824", "maxmemorypolicy"=>nil, "maxmemorysamples"=>nil, "appendfsync"=>"everysec", "noappendfsynconrewrite"=>"no", "aofrewritepercentage"=>"100", "aofrewriteminsize"=>"64mb", "luatimelimit"=>"5000", "slowloglogslowerthan"=>"10000", "slowlog-max-len"=>"1024", "notifykeyspaceevents"=>"", "hashmaxziplistentries"=>"512", "hashmaxziplistvalue"=>"64", "setmaxintsetentries"=>"512", "zsetmaxziplistentries"=>"128", "zsetmaxziplistvalue"=>"64", 
"activerehasing"=>"yes", "clientoutputbufferlimit"=>[["normal", "0", "0", "0"], ["slave", "256mb", "64mb", "60"], ["pubsub", "32mb", "8mb", "60"]], "hz"=>"10", "aofrewriteincrementalfsync"=>"yes", "cluster-enabled"=>"no", "cluster-config-file"=>nil, "cluster-node-timeout"=>5, "includes"=>nil, "maxmemory-policy"=>"volatile-lru"} 
     servers [{"port"=>"6379"}] 
     base_piddir "/var/run/redis" 
    end 


Running handlers: 
[2016-01-22T09:38:44+00:00] ERROR: Running exception handlers 
Running handlers complete 
[2016-01-22T09:38:44+00:00] ERROR: Exception handlers complete 
Chef Client failed. 1 resources updated in 12 seconds 
[2016-01-22T09:38:44+00:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out 
[2016-01-22T09:38:44+00:00] FATAL: Please provide the contents of the stacktrace.out file if you file a bug report 
[2016-01-22T09:38:44+00:00] ERROR: redisio_configure[redis-servers] (redisio::configure line 30) had an error: TypeError: no implicit conversion of Fixnum into String 
[2016-01-22T09:38:44+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1) 

谢谢

回答

1

你有"maxclients"=>"512",与值的字符串。这应该是一个整数,即"maxclients"=>512。修复它在你的节点属性。