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

Error while evaluating a Virtual Query #990

Open
madelaney opened this issue Oct 11, 2018 · 14 comments
Open

Error while evaluating a Virtual Query #990

madelaney opened this issue Oct 11, 2018 · 14 comments
Labels

Comments

@madelaney
Copy link

  • Module version: 6.3.3
  • Puppet version: 4.10.12
  • OS and version: Ubuntu 16.04.5 LTS

Bug description

When applying a puppet catalog, I get the following error:

Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Virtual Query, Could not autoload puppet/type/elasticsearch_user: Could not autoload puppet/provider/elasticsearch_user/elasticsearch_users: no such file to load -- puppet/provider/elastic_user_command at /etc/puppetlabs/code/thirdparty/elasticsearch/manifests/init.pp:554:3 on node vagrant-hostname
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run

I have the following setup:

node default {
  class {
    'elasticsearch':
      plugindir        => '/usr/share/elasticsearch/plugins',
  }
}

With the following hiera config

---
elasticsearch::restart_on_change: true
elasticsearch::api_protocol: https
elasticsearch::api_host: "%{ipaddress}"
elasticsearch::api_timeout: 60
elasticsearch::api_basic_auth_username: admin
elasticsearch::api_basic_auth_password: adminpassword
elasticsearch::api_ca_file: /etc/ssl/certs
elasticsearch::api_ca_path: /etc/pki/certs
elasticsearch::validate_tls: true
elasticsearch::jvm_options:
  - '-Xms1g'
  - '-Xmx2g'
elasticsearch::security_plugin: 'x-pack'
elasticsearch::roles:
  poweruser:
    privileges:
      cluster: monitor
      indices:
        '*': all
    mappings:
    - "cn=users,dc=example,dc=com"
elasticsearch::users:
  bob:
    password: 'bob12345'
  admin:
    password: 'admin12345'
elasticsearch::instances:
  es01: {}
  es02: {}

Feature Description

@tylerjl tylerjl added the triage label Oct 11, 2018
@tylerjl
Copy link
Contributor

tylerjl commented Oct 11, 2018

Hi @madelaney, after installing the module, have you restarted any puppet master/agent processes in order to ensure those files are available? Puppet sometimes behaves unexpectedly if you update/install a module without restarting the master/agent process afterwards.

@madelaney
Copy link
Author

madelaney commented Oct 11, 2018

@tylerjl part of my capistrano deployment issues the puppetserver reload command, should that be puppetserver restart?

@madelaney
Copy link
Author

@tylerjl For what it's worth, I've tried changing puppetserver reload to puppetserver restart but to no avail.

@tylerjl
Copy link
Contributor

tylerjl commented Oct 16, 2018

Hmm, I'd perhaps double check that 1) pluginsync is enabled, 2) the module has been installed to the correct path with all files intact (including the typical lib/ path, etc.) and 3) try restarting the Puppet service via the system init manager (not just puppetserver) with systemctl or service, for example.

@marclambrichs
Copy link

marclambrichs commented Oct 18, 2018

Run a 'puppet generate types' and a 'service puppetserver restart'

@madelaney
Copy link
Author

@marclambrichs Okay, i'll give that a shot. Thanks.

@madelaney
Copy link
Author

@marclambrichs I tried to run puppet generate types but to no avail the command fails with a not very helpful message:

Error: no implicit conversion of nil into String
Error: Try 'puppet help generate types' for usage
Exit 1

@tylerjl
Copy link
Contributor

tylerjl commented Oct 22, 2018

I'm not aware of the puppet generate types command - @marclambrichs, since you seem more familiar with it, is that command necessary in order to bring in custom types in recent versions of puppet? I don't recall having to use it before.

@madelaney
Copy link
Author

@tylerjl The machine that is running puppet off of has pretty poor i/o (disk) performance. Is it possible that there's a timeout that is being swallowed somewhere?

@tylerjl
Copy link
Contributor

tylerjl commented Oct 23, 2018

@madelaney I'm not aware of i/o problems that could impact it, though maybe increasing the log verbosity could help pinpoint where in the catalog application process things are breaking.

@madelaney
Copy link
Author

madelaney commented Oct 23, 2018

@tylerjl I was running with --verbose and --test but they still yield not helpful; or so I think. For your viewing pleasure, here is the stack trace in the puppetserver.log.

@alaunay
Copy link

alaunay commented Oct 24, 2018

I'm hitting this too. 6.3.2 works, 6.3.3 gives the same error @madelaney gets.

@madelaney
Copy link
Author

I tried 6.3.2 in hopes that my scenario would mirror that of @alaunay but I still get the issue.

(After downgrading, I issued puppetserver restart)

@alaunay
Copy link

alaunay commented Oct 31, 2018

Actually, it worked for one server, but for another one I had to downgrade to 6.3.0 (or even to 6.2, I'm unsure). After that, upgrading again to the last version still worked. Very strange.

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

No branches or pull requests

4 participants