Comments (13)
This looks very similar to the following error in:
from puppet-module-sensuclassic.
Can you provide your Puppet code where you setup the sensuclassic classes and any hiera data? Feel free to replace sensitive information with fake data. I would like to try and reproduce this issue locally.
What version of Windows is this happening on?
from puppet-module-sensuclassic.
Hello @treydock I have attached how we are calling the class for sensuclassic with params you can replace with required strings. I have stripped out some non-required params so have done my best to leave all you should need.
I have tested this issue on Windows Server 2012R2 and Windows Server 2016.
Sensu_Class.txt
from puppet-module-sensuclassic.
Do you have something special configured for chocolatey to work? I am unable to install Sensu through Chocolatey. When I go to chocolatey website the only options for Sensu I see are for Sensu Go (sensu-agent and sensu-cli). Are you maybe using some kind of custom chocolately repo or custom chocolatey config? This is error I get:
Error: Execution of 'C:\ProgramData\chocolatey\choco.exe install Sensu -y --ign
ore-package-exit-codes --no-progress' returned 1: Chocolatey v0.10.15
Installing the following packages:
Sensu
By installing you accept licenses for the packages.
Sensu not installed. The package was not found with the source(s) listed.
Source(s): 'https://chocolatey.org/api/v2/'
NOTE: When you specify explicit sources, it overrides default sources.
If the package version is a prerelease and you didn't specify `--pre`,
the package may not be found.
Please see https://chocolatey.org/docs/troubleshooting for more
assistance.
Chocolatey installed 0/1 packages. 1 packages failed.
See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
Failures
- Sensu - Sensu not installed. The package was not found with the source(s) lis
ted.
Source(s): 'https://chocolatey.org/api/v2/'
NOTE: When you specify explicit sources, it overrides default sources.
If the package version is a prerelease and you didn't specify `--pre`,
the package may not be found.
Please see https://chocolatey.org/docs/troubleshooting for more
from puppet-module-sensuclassic.
Hello @treydock we internalise packages from chocolately into our internal repo whereby that repo is added as a source when the chocolately packages are installed.
I have just checked though and you are right there is only Sensu Go so we have downloaded the client from Sensu themselves from https://eol-repositories.sensuapp.org/msi/2016/ and created the chocolately package from their msi using the chocolately package builder gui. We used the default options within that GUI so just a right click, create, build package and then uploaded to our internal repo.
from puppet-module-sensuclassic.
@StuartMcManus We just released v3.6.1. Could you give that a try and let us know if it addresses the issue.
from puppet-module-sensuclassic.
Hello @ghoneycutt sorry I have not had a chance to test yet but will pick Monday to test out.
from puppet-module-sensuclassic.
Hello @ghoneycutt I have tested using the new release 3.6.1 but it still comes up with the same error.
from puppet-module-sensuclassic.
@StuartMcManus Based on the errors you got its almost as if the Chocolatey package is installing the needed service and then the DSC service in the Puppet module is failing to to properly install the service or detect the existence of the service in same puppet run. I don't have the ability to test with Chocolately packages so I'm not sure I can reproduce this issue. One thing we can do to troubleshoot is you can modify this module on your local system and see if commenting out the following lines solves the problem:
https://github.com/sensu/puppet-module-sensuclassic/blob/master/manifests/client.pp#L75-L88
Also:
Change these two lines to use Service['sensu-client']
instead of Dsc_service['sensu-client']
:
https://github.com/sensu/puppet-module-sensuclassic/blob/master/manifests/client.pp#L57
https://github.com/sensu/puppet-module-sensuclassic/blob/master/manifests/client.pp#L68
If your able to share how you add the chocolately package and possibly make the chocolatey package available to me I can try debugging this locally.
from puppet-module-sensuclassic.
Hello @treydock this is happening after the service is installed correctly by DSC and working, whereby I then stop the service and run puppet to try and start it again. Chocolately just puts down the the files doing a standard msi install and puppet sensuclassic module creates the service using DSC.
Chocolatey for you doesn't need to be factored in as it just puts down the files you can just manually install and run puppet to setup the service for you. The problem is purely to do with the DSC_Service resource within the sensuclassic module not detecting the service correctly when the service is stopped which sounds a like it then sees it as absent but when the service is running it does not have an issue.
from puppet-module-sensuclassic.
Hello @treydock just checking if you have had a chance to test out with a standard install using the package resource and puppet trying to start the service?
from puppet-module-sensuclassic.
I can reproduce the issue and honestly have no idea how to fix the problem, it's likely a bug or misconfiguration with the DSC Puppet module. I think I may be able to come up with a way to get rid of the dsc_service
resource all together and instead install the Windows service the way Sensu documents installing the service.
Thus far what I've observed is what I think you saw and that's if sensu-client
service is stopped, the dsc_service
resource throws errors. Manually starting the service and then running Puppet produces no errors but that's not a solution.
from puppet-module-sensuclassic.
@StuartMcManus Can you try the changes in #35 and let me know if that resolves your issue?
from puppet-module-sensuclassic.
Related Issues (9)
- Ubuntu 14.04 LTS is EOL
- Feature request: Add ability to have configuration changes reload sensu-enterprise instead issuing a restart
- sensuclassic_sorted_json HOT 1
- undefined method `pretty_generate' for Puppet::Pops::Loader::RubyFunctionInstantiator::JSON:Module HOT 3
- deprecated `validate_bool()` function HOT 2
- Service started before config applied HOT 4
- Windows client value set to false throws puppet run error HOT 4
- Document that client custom property will filter out keys for other properties HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from puppet-module-sensuclassic.