Skip to content
This repository has been archived by the owner on Apr 9, 2024. It is now read-only.

reload_all not working, postgres connection fails. #52

Open
3 tasks
abhijeetasawant opened this issue Jul 17, 2020 · 0 comments
Open
3 tasks

reload_all not working, postgres connection fails. #52

abhijeetasawant opened this issue Jul 17, 2020 · 0 comments

Comments

@abhijeetasawant
Copy link

Steps to reproduce

Please guide here:

When i start with: sudo ./docker/bin/msfconsole

Two errors are shown:

  1. Error while running command db_connect: Failed to connect to the Postgres data service: could not translate host name "db" to address: Try again

Call stack:
/usr/src/metasploit-framework/lib/msf/ui/console/command_dispatcher/db.rb:2048:in db_connect_postgresql' /usr/src/metasploit-framework/lib/msf/ui/console/command_dispatcher/db.rb:1832:in cmd_db_connect'
/usr/src/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:523:in run_command' /usr/src/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:474:in block in run_single'
/usr/src/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:468:in each' /usr/src/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:468:in run_single'
/usr/src/metasploit-framework/lib/rex/ui/text/resource.rb:56:in load_resource' /usr/src/metasploit-framework/lib/rex/ui/text/resource.rb:61:in eval'
/usr/src/metasploit-framework/lib/rex/ui/text/resource.rb:61:in load_resource' /usr/src/metasploit-framework/lib/msf/ui/console/driver.rb:183:in block in initialize'
/usr/src/metasploit-framework/lib/msf/ui/console/driver.rb:182:in each' /usr/src/metasploit-framework/lib/msf/ui/console/driver.rb:182:in initialize'
/usr/src/metasploit-framework/lib/metasploit/framework/command/console.rb:62:in new' /usr/src/metasploit-framework/lib/metasploit/framework/command/console.rb:62:in driver'
/usr/src/metasploit-framework/lib/metasploit/framework/command/console.rb:48:in start' /usr/src/metasploit-framework/lib/metasploit/framework/command/base.rb:82:in start'
./msfconsole:49:in `

'

  1. Error while running command reload_all: No classes in Msf::Module::Platform::Linux for ,osx!

Call stack:
/usr/src/metasploit-framework/lib/msf/core/module/platform.rb:61:in find_platform' /usr/src/metasploit-framework/lib/msf/core/module/platform_list.rb:55:in block in initialize'
/usr/src/metasploit-framework/lib/msf/core/module/platform_list.rb:53:in each' /usr/src/metasploit-framework/lib/msf/core/module/platform_list.rb:53:in initialize'
/usr/src/metasploit-framework/lib/msf/core/module/platform_list.rb:40:in new' /usr/src/metasploit-framework/lib/msf/core/module/platform_list.rb:40:in from_a'
/usr/src/metasploit-framework/lib/msf/core/module/platform_list.rb:30:in transform' /usr/src/metasploit-framework/lib/msf/core/module.rb:119:in initialize'
/usr/src/metasploit-framework/lib/msf/core/module/has_actions.rb:6:in initialize' /usr/src/metasploit-framework/lib/msf/core/post_mixin.rb:16:in initialize'
/usr/src/metasploit-framework/modules/post/multi/purple/t1153.rb:9:in initialize' /usr/src/metasploit-framework/lib/msf/core/module_set.rb:54:in new'
/usr/src/metasploit-framework/lib/msf/core/module_set.rb:54:in create' /usr/src/metasploit-framework/lib/msf/core/modules/metadata/cache.rb:61:in block (3 levels) in refresh_metadata'
/usr/src/metasploit-framework/lib/msf/core/modules/metadata/cache.rb:57:in each' /usr/src/metasploit-framework/lib/msf/core/modules/metadata/cache.rb:57:in block (2 levels) in refresh_metadata'
/usr/src/metasploit-framework/lib/msf/core/modules/metadata/cache.rb:54:in each' /usr/src/metasploit-framework/lib/msf/core/modules/metadata/cache.rb:54:in block in refresh_metadata'
/usr/src/metasploit-framework/lib/msf/core/modules/metadata/cache.rb:51:in synchronize' /usr/src/metasploit-framework/lib/msf/core/modules/metadata/cache.rb:51:in refresh_metadata'
/usr/src/metasploit-framework/lib/msf/core/module_manager/cache.rb:124:in refresh_cache_from_module_files' /usr/src/metasploit-framework/lib/msf/core/module_manager/reloading.rb:51:in reload_modules'
/usr/src/metasploit-framework/lib/msf/ui/console/command_dispatcher/modules.rb:859:in cmd_reload_all' /usr/src/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:523:in run_command'
/usr/src/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:474:in block in run_single' /usr/src/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:468:in each'
/usr/src/metasploit-framework/lib/rex/ui/text/dispatcher_shell.rb:468:in run_single' /usr/src/metasploit-framework/lib/rex/ui/text/resource.rb:57:in load_resource'
/usr/src/metasploit-framework/lib/rex/ui/text/resource.rb:61:in eval' /usr/src/metasploit-framework/lib/rex/ui/text/resource.rb:61:in load_resource'
/usr/src/metasploit-framework/lib/msf/ui/console/driver.rb:183:in block in initialize' /usr/src/metasploit-framework/lib/msf/ui/console/driver.rb:182:in each'
/usr/src/metasploit-framework/lib/msf/ui/console/driver.rb:182:in initialize' /usr/src/metasploit-framework/lib/metasploit/framework/command/console.rb:62:in new'
/usr/src/metasploit-framework/lib/metasploit/framework/command/console.rb:62:in driver' /usr/src/metasploit-framework/lib/metasploit/framework/command/console.rb:48:in start'
/usr/src/metasploit-framework/lib/metasploit/framework/command/base.rb:82:in start' ./msfconsole:49:in

'

Expected behavior

Postgres db should connect seamless.
reload_all should work without any errors.

Current behavior

Postgres db is not connected.
reload_all is not working.

System stuff

Metasploit version

Framework: 5.0.69-dev-5e07f93720
Console : 5.0.69-dev-5e07f93720

Get this with the version command in msfconsole (or git log -1 --pretty=oneline for a source install).

I installed Metasploit with:

Merge pull request #51 from praetorian-code/tmsteen-create/T1153M

OS

What OS are you running Metasploit on?
Ubuntu 18.04 LTS

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

No branches or pull requests

1 participant