GitLab|GitLab报错:Restoring PostgreSQL database gitlabhq_production...

错误信息:

Restoring PostgreSQL database gitlabhq_production ... ERROR: must be owner of extension pg_trgm

ERROR: must be owner of extension btree_gist

ERROR: must be owner of extension btree_gist

ERROR: must be owner of extension pg_trgm

解决方案:

  1. 修改postgresql相关配置

修改配置文件postgresql.conf,修改端口监听地址,默认监控localhost,* 代表all

复制代码
$ vim /var/opt/gitlab/postgresql/data/postgresql.conf
listen_addresses = '*'

修改配置文件pg_hba.conf,新增以下两行

复制代码
$ vim /var/opt/gitlab/postgresql/data/pg_hba.conf
local all all trust
host all all 127.0.0.1/32 trust
  1. 重启gitlab服务

    gitlab-ctl restart

  2. 修改数据

    su - gitlab-psql /opt/gitlab/embedded/bin/psql -h 127.0.0.1 gitlabhq_production
    gitlabhq_production=# ALTER USER gitlab WITH SUPERUSER;
    ALTER ROLE
    gitlabhq_production=# \q
    $ exit

作者:Kkoo

链接:https://www.pwwwp.com/

著作权归作者所有。商业转载请联系作者进行授权,非商业转载请注明出处。

相关推荐
lijunjun2 天前
当ubuntu 系统的IP地址修改之后,gitlab服务应该如何修改?
tcp/ip·ubuntu·gitlab
Qperable4 天前
gitlab-runner提示401 Unauthorized
后端·gitlab
西瓜er5 天前
Docker 一键部署指南:GitLab、Nacos、Redis、MySQL 与 MinIO 全解析
redis·docker·gitlab
yunson_Liu5 天前
jenkins更新了gitlab后出现报错
运维·gitlab·jenkins
stark张宇6 天前
Git 与 GitHub 协同工作流:从0到1搭建版本控制体系
git·gitlab·github
牛马的人生11 天前
GitLab入门教程:打开DevOps全流程的大门
运维·其他·gitlab·devops
水冗水孚11 天前
Ubuntu服务器上使用docker-compose部署 gitlab(图文并茂记录)
gitlab
<花开花落>13 天前
gitlab-runner 再次实践中理解和学习
gitlab
Vahala0623-孔勇14 天前
CI/CD流水线优化:GitLab CI镜像构建加速实战
ci/cd·gitlab
Lin_Aries_042114 天前
部署 GitLab 服务器
linux·运维·服务器·docker·gitlab·github