Kintyre / ksconf

Kintyre's Splunk Configuration tool
Apache License 2.0
50 stars 13 forks source link

Error displayed on execution - ValueError: unsupported hash type sha1 #68

Closed jonesy1234 closed 4 years ago

jonesy1234 commented 4 years ago

The problem

When running ksconf the following error is displayed.

ERROR:root:code for hash sha1 was not found.
Traceback (most recent call last):
  File "/opt/splunk/lib/python2.7/hashlib.py", line 147, in <module>
    globals()[__func_name] = __get_hash(__func_name)
  File "/opt/splunk/lib/python2.7/hashlib.py", line 97, in __get_builtin_constructor
    raise ValueError('unsupported hash type ' + name)
ValueError: unsupported hash type sha1

Environment

Details

This is a fresh installation so I'm not sure what further details I can provide. KSCONF_DEBUG=1 doesn't display anymore detail other than the output below. As I'm using the python version from with the splunk app I'm assuming this is not an OS level issue?

[splunk]$ /opt/splunk/bin/splunk cmd python /opt/splunk/etc/apps/ksconf/bin/install.py
ksconf_app: /opt/splunk/etc/apps/ksconf/bin
Writing script /opt/splunk/bin/ksconf
Try running 'ksconf --version' to ensure that install worked correctly.
[splunk]$ ksconf --version
-bash: ksconf: command not found
[splunk]$ /opt/splunk/bin/ksconf --version
ERROR:root:code for hash sha1 was not found.
Traceback (most recent call last):
  File "/opt/splunk/lib/python2.7/hashlib.py", line 147, in <module>
    globals()[__func_name] = __get_hash(__func_name)
  File "/opt/splunk/lib/python2.7/hashlib.py", line 97, in __get_builtin_constructor
    raise ValueError('unsupported hash type ' + name)
ValueError: unsupported hash type sha1
                                  #
                                  ##
 ###  ##     #### ###### #######  ###  ##  #######
 ### ##     ###  ###           ## #### ##
 #####      ###  ###      ##   ## #######  #######
 ### ##     ###  ###      ##   ## ### ###  ##
 ###  ## #####    ######   #####  ###  ##  ##
                                        #

ksconf 0.7.6  (Build 435)
Python: 2.7.15  (/opt/splunk/bin/python)
Git SHA1 cf0cd07d committed on 2019-08-15
Installed at: /opt/splunk/etc/apps/ksconf/bin/lib/ksconf
Written by Lowell Alleman <lowell@kintyre.co>.
Copyright (c) 2019 Kintyre Solutions, Inc, all rights reserved.
Licensed under Apache Public License v2

    Commands:
      check           (stable)    OK
      combine         (beta)      OK
      diff            (stable)    OK
      filter          (alpha)     OK
      merge           (stable)    OK
      minimize        (beta)      OK
      promote         (beta)      OK
      rest-export     (beta)      OK
      rest-publish    (alpha)     Missing 3rd party module:  libssl.so.1.0.0: cannot open shared object file: No such file or directory
      snapshot        (alpha)     OK
      sort            (stable)    OK
      unarchive       (beta)      OK
      xml-format      (alpha)     OK   (lxml 4.3.0)

Steps To Reproduce Issue

  1. Splunk version 7.3.3 installation on Oracle Linux 7
  2. Install via SplunkBase
  3. Run any ksconf command

Thanks

jonesy1234 commented 4 years ago

Found a reference to this and a fix. Closing. Thanks!

lowell80 commented 4 years ago

Thanks for the full bug report! I'm assuming the fix you found was related to #48? Did you resolve this by simply calling setSplunkEnv or come up with another fix/workaround? I'd like to improve the user experience, but I'm not 100% sure what would work best.

Thanks for trying out ksconf and taking the time to file a bug report!

jonesy1234 commented 4 years ago

Hey thanks for getting in touch. Great tool you have built here I think Splunk really need to integrate version control within the core app but doesn’t seem to be coming any time soon....

Running through splunk cmd works best for me as I’m planning on merging local to default changes through from a power users splunk host via an ansible playbook, checkin to git and trigger CI/CD to promote bundle across our search head cluster.

We host our shcluster apps in CodeCommit and have a CloudWatch event trigger to run the bundle deploy via ansible. On the power user splunk host these apps are checked out and symlinked to etc/apps.

Anyway blog post coming soon... I’ll make sure I give your great work a shout out 😉

Many thanks 👍

Sent from my iPhone

On 16 Jan 2020, at 2:38 am, Lowell Alleman notifications@github.com wrote:

 Thanks for the full bug report! I'm assuming the fix you found was related to #48? Did you resolve this by simply calling setSplunkEnv or come up with another fix/workaround? I'd like to improve the end-use experience here, but I'm not 100% sure what would work best.

Thanks for trying out ksconf and taking the time to file a bug report!

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or unsubscribe.

brian-kennedy commented 4 years ago

Hi Steven,

I'm glad you are seeing the value of KSCONF. To help us promote the tool, how did you come across it? I want to assume Splunkbase?

-- BRIAN KENNEDY kintyre http://kintyre.co/. Splunk Expertise & System Craftsmanship. (302) 482-4571 | about.me/brian.m.kennedy Splunk Certified Architect and Sales Engineer, AWS Certified Architect

On Wed, Jan 15, 2020 at 3:37 PM Stephen Jones notifications@github.com wrote:

Hey thanks for getting in touch. Great tool you have built here I think Splunk really need to integrate version control within the core app but doesn’t seem to be coming any time soon....

Running through splunk cmd works best for me as I’m planning on merging local to default changes through from a power users splunk host via an ansible playbook, checkin to git and trigger CI/CD to promote bundle across our search head cluster.

