Closed Dourin closed 2 weeks ago
Hello @Dourin,
msfdb is already init by exegol. Can you stop all your active containers and ensure that port 5432 is not used by your system.
Then, start a new container and run the following command: msfdb start
Then run msfconsole
and execute db_status
. The database should then be connected.
Can you tell me if you have an error in the process ?
> msfdb start
Calling `DidYouMean::SPELL_CHECKERS.merge!(error_name => spell_checker)' has been deprecated. Please call `DidYouMean.correct_error(error_name, spell_checker)' instead.
Running the 'start' command for the database:
Starting database at /var/lib/postgresql/.msf4/db...success
> msfconsole
msf6 > db_status
[*] Connected to msf. Connection type: postgresql.
.git/index: index file open failed: Permission denied
is just a warning; it will be removed later. This has no impact on database startup and shutdown.
OK thank you for the answer :)
I am not having errors with the process than you shown
Describe the bug
It happen then you try to init or run the msfdb. fatal: .git/index: index file open failed: Permission denied
Steps To Reproduce
[Jun 19, 2024 - 08:42:27 (CEST)] exegol-htb /workspace # msfdb init Calling
DidYouMean::SPELL_CHECKERS.merge!(error_name => spell_checker)' has been deprecated. Please call
DidYouMean.correct_error(error_name, spell_checker)' instead. fatal: .git/index: index file open failed: Permission denied Running the 'init' command for the database: Existing database found, attempting to start it Starting database at /var/lib/postgresql/.msf4/db...success [Jun 19, 2024 - 08:42:39 (CEST)] exegol-htb /workspace # msfdb status CallingDidYouMean::SPELL_CHECKERS.merge!(error_name => spell_checker)' has been deprecated. Please call
DidYouMean.correct_error(error_name, spell_checker)' instead. fatal: .git/index: index file open failed: Permission deniedRunning the 'status' command for the database: Database started
==================================================================== Running the 'status' command for the webservice: MSF web service is not running: no PID file found at /var/lib/postgresql/.msf4/msf-ws.pid
[Jun 19, 2024 - 08:42:53 (CEST)] exegol-htb /workspace # msfdb run
Calling
DidYouMean::SPELL_CHECKERS.merge!(error_name => spell_checker)' has been deprecated. Please call
DidYouMean.correct_error(error_name, spell_checker)' instead. fatal: .git/index: index file open failed: Permission denied Running the 'run' command for the database: [!] Error: unrecognized command 'run' for databaseThe solution is to make the right on the /opt/tools/metasploit-framework/.git/index like chmod 777 /opt/tools/metasploit-framework/.git/
Exegol Wrapper Version
Host OS
Linux
Configuration of the concerned container
Execution logs in debug mode
Exception
Anything else?
No response