seaweedfs.sql 595 B

123456789101112
  1. CREATE DATABASE IF NOT EXISTS seaweedfs;
  2. CREATE USER IF NOT EXISTS 'seaweedfs'@'%' IDENTIFIED BY 'secret';
  3. GRANT ALL PRIVILEGES ON seaweedfs.* TO 'seaweedfs'@'%';
  4. FLUSH PRIVILEGES;
  5. USE seaweedfs;
  6. CREATE TABLE IF NOT EXISTS `filemeta` (
  7. `dirhash` BIGINT NOT NULL COMMENT 'first 64 bits of MD5 hash value of directory field',
  8. `name` VARCHAR(766) NOT NULL COMMENT 'directory or file name',
  9. `directory` TEXT NOT NULL COMMENT 'full path to parent directory',
  10. `meta` LONGBLOB,
  11. PRIMARY KEY (`dirhash`, `name`)
  12. ) DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;