We host our shcluster apps in CodeCommit and have a CloudWatch event trigger to run the bundle deploy via ansible. On the power user splunk host these apps are checked out and symlinked to etc/apps.

Anyway blog post coming soon... I’ll make sure I give your great work a shout out 😉

Many thanks 👍

Sent from my iPhone

On 16 Jan 2020, at 2:38 am, Lowell Alleman notifications@github.com wrote:

 Thanks for the full bug report! I'm assuming the fix you found was related to #48? Did you resolve this by simply calling setSplunkEnv or come up with another fix/workaround? I'd like to improve the end-use experience here, but I'm not 100% sure what would work best.

Thanks for trying out ksconf and taking the time to file a bug report!

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or unsubscribe.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/Kintyre/ksconf/issues/68?email_source=notifications&email_token=ABADWJ4AILO5VDXXKDXCVXTQ55XY3A5CNFSM4KG6JNJKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJBXEZY#issuecomment-574845543, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABADWJ7H5ZNSNCLRL3PUE7LQ55XY3ANCNFSM4KG6JNJA .

jonesy1234 commented 4 years ago

Afraid not, it was via google when searching how the hell others had done this sort of thing managing app config in git. Found the presentation/talk that was done.

Cheers

Sent from my iPhone

On 16 Jan 2020, at 11:40 pm, Brian Kennedy notifications@github.com wrote:

Hi Steven,

I'm glad you are seeing the value of KSCONF. To help us promote the tool, how did you come across it? I want to assume Splunkbase?

-- BRIAN KENNEDY kintyre http://kintyre.co/. Splunk Expertise & System Craftsmanship. (302) 482-4571 | about.me/brian.m.kennedy Splunk Certified Architect and Sales Engineer, AWS Certified Architect

On Wed, Jan 15, 2020 at 3:37 PM Stephen Jones notifications@github.com wrote:

Hey thanks for getting in touch. Great tool you have built here I think Splunk really need to integrate version control within the core app but doesn’t seem to be coming any time soon....

Running through splunk cmd works best for me as I’m planning on merging local to default changes through from a power users splunk host via an ansible playbook, checkin to git and trigger CI/CD to promote bundle across our search head cluster.

We host our shcluster apps in CodeCommit and have a CloudWatch event trigger to run the bundle deploy via ansible. On the power user splunk host these apps are checked out and symlinked to etc/apps.

Anyway blog post coming soon... I’ll make sure I give your great work a shout out 😉

Many thanks 👍

Sent from my iPhone

On 16 Jan 2020, at 2:38 am, Lowell Alleman notifications@github.com wrote:

 Thanks for the full bug report! I'm assuming the fix you found was related to #48? Did you resolve this by simply calling setSplunkEnv or come up with another fix/workaround? I'd like to improve the end-use experience here, but I'm not 100% sure what would work best.

Thanks for trying out ksconf and taking the time to file a bug report!

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or unsubscribe.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/Kintyre/ksconf/issues/68?email_source=notifications&email_token=ABADWJ4AILO5VDXXKDXCVXTQ55XY3A5CNFSM4KG6JNJKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJBXEZY#issuecomment-574845543, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABADWJ7H5ZNSNCLRL3PUE7LQ55XY3ANCNFSM4KG6JNJA .

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or unsubscribe.

brian-kennedy commented 4 years ago

Thanks for the feedback!

-- Brian Kennedy (302)482-4571

On Jan 16, 2020, at 3:47 PM, Stephen Jones notifications@github.com wrote:

Afraid not, it was via google when searching how the hell others had done this sort of thing managing app config in git. Found the presentation/talk that was done.

Cheers

Sent from my iPhone

On 16 Jan 2020, at 11:40 pm, Brian Kennedy notifications@github.com wrote:

Hi Steven,

I'm glad you are seeing the value of KSCONF. To help us promote the tool, how did you come across it? I want to assume Splunkbase?

-- BRIAN KENNEDY kintyre http://kintyre.co/. Splunk Expertise & System Craftsmanship. (302) 482-4571 | about.me/brian.m.kennedy Splunk Certified Architect and Sales Engineer, AWS Certified Architect

On Wed, Jan 15, 2020 at 3:37 PM Stephen Jones notifications@github.com wrote:

Hey thanks for getting in touch. Great tool you have built here I think Splunk really need to integrate version control within the core app but doesn’t seem to be coming any time soon....

Running through splunk cmd works best for me as I’m planning on merging local to default changes through from a power users splunk host via an ansible playbook, checkin to git and trigger CI/CD to promote bundle across our search head cluster.

We host our shcluster apps in CodeCommit and have a CloudWatch event trigger to run the bundle deploy via ansible. On the power user splunk host these apps are checked out and symlinked to etc/apps.

Anyway blog post coming soon... I’ll make sure I give your great work a shout out 😉

Many thanks 👍

Sent from my iPhone

On 16 Jan 2020, at 2:38 am, Lowell Alleman notifications@github.com wrote:

 Thanks for the full bug report! I'm assuming the fix you found was related to #48? Did you resolve this by simply calling setSplunkEnv or come up with another fix/workaround? I'd like to improve the end-use experience here, but I'm not 100% sure what would work best.

Thanks for trying out ksconf and taking the time to file a bug report!

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or unsubscribe.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/Kintyre/ksconf/issues/68?email_source=notifications&email_token=ABADWJ4AILO5VDXXKDXCVXTQ55XY3A5CNFSM4KG6JNJKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJBXEZY#issuecomment-574845543, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABADWJ7H5ZNSNCLRL3PUE7LQ55XY3ANCNFSM4KG6JNJA .

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub, or unsubscribe. — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.