Davinci Resolve Collaboration

 
 

Here is how co configure a QNAP NAS to HOST A RESOLVE POSTGRESQL DATABASE

With latest versions of Davinci Resolve Studio we can work in a collaborative environment using a central Postgres database.

https://mixinglight.com/color-tutorial/davinci-resolve-14-mythical-collaborative-workflow-is-here/
https://blog.pond5.com/18201-post-production-collaboration-made-simple-davinci-resolve-14-studio/
https://www.youtube.com/watch?v=3dQoqBwJ2gM


You can install Postgres on a Mac or Windows workstation to share it, but even easier is to install it on your QNAP files sharing system.
Recommended QNAP systems to use for filesharing in video-editing environments are the TVS-1282 series and the TS-1685 or the rack version similar to the TVS-EC1680.
These can be used for Adobe Premiere, Final Cut Pro X , Avid ( using Mimiq ) and of course Resolve.

The QNAP app store has the option to install the free Postgres database.
Restart the QNAP after installing the Postgres app on the QNAP

After installing the Postgres database engine, it is by default, only accessibe from within the QNAP server itself.
But in this case we want acces to the database from our Davinci Resolve workstation, so we need to change 2 parameters on the PostgreSQL on the QNAP:

- Allowing external TCP/IP connections by modyfing the pg_hba.conf file, you have to add a client authentication record so that external ip's have acces.
 
- Alter the listening addresses in the postgresql.conf
so it will listen to external ip's and not only its localhost ip addresses.

how do we do this :

1. we have make a external connection to the QNAP over ssh so that we can access to modify these
files on the QNAP :

we do this with the admin account of the QNAP , so that its system settings can be changed.

On the Mac,  Finder , Goto, Applications, Utilities, start Terminal
then enter

ssh admin@ipnroftheqnap
in our example that would be
ssh admin@10.0.73.180

accept ssh acces and enter the QNAP admin password
now you have a commandline interface with the QNAP - which is a unix based system.

-- TIP: for easy viewing, make the terminal window al least twice as large, as we are later on copy/paste long text in it.

2. then we need to know where the files are that need modifications :

use the command find :

find / -name pg_hba.conf

this gives the path to the file on the QNAP: in our case /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/
to see its content use:

cat /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/pg_hba.conf

Before modifing this file, we make an extra backup :

cp /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/pg_hba.conf /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/pg_hba.conf.backup

then append the necessary changes to the pg_hba.conf file.
this can be done  with the unix texteditor vi on the QNAP
but much easier :

echo "host    all             all             10.0.73.0/24            trust" >> /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/pg_hba.conf

in this example our QNAP and computers have ip-addresses in the 10.0.73.X segment.

the option to use md5 or password as security system won't work with Davinci Resolve,
so the only protection is now the masking with ipnrs and networkrange.
If you have a private network, this is probably not an issue. Perhaps in the future
we can use user/password with Resolve.

--TIP : if you use a textfile to prepare the commands and then copy-paste in terminal,
but sure that smart quotes are off = in apple texteditor app , preferences,  disable all these options at the bottom.
You DONT want smart quotes: we need  " " and NOT the  'smart'  ” “


to check that the modification is done , you can do another cat :

cat /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/pg_hba.conf

and see that the files is modified at the end.

the 2nd .conf that needs a modification is in the postgresql.conf file

again, first locate this file :

find / -name postgresql.conf

which gives in our system : /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/postgresql.conf

to check its content :

cat /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/postgresql.conf

before modification , again, we make a backup

cp /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/postgresql.conf /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/postgresql.conf.backup

then add the modification , so external acces of the database is possible :

echo "listen_addresses = '*' " >> /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/postgresql.conf

check if the modification was correct:

cat /share/CACHEDEV1_DATA/.qpkg/PostgreSQL/postgresDB/postgresql.conf

to make all these modifications active, you need to restart the QNAP

after this the QNAP system is ready for davinci resolve acces from the network :

when we log in over resolve we use : username postgres with password davinci,
but it could be anything as the setting is trust in de the pg_hba.conf


if you need to find the names back of your Resolve projects on the Postgres server,
you can login on the qnap over its webpage, startup the postgres app and login with the user postgres, no password.

disclaimer : Use this tutorial at your own risk

Extra considerations when using this setup :
- backup of the postgress databases is not so easy, as they are always open,
perhaps Blackmagic will give us an kind of autobackup mechanisme as with final cut pro x,
- postgres databases use a lot of small files that change alle the time,
so it would be nice to put them on a separate SSD disk based shared volume on the QNAP

---------

attention : sometimes internet and texteditors will mess up " " with 'smart'  ” “
this will mess up your settings file ...

if this happens you can copy over your backupfile and try again,
or use the vi editor of QNAP - some vi commando's if you need to edit  ...

:d  = delete current line
:x  = exit with save
:q! = exit without saving changes
:q = exit when no changes were done

-----------