REMnux / remnux-cli

This repository contains the source code for the REMnux installer, which is the command-line tool for installing and upgrading the REMnux distro.
https://REMnux.org
MIT License
38 stars 11 forks source link

Running 'remnux upgrade' keeps failing #136

Closed Cr4wlerx closed 5 months ago

Cr4wlerx commented 1 year ago

Hello,

mind checking the saltstack log and see what goes wrong with this update.

saltstack.log

i updated twice and this is the second times clean log. as i noticed some repositories were corrected in the first update. but still cant complete it.

image

thank you.

digitalsleuth commented 1 year ago

Hi @Cr4wlerx , it looks like there was an issue installing Volatility 3, but I'm not sure yet what might have caused it. Everything else has installed correctly though and should work fine. I'll take a look at this issue and get back to you!

Cr4wlerx commented 1 year ago

thanx, i will wait for further info. since some one else might have this issue at the moment.

i managed to go the install from scratch route and finished successfully.

BoBeR182 commented 1 year ago

I have the same issue with volatility3 saltstack.log

digitalsleuth commented 1 year ago

Hi @BoBeR182 , I haven't been able to duplicate the volatility issue, however I did notice that you had some connectivity issues while installing. If you tried this a few days ago, I would recommend trying again now after checking that you have no connectivity issues, as we've recently upgraded a couple of states, including the "pip" state.

Additionally, if you are behind a proxy, you might want to visit the documentation to learn how to configure REMnux for use / installation behind a proxy.

BoBeR182 commented 1 year ago
/usr/bin/salt-call:6: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
  from pkg_resources import load_entry_point
