Prepare the Database on macOS

In order to setup a production system you have to prepare a MySQL database where the application will store all data.
To perform this step, make sure to have a MySQL up and running, if this is not the case install it:

Once your MySQL instance is up and running, please open a terminal and execute this command:

$ sudo su

Setting Password for MySQL Root User

Execute the following commands at a shell prompt:

$ /usr/local/mysql/bin/mysqladmin -u root password 'password'

Type your password as requested in order to login as the root user.

Creating the database

Connect to mysql prompt typing the command:

$ /usr/local/mysql/mysql -u root -ppassword

Execute the following commands at the mysql prompt:


Now we have an empty database called logicaldoc with a user root that can access it using password password.
You can exit the mysql prompt(command \q) and go ahead.


OS X uses launch daemons to automatically start, stop, and manage processes and applications such as MySQL.
But sometimes the installation process can go wrong or perhaps you run anĀ upgrade of your Mac and MySQL will not start at boot...
To fix this problem you just need to add a special fileĀ into your /Library/LaunchDaemons directory, so please refer to the Oracle's MySQL reference manual to better understand the procedure:


Directories and executable files inside the StartupItems and LaunchDaemons folder should have permissions of 0755 with the owner set to "root" and group set to "wheel." Other (non-executable) files should have permissions of 0644 with the owner set to "root" and group set to "wheel."