-
Notifications
You must be signed in to change notification settings - Fork 41
Database setup
angelxuanchang edited this page Sep 25, 2024
·
10 revisions
So far, we have used MySQL 5.7.
- Following MySQL installation to installing MySQL for your platform. Alternatively, you can also use MariaDB
Ubuntu 14.04, 16.04, 18.04
sudo apt install mysql-server
sudo mysql_secure_installation
MacOS
brew install mariadb
brew install mysql
- Setup an account with username/password and database that you will use for the annotations (substitute appropriate name for
dbname
,username
andpassword
.
sudo mysql -u root -p
CREATE DATABASE dbname;
CREATE USER 'username'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON dbname.* TO 'username'@'localhost' IDENTIFIED BY 'password';
- Run
scripts/db/create_annotation_tables.sql
to create tables for annotation
# in mysql prompt
source scripts/db/create_annotation_tables.sql
- Adjust configuration for your MySQL instance in
server/config/index.js
(seeconfig.annDb
)
mysqldump -u [username] -p --databases [database] > [database]_20190506.sql
Single table
mysqldump [database] [t1] [t2] [t3] > dump.sql
Restore
mysql < dump.sql
- Home
- Main
- Annotators
- Assets
- Batch processing
- Development
- File formats
- Rendering
- Scene Tools
- Voxels