gitlab-ctl重新配置:无法确定节点名称 [英] gitlab-ctl reconfigure: Unable to determine node name

查看:537
本文介绍了gitlab-ctl重新配置:无法确定节点名称的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我确实在Ubuntu 16.04.4 LTS上设置了一个新的GitLab实例.安装软件包运行正常,并且GitLab似乎已启动并正在运行.然后,我开始在/etc/gitlab/gitlab.rb中配置实例并设置SMTP.之后,我运行了sudo gitlab-ctl reconfigure.它失败,并显示以下错误消息:

I did setup a new GitLab instance on Ubuntu 16.04.4 LTS. Installing the package went fine and GitLab seems to be up and running. I then started to configure the instance and setup SMTP in /etc/gitlab/gitlab.rb. Afterwards I ran sudo gitlab-ctl reconfigure. It failed with the following error message:

Starting Chef Client, version 13.6.4

Running handlers:
There was an error running gitlab-ctl reconfigure:

Unable to determine node name: configure node_name or configure the system's hostname and fqdn

Running handlers complete
Chef Client failed. 0 resources updated in 10 seconds

设置了系统的主机名和fqdn:

The system's hostname and fqdn are set:

$ hostname --fqdn
git-lab.dom
$ hostname
git-lab

Ohai似乎成功读取了主机名,fqdn和域:

Ohai seems to to successfully read hostname, fqdn and domain:

$ /opt/gitlab/embedded/bin/ohai
[...]
"hostname": "git-lab",
"machinename": "git-lab",
"fqdn": "git-lab.dom",
"domain": "dom",
[...]

对类似问题的答案建议在/etc/chef/client.rb中手动设置node_name.但是,gitlab omnibus软件包似乎将client.rb放在其他位置.我也不愿意遵循这个建议,因为到目前为止,我对其他的GitLab安装都没有这样做,这让我感到奇怪.此外,文档指出(重点是我的):

The answer to a similar question suggested to manually set the node_name in /etc/chef/client.rb. However, the gitlab omnibus package seems to put the client.rb somewhere else. I am also reluctant to follow this advice since it seems strange to me that I did not have to do it for other GitLab installations so far. Also the docs state (emphasis mine):

node_name:节点的名称.确定应使用的配置 应用并设置client_name,这是在以下情况下使用的名称 向Chef服务器进行身份验证.默认值为 厨师客户,由Ohai检测到.通常,厨师建议您 将此设置留空,然后让Ohai将节点的FQDN分配为 每个主客户端运行期间的node_name.

node_name: The name of the node. Determines which configuration should be applied and sets the client_name, which is the name used when authenticating to a Chef server. The default value is the FQDN of the chef-client, as detected by Ohai. In general, Chef recommends that you leave this setting blank and let Ohai assign the FQDN of the node as the node_name during each chef-client run.

如何解决该问题并继续配置新安装?

How can I solve the issue and continue configuring my new installation?

推荐答案

问题似乎是由内存不足引起的.为虚拟机提供更多内存后,错误消失了.

The problem seems to be caused by insufficient memory. After giving the virtual machine more memory the error went away.

这篇关于gitlab-ctl重新配置:无法确定节点名称的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