download metasploit in termux without error
Start postgresql
postgresql
./postgresql_ctl.sh start
And run msfconsole
msfconsole