ubuntu20 部署社区版,到最后运行 ./seahub.sh start 时,无法创建管理员
提示 Error happened during creating seafile admin
查 logs/seafile.log日志,提示
/common/seaf-db.c(867): Failed to connect to MySQL: Plugin caching_sha2_password could not be loaded: /usr/lib/mariadb/plugin/caching_sha2_password.so: 无法打开共享对象文件: 没有那个文件或目录
网上说是由于 mysql 8.0 默认采用 caching sha2 password
进入mysql做如下改
ALTER USER ‘seafile’@‘127.0.0.1’ IDENTIFIED BY ‘passowrd’ PASSWORD EXPIRE NEVER;
ALTER USER ‘seafile’@‘127.0.0.1’ IDENTIFIED WITH mysql_native_password BY ‘password’;
FLUSH PRIVILEGES;
ALTER USER ‘seafile’@‘127.0.0.1’ IDENTIFIED BY ‘password’;
quit;
再启动seahub.sh, caching_sha2_password 错误倒是没了,但还是提示Error happened during creating seafile admin 但是seahub也能运行起来,页面能访问,但无法创建admin账号就无法登录。再查seafile.log 日志,
2025-01-10 09:20:01 http-server.c(195): fileserver: worker_threads = 10
2025-01-10 09:20:01 http-server.c(217): fileserver: cluster_shared_temp_file_mode = 600
2025-01-10 09:20:01 socket file exists, delete it anyway
2025-01-10 09:20:01 …/common/seaf-db.c(867): Failed to connect to MySQL: Access denied for user ‘seafile’@‘localhost’ (using password: YES)
2025-01-10 09:20:01 …/common/seaf-db.c(867): Failed to connect to MySQL: Access denied for user ‘seafile’@‘localhost’ (using password: YES)
2025-01-10 09:20:01 repo-mgr.c(3824): Failed to add branch.
2025-01-10 09:20:01 seafile-session.c(631): Failed to create system default repo.
2025-01-10 09:22:42 start to serve on pipe client
2025-01-10 09:22:42 …/common/seaf-db.c(867): Failed to connect to MySQL: Access denied for user ‘seafile’@‘localhost’ (using password: YES)
2025-01-10 09:23:10 …/common/seaf-db.c(867): Failed to connect to MySQL: Access denied for user ‘seafile’@‘localhost’ (using password: YES)
这是什么导致的?