默認(rèn)情況下,GitLab會將數(shù)據(jù)庫文件放在 /var/opt/gitlab/postgresql/data 中。如果要修改數(shù)據(jù)庫文件位置,需要將 /var/opt/gitlab/postgresql/data 中的所有文件復(fù)制到新的位置,然后在 /etc/gitlab/gitlab.rb 中設(shè)置以下4個配置至新的位置:postgresql['dir'] =
postgresql['data_dir'] =
postgresql['log_directory'] =
postgresql['home'] =進(jìn)行這樣的設(shè)置后,運行g(shù)itlab-ctl reconfigure,卻出現(xiàn)下面的錯誤提示:================================================================================
Error executing action `create` on resource 'user[gitlab-psql]'
================================================================================
Mixlib::ShellOut::ShellCommandFailed
------------------------------------
Expected process to exit with [0], but received '8'
---- Begin output of ["usermod", "-d", "/gitlab/postgresql/data", "gitlab-psql"] ----
STDOUT:
STDERR: usermod: user gitlab-psql is currently logged in
---- End output of ["usermod", "-d", "/gitlab/postgresql/data", "gitlab-psql"] ----
Ran ["usermod", "-d", "/gitlab/postgresql/data", "gitlab-psql"] returned 8
GitLab修改PostgreSQL數(shù)據(jù)庫文件位置的問題
jeck貓
2018-08-03 06:09:03