tag:support.arachni-scanner.com,2012-07-01:/discussions/questions/13147-postgressql-as-databaseArachni: Discussion 2018-10-19T07:41:56Ztag:support.arachni-scanner.com,2012-07-01:Comment/418927672017-02-05T21:27:25Z2017-02-05T21:27:30ZPostgresSQL as Database<div><p>To use PostgreSQL as your database you should:</p>
<pre>
<code>Backup the default DB configuration file (system/arachni-ui-web/config/database.yml).
Rename system/arachni-ui-web/config/database.yml.pgsql to system/arachni-ui-web/config/database.yml.
Update the configuration file settings with the appropriate credentials.
Run ./bin/arachni_web_task db:setup to setup the database.</code>
</pre>
<p>How do I update the configuration file settings with the
appropriate credentials?</p>
<p>I moved the original database.yml file to another location for
backup purposes. I then renamed database.yml.pgsql to just
database.yml</p>
<p>Now I am on to the next step of updating the configuration file
and am stuck because I do not know how to go about doing this.</p>
<p>Thanks</p></div>Dtag:support.arachni-scanner.com,2012-07-01:Comment/418927672017-02-07T10:19:13Z2017-02-07T10:19:13ZPostgresSQL as Database<div><p>You need to change these values:</p>
<pre>
<code> username: arachni
password: secret</code>
</pre>
<p>From <code>arachni</code> and <code>secret</code> to whatever
credentials you have set for your DB.</p></div>Tasos Laskostag:support.arachni-scanner.com,2012-07-01:Comment/418927672017-02-09T04:55:49Z2017-02-09T04:55:51ZPostgresSQL as Database<div><p>I went into the database.yml.pgsql file and changed "arachni" in
all instances along with "secret" in all instances.</p>
<p>I moved the original database.yml file out the folder.<br>
I renamed the database.yml.pgsql into database.yml.</p>
<p>I now go to my terminal and start psql to correct an error I am
receiving and cannot find the correct commands to enter. I have
enclosed a file which displays the errors I have come across.
Please tell me if I am taking the wrong steps.</p></div>Dtag:support.arachni-scanner.com,2012-07-01:Comment/418927672017-02-09T08:32:34Z2017-02-09T08:32:34ZPostgresSQL as Database<div><p>I don't think I can be of further help, it's a DB configuration
issue from now on and I'm very rusty on my DB admin skills.<br>
Are you sure the password for the "specias" user is correct?</p></div>Tasos Laskostag:support.arachni-scanner.com,2012-07-01:Comment/418927672017-02-12T11:22:15Z2017-02-12T11:22:18ZPostgresSQL as Database<div><p>I think... I think I finally configured the DB. However, I came
across this issue:</p>
<p>./arachni_web [WARN] table 'Role' doesn't exist. Did you run the
migration ? Ignoring rolify config. Puma 2.14.0 starting...<br>
* Min threads: 0, max threads: 16 * Environment: development *
Listening on tcp://localhost:9292</p>
<p>Kinda scratching my head for any hairs that are left
now.......</p></div>Dtag:support.arachni-scanner.com,2012-07-01:Comment/418927672017-02-12T15:12:33Z2017-02-12T15:12:33ZPostgresSQL as Database<div><p>Did you run <code>./bin/arachni_web_task db:setup</code>?</p></div>Tasos Laskostag:support.arachni-scanner.com,2012-07-01:Comment/418927672017-02-12T19:52:34Z2017-02-12T19:52:36ZPostgresSQL as Database<div><p>Well, that is the step I missed.<br>
I remember restarting postgreSQL prior to starting
./arachni_web<br>
I remember going into the web interface and creating new users so
that the logins work.</p>
<p>I first received this output - that I placed in file format and
attached - when starting ./bin/arachni_web_task db:setup</p>
<p>The first lines put a little fright in me. I thought that the
same issue would exist.</p>
<p>I restarted postgreSQL once again.<br>
I started ./arachni_web and logged into the web interface.<br>
However, all the users I created previously were removed or
missing.<br>
I only had to re-add these users. Sign out. Restart postgreSQL.</p>
<p>I opened ./arachni_web and the command provided no error or
warns.</p>
<p>It appears to me that everything is functioning smoothly
now.<br>
Now that I have the database and web interface configured, I can
now continue on with the rest of the tutorial.</p>
<p>Much thanks!</p></div>D