Gitlab-EE installed from Omnibus is unreachable

gitlab-ee on Ubuntu 18.04 gives unable to resolve host

Describe your question in as much detail as possible: I am unable to run Gitlab-EE on my machine.

  • What are you seeing, and how does it differ from what you expect to see? I am seeing “Hmm. We’re having trouble finding that site.” instead of the Gitlab welcome screen where I should be able to enter my root password for the first time. wget http://gitlab.example.com gives error unable to resolve host
  • Consider including screenshots, error messages, and/or other helpful visuals (some outputs attached below)
  • What version are you on (Hint: /help) ? and are you using self-managed or gitlab.com? I don’t know how to find version number, but I installed gitlab on May 2, 2020 as per the instructions given at https://about.gitlab.com/install/#ubuntu (till step #3 only)
  • What troubleshooting steps have you already taken? Can you link to any docs or other resources so we know where you have been?

I have tried the advice at - https://docs.gitlab.com/omnibus/common_installation_problems/#gitlab-is-unreachable-in-my-browser but it didn’t help.

So I found this page - https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-gitlab-on-ubuntu-18-04

I was skimming the DO tutorial but was surprised that on doing step #3 I found that ufw was inactive immediately after ... apt install gitlab-ee. I activated it manually and again surprized that it had no rules. So I allowed http, https & OpenSSH.

If it matters, I’d like to inform that my postfix installation may be faulty I got error where dpkg was failing as $myhostname (used by postfix’s main.cf) was recorded incorrectly, for some mysterious reason ..name was being appended to $HOSTNAME and this improper recording made postfix installation fail.

I fixed the main.cf and moved on. Anyway, here are the outputs

usern@this-pc:~$ sudo gitlab-ctl status
[sudo] password for usern: 
run: alertmanager: (pid 1938) 1070s; run: log: (pid 1929) 1070s
run: gitaly: (pid 1946) 1070s; run: log: (pid 1933) 1070s
run: gitlab-exporter: (pid 1935) 1070s; run: log: (pid 1921) 1070s
run: gitlab-workhorse: (pid 1936) 1070s; run: log: (pid 1922) 1070s
run: grafana: (pid 1917) 1070s; run: log: (pid 1912) 1070s
run: logrotate: (pid 1934) 1070s; run: log: (pid 1920) 1070s
run: nginx: (pid 1919) 1070s; run: log: (pid 1915) 1070s
run: node-exporter: (pid 1945) 1070s; run: log: (pid 1928) 1070s
run: postgres-exporter: (pid 1947) 1070s; run: log: (pid 1930) 1070s
run: postgresql: (pid 1918) 1070s; run: log: (pid 1913) 1070s
run: prometheus: (pid 1942) 1070s; run: log: (pid 1926) 1070s
run: redis: (pid 1916) 1070s; run: log: (pid 1914) 1070s
run: redis-exporter: (pid 1943) 1070s; run: log: (pid 1927) 1070s
run: sidekiq: (pid 1951) 1070s; run: log: (pid 1932) 1070s
run: unicorn: (pid 1944) 1070s; run: log: (pid 1931) 1070s
usern@this-pc:~$ sudo ufw status 
Status: active

To                         Action      From
--                         ------      ----
80/tcp                     ALLOW       Anywhere                  
443/tcp                    ALLOW       Anywhere                  
OpenSSH                    ALLOW       Anywhere                  
80/tcp (v6)                ALLOW       Anywhere (v6)             
443/tcp (v6)               ALLOW       Anywhere (v6)             
OpenSSH (v6)               ALLOW       Anywhere (v6)             

usern@this-pc:~$ wget http://gitlab.example.com
--2020-05-06 15:49:44--  http://gitlab.example.com/
Resolving gitlab.example.com (gitlab.example.com)... failed: Name or service not known.
wget: unable to resolve host address ‘gitlab.example.com’

Uninstalling as per https://askubuntu.com/q/824696/