[DEBUG   ] Missing configuration file: /etc/salt/minion
[DEBUG   ] Using cached minion ID from /etc/salt/minion_id: remnux
[DEBUG   ] Using importlib_metadata to load entry points
[ERROR   ] 'EntryPoints' object has no attribute 'items'
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/salt/utils/parsers.py", line 210, in parse_args
    mixin_after_parsed_func(self)
  File "/usr/lib/python3/dist-packages/salt/utils/parsers.py", line 887, in __setup_extended_logging
    log.setup_extended_logging(self.config)
  File "/usr/lib/python3/dist-packages/salt/log/setup.py", line 414, in setup_extended_logging
    providers = salt.loader.log_handlers(opts)
  File "/usr/lib/python3/dist-packages/salt/loader/__init__.py", line 686, in log_handlers
    _module_dirs(
  File "/usr/lib/python3/dist-packages/salt/loader/__init__.py", line 148, in _module_dirs
    for entry_point in entrypoints.iter_entry_points("salt.loader"):
  File "/usr/lib/python3/dist-packages/salt/utils/entrypoints.py", line 43, in _wrapped
    return f(*args, **kwargs)
  File "/usr/lib/python3/dist-packages/salt/utils/entrypoints.py", line 62, in iter_entry_points
    for entry_point_group, entry_points_list in entry_points.items():
AttributeError: 'EntryPoints' object has no attribute 'items'
Usage: salt-call [options] <function> [arguments]

salt-call: error: Error while processing <function LogLevelMixIn.__setup_extended_logging at 0x7f413bd039d0>: Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/salt/utils/parsers.py", line 210, in parse_args
    mixin_after_parsed_func(self)
  File "/usr/lib/python3/dist-packages/salt/utils/parsers.py", line 887, in __setup_extended_logging
    log.setup_extended_logging(self.config)
  File "/usr/lib/python3/dist-packages/salt/log/setup.py", line 414, in setup_extended_logging
    providers = salt.loader.log_handlers(opts)
  File "/usr/lib/python3/dist-packages/salt/loader/__init__.py", line 686, in log_handlers
    _module_dirs(
  File "/usr/lib/python3/dist-packages/salt/loader/__init__.py", line 148, in _module_dirs
    for entry_point in entrypoints.iter_entry_points("salt.loader"):
  File "/usr/lib/python3/dist-packages/salt/utils/entrypoints.py", line 43, in _wrapped
    return f(*args, **kwargs)
  File "/usr/lib/python3/dist-packages/salt/utils/entrypoints.py", line 62, in iter_entry_points
    for entry_point_group, entry_points_list in entry_points.items():
AttributeError: 'EntryPoints' object has no attribute 'items'

Just tried to remnux upgrade

BoBeR182 commented 1 year ago

sudo pip install 'importlib_metadata==4.13.0' Fixed my above issue, and I am fully updated now.

jdk32f2 commented 1 year ago

sudo pip install 'importlib_metadata==4.13.0' Fixed my above issue, and I am fully updated now.

I've been having the same exact error and this fixed it for me. Thank you

geeksailor commented 1 year ago

For those of you who are attempting to run the remnux update command but getting the error return:

Update returned exit code not zero Error: Update returned exit code not zero at ChildProcess. (/snapshot/remnux-cli/remnux-cli.js:569:23) at ChildProcess.emit (events.js:315:20) at maybeClose (internal/child_process.js:1021:16) at Socket. (internal/child_process.js:443:11) at Socket.emit (events.js:315:20) at Pipe. (net.js:674:12)

and seeing the following in your saltstack.log for the reason

[DEBUG ] Missing configuration file: /etc/salt/minion [DEBUG ] Using cached minion ID from /etc/salt/minion_id: remnux [DEBUG ] Using importlib_metadata to load entry points [ERROR ] 'EntryPoints' object has no attribute 'items' Traceback (most recent call last): File "/usr/lib/python3/dist-packages/salt/utils/parsers.py", line 210, in parse_args mixin_after_parsed_func(self) File "/usr/lib/python3/dist-packages/salt/utils/parsers.py", line 887, in setup_extended_logging log.setup_extended_logging(self.config) File "/usr/lib/python3/dist-packages/salt/log/setup.py", line 414, in setup_extended_logging providers = salt.loader.log_handlers(opts) File "/usr/lib/python3/dist-packages/salt/loader/init.py", line 686, in log_handlers _module_dirs( File "/usr/lib/python3/dist-packages/salt/loader/init__.py", line 148, in _module_dirs for entry_point in entrypoints.iter_entry_points("salt.loader"): File "/usr/lib/python3/dist-packages/salt/utils/entrypoints.py", line 43, in _wrapped return f(*args, **kwargs) File "/usr/lib/python3/dist-packages/salt/utils/entrypoints.py", line 62, in iter_entry_points for entry_point_group, entry_points_list in entry_points.items(): AttributeError: 'EntryPoints' object has no attribute 'items' Usage: salt-call [options] [arguments]

salt-call: error: Error while processing <function LogLevelMixIn.setup_extended_logging at 0x7f18f8f02550>: Traceback (most recent call last): File "/usr/lib/python3/dist-packages/salt/utils/parsers.py", line 210, in parse_args mixin_after_parsed_func(self) File "/usr/lib/python3/dist-packages/salt/utils/parsers.py", line 887, in setup_extended_logging log.setup_extended_logging(self.config) File "/usr/lib/python3/dist-packages/salt/log/setup.py", line 414, in setup_extended_logging providers = salt.loader.log_handlers(opts) File "/usr/lib/python3/dist-packages/salt/loader/init.py", line 686, in log_handlers _module_dirs( File "/usr/lib/python3/dist-packages/salt/loader/init.py", line 148, in _module_dirs for entry_point in entrypoints.iter_entry_points("salt.loader"): File "/usr/lib/python3/dist-packages/salt/utils/entrypoints.py", line 43, in _wrapped return f(*args, **kwargs) File "/usr/lib/python3/dist-packages/salt/utils/entrypoints.py", line 62, in iter_entry_points for entry_point_group, entry_points_list in entry_points.items(): AttributeError: 'EntryPoints' object has no attribute 'items'

and have tried the solution mentioned in other suggestions to try and run sudo python3 -m pip install 'importlib-metadata==4.13.0' but are getting the return that it's already there:

Requirement already satisfied: importlib_metadata==4.13.0 in /usr/local/lib/python3.8/dist-packages (4.13.0) Requirement already satisfied: zipp>=0.5 in /usr/local/lib/python3.8/dist-packages (from importlib_metadata==4.13.0) (3.16.2) WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv

What I did was trying running sudo python3 -m pip uninstall importlib-metadata and then sudo python3 -m pip install 'importlib-metadata==4.13.0' which I got

Collecting importlib-metadata<5.0.0 Using cached importlib_metadata-4.13.0-py3-none-any.whl (23 kB) Requirement already satisfied: zipp>=0.5 in /usr/local/lib/python3.8/dist-packages (from importlib-metadata<5.0.0) (3.16.2) Installing collected packages: importlib-metadata Attempting uninstall: importlib-metadata Found existing installation: importlib-metadata 6.8.0 Uninstalling importlib-metadata-6.8.0: Successfully uninstalled importlib-metadata-6.8.0 Successfully installed importlib-metadata-4.13.0 WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv

It seems 6.8.0 had somehow snuck itself into the system as well and might have been the issue. Something to check for.

geeksailor commented 1 year ago

@Cr4wlerx @digitalsleuth If the original posters issue has been resolved can this ticket be closed?

BoBeR182 commented 1 year ago

@Cr4wlerx @digitalsleuth If the original posters issue has been resolved can this ticket be closed?

It's only solved with a hotfix, running the pip command. There should be a proper upstream solution.

geeksailor commented 1 year ago

@BoBeR182 Ah my bad. Thanks for the follow up

digitalsleuth commented 1 year ago

@BoBeR182 @geeksailor , yes the "importlib-metadata" error was fixed with the implementation of SaltStack 3006 in the new REMnux CLI. This is the "upstream solution" you mentioned regarding the "hotfix". Regarding the original context for this issue, I have not heard back regarding the Volatility3 issue, and it does not seem to have come back in any testing.

@BoBeR182 , since you were also experiencing the issue with Volatility 3, can you confirm that you no longer have that specific issue? If so, we can close this issue.

digitalsleuth commented 5 months ago

@lennyzeltser I believe we may be able to close this issue.