Azure / Azure/azure-quickstart-templates
Error enabling chef-client service - no such file rb_sysopen /etc/chef/client.rb
- Dominant language
- Bicep
- Stars
- 14.9k
- Forks
- 16.2k
- Avg merge
- 6d 21h
- Merged PRs (30d)
- 6
Description
[chef-json-parameters-linux-vm](https://github.com/Azure/azure-quickstart-templates/tree/master/chef-json-parameters-linux-vm)
### Issue Details
Hello. I can't seem to get anything to work with the 'LinuxChefExtension' example in this template. When generating just a plain (empty) vm and removing the 'LinuxChefExtension' resource block (and associated variables/parameters) the same settings work to generate a vm. Note that with the 'LinuxChefExtension' settings included a vm is created, but then errors out I presume when trying to bootstrap the node. What is befuddling is that the error indicates there is no '/etc/chef/client.rb' file, when there is and is readable. Been tearing my hair out, any assistance greatly appreciated.
[From ~/.azure/azure.err:]
Error message: "chef-service enable failed - "Error enabling chef-client service - No such file or directory @ rb_sysopen - /etc/chef/client.rb - Check log file for details"
### Repro steps (_if necessary, delete otherwise_)
1. azuredeploy.json & azuredeploy.parameters.json with placeholders/params/variables set
2. Login via 'azure login', set correct account, and execute: 'azure group deployment create -g MY_RESOURCE_GROUP -n "my-vmname-01" -v -f azuredeploy.json -e azuredeploy.parameters.json'
3. After failing, view ~/.azure/azure.err
## MORE INFO:
/etc/chef/client.rb:
log_level :info
log_location STDOUT
chef_server_url 'https://chef-armdev-01:443/organizations/testorg'
validation_client_name 'testorg-validator'
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the chef-json-parameters-linux-vm template, especially azuredeploy.json and azuredeploy.parameters.json, then inspect ~/.azure/azure.err and the LinuxChefExtension deployment sequence. Reproduce the deployment with the documented azure group deployment command and verify that /etc/chef/client.rb is available when the chef-client service is enabled; done means the VM deployment and service setup complete successfully.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, linux
- Domain
- cloud, infrastructure
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100