How'd you do it?
This section should also tell us any relevant information about the
environment; for example, if an exploit that used to work is failing,
tell us the victim operating system and service versions.
What should happen?
root@debian-pentest:~# msfconsole
Metasploit Park, System Security Interface
Version 4.0.5, Alpha E
Ready...
access security
access: PERMISSION DENIED.
access security grid
access: PERMISSION DENIED.
access main security grid
access: PERMISSION DENIED....and...
YOU DIDN'T SAY THE MAGIC WORD!
YOU DIDN'T SAY THE MAGIC WORD!
YOU DIDN'T SAY THE MAGIC WORD!
YOU DIDN'T SAY THE MAGIC WORD!
YOU DIDN'T SAY THE MAGIC WORD!
YOU DIDN'T SAY THE MAGIC WORD!
YOU DIDN'T SAY THE MAGIC WORD!
=[ metasploit v4.11.21-dev-16c599866cd501d0c619ce12248a2b0127ceaf93]
/opt/metasploit-framework/embedded/lib/ruby/gems/2.1.0/gems/activesupport-4.0.13/lib/active_support/core_ext/kernel/agnostics.rb:7:in ': Cannot allocate memory - infocmp (Errno::ENOMEM)
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.1.0/gems/activesupport-4.0.13/lib/active_support/core_ext/kernel/agnostics.rb:7:in'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.1.0/gems/rb-readline-r7-0.5.2.0/lib/rbreadline.rb:1815:in get_term_capabilities'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.1.0/gems/rb-readline-r7-0.5.2.0/lib/rbreadline.rb:2027:in_rl_init_terminal_io'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.1.0/gems/rb-readline-r7-0.5.2.0/lib/rbreadline.rb:2519:in readline_initialize_everything'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.1.0/gems/rb-readline-r7-0.5.2.0/lib/rbreadline.rb:3804:inrl_initialize'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.1.0/gems/rb-readline-r7-0.5.2.0/lib/rbreadline.rb:4823:in readline'
from /opt/metasploit-framework/embedded/framework/lib/rex/ui/text/input/readline.rb:132:inreadline_with_output'
from /opt/metasploit-framework/embedded/framework/lib/rex/ui/text/input/readline.rb:86:in pgets'
from /opt/metasploit-framework/embedded/framework/lib/rex/ui/text/shell.rb:187:inrun'
from /opt/metasploit-framework/embedded/framework/lib/metasploit/framework/command/console.rb:48:in start'
from /opt/metasploit-framework/embedded/framework/lib/metasploit/framework/command/base.rb:82:instart'
from /opt/metasploit-framework/bin/../embedded/framework/msfconsole:48:in `
What happens instead?
You might also want to check the last ~1k lines of
/opt/metasploit/apps/pro/engine/config/logs/framework.log or
~/.msf4/logs/framework.log for relevant stack traces
Get this with the version command in msfconsole (or git log -1 --pretty=oneline for a source install).
What OS are you running Metasploit on?
ubuntu 14
You probably installed Metasploit on a system without enough memory. Create some swap space and try running msfconsole again.
Follow this guide:
https://www.optiv.com/blog/create-a-budget-friendly-virtual-private-server-with-a-metasploit-instance
He's using a DO droplet, but the steps to create swap space are the same. Follow the steps from this point "First Attempt at Running MSF (FAIL)".
@AliBawazeEer Nice report, but @P5I is correct - the stacktrace indicates your environment has run out of memory, so you will need to change that on your end. This doesn't look like a bug in Framework, so I will go ahead and close this ticket. But if for some reason that's not the case, feel free to ping me and I will be more than happy to reopen. Thanks.
Hi all ,
this issue can be resolved , resolution swap file created
i have this error after install msf console
/opt/metasploit-framework/embedded/lib/ruby/gems/2.4.0/gems/activesupport-4.2.10/lib/active_support/core_ext/kernel/agnostics.rb:7:in ': Cannot allocate memory - infocmp (Errno::ENOMEM)
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.4.0/gems/activesupport-4.2.10/lib/active_support/core_ext/kernel/agnostics.rb:7:in'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.4.0/gems/rb-readline-0.5.5/lib/rbreadline.rb:1815:in get_term_capabilities'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.4.0/gems/rb-readline-0.5.5/lib/rbreadline.rb:2027:in_rl_init_terminal_io'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.4.0/gems/rb-readline-0.5.5/lib/rbreadline.rb:2564:in readline_initialize_everything'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.4.0/gems/rb-readline-0.5.5/lib/rbreadline.rb:3849:inrl_initialize'
from /opt/metasploit-framework/embedded/lib/ruby/gems/2.4.0/gems/rb-readline-0.5.5/lib/rbreadline.rb:4868:in readline'
from /opt/metasploit-framework/embedded/framework/lib/rex/ui/text/input/readline.rb:162:inreadline_with_output'
from /opt/metasploit-framework/embedded/framework/lib/rex/ui/text/input/readline.rb:100:in pgets'
from /opt/metasploit-framework/embedded/framework/lib/rex/ui/text/shell.rb:189:inrun'
from /opt/metasploit-framework/embedded/framework/lib/metasploit/framework/command/console.rb:48:in start'
from /opt/metasploit-framework/embedded/framework/lib/metasploit/framework/command/base.rb:82:instart'
from /opt/metasploit-framework/bin/../embedded/framework/msfconsole:48:in `
how can i fix
Please don't comment on closed tickets. If you read the first response above, I believe that will help find an answer for the ENOMEM your installation hit, @vicky121998.
ayn谋 hata bende de oldu yard谋m edebilecek var m谋?
Probleme: not enough swap space
Solution Create SWAP
free ## to check your swap space
cd /var/
ls
touch swap.img
chmod 600 s
chmod 600 swap.img
dd if=/dev/zero of=/var/swap.img bs=1024k count=1000
mkswap /var/swap.img
swapon /var/swap.img
Most helpful comment
You probably installed Metasploit on a system without enough memory. Create some swap space and try running msfconsole again.
Follow this guide:
https://www.optiv.com/blog/create-a-budget-friendly-virtual-private-server-with-a-metasploit-instance
He's using a DO droplet, but the steps to create swap space are the same. Follow the steps from this point "First Attempt at Running MSF (FAIL)".