Tried to run msfconsole as the samurai user and keep getting an error attempting to connect to the database, works fine when run via sudo. Is this supposed to be how it works, or should the samurai user allowed to run metasploit?
The error is: [-] Warning, /usr/share/metasploit/config/database.yml is not readable. Try running as root or chmod. [-] No database definition for environment
Output of running msfconsole as samurai user
The error is:
[-] Warning, /usr/share/metasploit/config/database.yml is not readable. Try running as root or chmod.
[-] No database definition for environment
Solution:
$ sudo chmod 744 /usr/share/metasploit/config/database.yml
$ sudo chown samurai:samurai /home/samurai/.msf4/schema/
This will be fixed in 2.1.