Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined method 'unified_mode' #577

Closed
sbrennan4 opened this issue Jun 25, 2021 · 2 comments
Closed

undefined method 'unified_mode' #577

sbrennan4 opened this issue Jun 25, 2021 · 2 comments
Milestone

Comments

@sbrennan4
Copy link

sbrennan4 commented Jun 25, 2021

After upgrading to v5.9.0 we get

WARN: Deprecation CHEF-25 from /var/chef/cache/cookbooks/sysctl/resources/param.rb:27:in `class_from_file'

Resource sysctl from a cookbook is overriding the resource from the client. Please upgrade your cookbook or remove the cookbook from your run_list before the next major release of Chef.

Please see https://docs.chef.io/deprecations_map_collision.html for further details and information on how to correct this problem.

================================================================================
Recipe Compile Error in /var/chef/cache/cookbooks/rabbitmq/resources/cluster.rb
================================================================================

NoMethodError
-------------
undefined method `unified_mode' for #<Class:0x0000000003d6eab8>

Cookbook Trace:
---------------
  /var/chef/cache/cookbooks/rabbitmq/resources/cluster.rb:22:in `class_from_file'

Relevant File Content:
----------------------
/var/chef/cache/cookbooks/rabbitmq/resources/cluster.rb:

 15:  # Unless required by applicable law or agreed to in writing, software
 16:  # distributed under the License is distributed on an "AS IS" BASIS,
 17:  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 18:  # See the License for the specific language governing permissions and
 19:  # limitations under the License.
 20:  #
 21:  
 22>> unified_mode true
 23:  
 24:  actions :join, :set_cluster_name, :change_cluster_node_type
 25:  
 26:  default_action :join
 27:  
 28:  attribute :cluster_nodes, :kind_of => String, :name_attribute => true # first node name to join
 29:  attribute :cluster_name,  :kind_of => String                          # cluster name
 30:  

System Info:
------------
chef_version=14.10.9
platform=ubuntu
platform_version=14.04
ruby=ruby 2.5.3p105 (2018-10-18 revision 65156) [x86_64-linux]
program_name=/usr/bin/chef-client
executable=/opt/chef/bin/chef-client

We also depend on the hadoop cookbook which depends on sysctl so we cannot remove it.

Should unified_mode be handled like it is here? https://github.com/chef-cookbooks/chef-client/blob/0fed4b410886894b67132251dbe56cd216d58b11/resources/launchd.rb#L13

@michaelklishin michaelklishin added this to the 5.9.1 milestone Jun 25, 2021
@michaelklishin
Copy link
Member

sysctl only emits a warning, the real issue was that Chef 14 which you run does not provide unified_mode.

@michaelklishin
Copy link
Member

5.9.1 is out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants