修改GitLab项目文件路径重新刷新配置报错问题原因及解决方案

Error executing action create on resource ‘storage_directory[/***/git-data]’
原因是执行用户需要有执行权限。
解决方案是:切换到对应目录去执行sudo gitlab-ctl reconfigure 。

登录系统,执行修改配置路径,来修改数据仓库的地址:vim /etc/gitlab/gitlab.rb
在这里插入图片描述
当然你也可以把路径修改为:git_data_dirs({ “default” => { “path” => “/mnt/sda3/git-data” } })
这两种方式都可以。
git_data_dir "/mnt/sda3/git-data"这种修改方式刷新配置时会报下面的错误:
在这里插入图片描述
就是该方式已经在11.0被废弃了。11.0以后版本使用git_data_dirs代替了。
官方文档说是修改权限就可以,实际执行结果还是不行。我当时的操作目录是:[root@localhost ~]#sudo gitlab-ctl reconfigure。
报错信息如下:
在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

我切换到目标路径,再刷新配置成功了。
在这里插入图片描述
[root@localhost /]# sudo chmod +x /mnt
您在 /var/spool/mail/root 中有新邮件
[root@localhost /]# sudo chmod +x /mnt/sda3
[root@localhost /]# sudo chmod +x /mnt/sda3/git-data
[root@localhost /]# cd /mnt/sda3
[root@localhost sda3]# ls
git git-data lost+found
[root@localhost sda3]# cd git-data
[root@localhost git-data]# ls
[root@localhost git-data]# sudo gitlab-ctl reconfigure

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值