usern@this-pc:~$ sudo gitlab-ctl stop
[sudo] password for usern: 
ok: down: alertmanager: 1s, normally up
ok: down: gitaly: 0s, normally up
ok: down: gitlab-exporter: 0s, normally up
ok: down: gitlab-workhorse: 1s, normally up
ok: down: grafana: 0s, normally up
ok: down: logrotate: 1s, normally up
ok: down: nginx: 0s, normally up
ok: down: node-exporter: 0s, normally up
ok: down: postgres-exporter: 1s, normally up
ok: down: postgresql: 0s, normally up
ok: down: prometheus: 1s, normally up
ok: down: redis: 0s, normally up
ok: down: redis-exporter: 1s, normally up
ok: down: sidekiq: 0s, normally up
ok: down: unicorn: 1s, normally up
usern@this-pc:~$ sudo gitlab-ctl uninstall
ok: down: alertmanager: 16s, normally up
ok: down: gitaly: 14s, normally up
ok: down: gitlab-exporter: 14s, normally up
ok: down: gitlab-workhorse: 14s, normally up
ok: down: grafana: 13s, normally up
ok: down: logrotate: 13s, normally up
ok: down: nginx: 12s, normally up
ok: down: node-exporter: 12s, normally up
ok: down: postgres-exporter: 12s, normally up
ok: down: postgresql: 11s, normally up
ok: down: prometheus: 11s, normally up
ok: down: redis: 10s, normally up
ok: down: redis-exporter: 10s, normally up
ok: down: sidekiq: 9s, normally up
ok: down: unicorn: 8s, normally up
could not find alertmanager runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: alertmanager: 16s, normally up
could not find gitaly runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: gitaly: 14s, normally up
could not find gitlab-exporter runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: gitlab-exporter: 14s, normally up
could not find gitlab-workhorse runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: gitlab-workhorse: 14s, normally up
could not find grafana runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: grafana: 13s, normally up
could not find logrotate runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: logrotate: 13s, normally up
could not find nginx runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: nginx: 12s, normally up
could not find node-exporter runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: node-exporter: 12s, normally up
could not find postgres-exporter runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: postgres-exporter: 12s, normally up
could not find postgresql runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: postgresql: 11s, normally up
could not find prometheus runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: prometheus: 11s, normally up
could not find redis runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: redis: 10s, normally up
could not find redis-exporter runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: redis-exporter: 10s, normally up
could not find sidekiq runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: sidekiq: 9s, normally up
could not find unicorn runit pidfile (service already stopped?), cannot attempt SIGKILL...
ok: down: unicorn: 8s, normally up
Terminating processes running under application users. This will take a few seconds.
Your config files have been backed up to /root/gitlab-cleanse-2020-05-06T16:45.
usern@this-pc:~$ sudo gitlab-ctl cleanse
    *******************************************************************
    * * * * * * * * * * *       STOP AND READ       * * * * * * * * * *
    *******************************************************************




ok: down: alertmanager: 1s, normally up
ok: down: gitaly: 0s, normally up
ok: down: gitlab-exporter: 0s, normally up
ok: down: gitlab-workhorse: 0s, normally up
ok: down: grafana: 1s, normally up
ok: down: logrotate: 0s, normally up
ok: down: nginx: 1s, normally up
ok: down: node-exporter: 0s, normally up
ok: down: postgres-exporter: 0s, normally up
ok: down: postgresql: 0s, normally up
ok: down: prometheus: 0s, normally up
ok: down: redis: 1s, normally up
ok: down: redis-exporter: 0s, normally up
ok: down: sidekiq: 1s, normally up
ok: down: unicorn: 0s, normally up
alertmanager disabled, not stopping
gitaly disabled, not stopping
gitlab-exporter disabled, not stopping
gitlab-workhorse disabled, not stopping
grafana disabled, not stopping
logrotate disabled, not stopping
nginx disabled, not stopping
node-exporter disabled, not stopping
postgres-exporter disabled, not stopping
postgresql disabled, not stopping
prometheus disabled, not stopping
redis disabled, not stopping
redis-exporter disabled, not stopping
sidekiq disabled, not stopping
unicorn disabled, not stopping
Terminating processes running under application users. This will take a few seconds.
Your config files have been backed up to /root/gitlab-cleanse-2020-05-06T16:47.
usern@this-pc:~$ sudo dpkg -P gitlab-ee 
(Reading database ... 251007 files and directories currently installed.)
Removing gitlab-ee (12.10.2-ee.0) ...
Purging configuration files for gitlab-ee (12.10.2-ee.0) ...
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/sv' not empty so not removed
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/init' not empty so not removed
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/etc' not empty so not removed
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/embedded/ssl/certs' not empty so not removed
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/embedded/service/gitlab-shell' not empty so not removed
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/embedded/service/gitlab-rails/public' not empty so not removed
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/embedded/service/gitlab-rails/config/initializers' not empty so not removed
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/embedded/cookbooks' not empty so not removed
dpkg: warning: while removing gitlab-ee, directory '/opt/gitlab/embedded/bin' not empty so not removed