Ask Your Question
0

kolla-ansible deploy rocky: bootstrap_mariadb Exited (1); "Please configure the 'hostname' command to return a correct hostname.

asked 2019-03-06 14:03:17 -0600

benray gravatar image

updated 2019-03-07 09:59:52 -0600

I see some other issues with kolla-ansible deployments where mariadb doesn't come up, but wonder if anyone has seen this one. It's a new all-in-one rocky install on Ubuntu 16.04.6.

kolla-ansible -i ./all-in-one deploy ends with:

================== RUNNING HANDLER [mariadb : Waiting for master mariadb] ******************************************* FAILED - RETRYING: Waiting for master mariadb (10 retries left). FAILED - RETRYING: Waiting for master mariadb (9 retries left). FAILED - RETRYING: Waiting for master mariadb (8 retries left). FAILED - RETRYING: Waiting for master mariadb (7 retries left). FAILED - RETRYING: Waiting for master mariadb (6 retries left). FAILED - RETRYING: Waiting for master mariadb (5 retries left). FAILED - RETRYING: Waiting for master mariadb (4 retries left). FAILED - RETRYING: Waiting for master mariadb (3 retries left). FAILED - RETRYING: Waiting for master mariadb (2 retries left). FAILED - RETRYING: Waiting for master mariadb (1 retries left). An exception occurred during task execution. To see the full traceback, use -vvv. The error was: socket.error: [Errno 104] Connection reset by peer

fatal: [localhost]: FAILED! => {"attempts": 10, "changed": false, "module_stderr": "Traceback (most recent call last):\n File \"<stdin>\", line 113, in <module>\n File \"<stdin>\", line 105, in _ansiballz_main\n File \"<stdin>\", line 48, in invoke_module\n File \"/tmp/ansible_wait_for_payload_QRG4Ei/__main__.py\", line 629, in <module>\n File \"/tmp/ansible_wait_for_payload_QRG4Ei/__main__.py\", line 558, in main\nsocket.error: [Errno 104] Connection reset by peer\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}

Adding -vvv I get:

================== Using module file /root/cos/venv/local/lib/python2.7/site-packages/ansible/modules/utilities/logic/wait_for.py <localhost> EXEC /bin/sh -c '/usr/bin/python && sleep 0' FAILED - RETRYING: Waiting for master mariadb (1 retries left).Result was: { "attempts": 10, "changed": false, "module_stderr": "Traceback (most recent call last):\n File \"<stdin>\", line 113, in <module>\n File \"<stdin>\", line 105, in _ansiballz_main\n File \"<stdin>\", line 48, in invoke_module\n File \"/tmp/ansible_wait_for_payload_uaoycs/__main__.py\", line 629, in <module>\n File \"/tmp/ansible_wait_for_payload_uaoycs/__main__.py\", line 558, in main\nsocket.error: [Errno 104] Connection reset by peer\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1, "retries": 11 } Using module file /root/cos/venv/local/lib/python2.7/site-packages/ansible/modules/utilities/logic/wait_for.py <localhost> EXEC /bin/sh -c '/usr/bin/python && sleep 0' The full traceback is: Traceback (most recent call last): File "<stdin>", line 113, in <module> File "<stdin>", line 105, in _ansiballz_main File "<stdin>", line 48, in invoke_module File "/tmp/ansible_wait_for_payload_wFR7KE/__main__.py", line 629, in <module> File "/tmp/ansible_wait_for_payload_wFR7KE/__main__.py", line 558, in main socket.error: [Errno 104] Connection reset by peer

fatal: [localhost]: FAILED! => { "attempts": 10, "changed": false, "module_stderr": "Traceback (most recent call last):\n File \"<stdin>\", line 113, in <module>\n File \"<stdin>\", line 105, in _ansiballz_main\n File \"<stdin>\", line 48, in invoke_module\n File \"/tmp/ansible_wait_for_payload_wFR7KE/__main__.py\", line 629, in <module>\n File \"/tmp/ansible_wait_for_payload_wFR7KE/__main__.py\", line 558, in main\nsocket.error: [Errno 104] Connection reset by peer\n", "module_stdout": "", "msg": "MODULE ... (more)

edit retag flag offensive close merge delete

Comments

After cleanup and redeploy I noticed that the bootstrap_mariadb container is never coming up, so possibly this is a root cause.

kolla/ubuntu-source-mariadb:rocky "dumb-init --single-c" About a minute ago Exited (1) About a minute ago bootstrap_mariadb

benray gravatar imagebenray ( 2019-03-07 09:31:11 -0600 )edit

docker logs on this exited container show a hostname resolution issue

++ mysql_install_db Neither host 'hamilton' nor 'localhost' could be looked up with '/usr/sbin/resolveip' Please configure the 'hostname' command to return a correct hostname.

benray gravatar imagebenray ( 2019-03-07 09:32:06 -0600 )edit

However I have no issue resolving the hostname either with /etc/hosts or DNS. If the docker host doesn't have the issue, why would the bootstrap_mariadb container? I can run 'hostname' in other containers like chrony without issue.

benray gravatar imagebenray ( 2019-03-07 09:33:58 -0600 )edit

I edited the question heading to reflect the bootstrap failure and hostname error.

benray gravatar imagebenray ( 2019-03-07 10:00:30 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2019-03-07 13:36:51 -0600

benray gravatar image

I've not resolved this yet but I think I found the issue patched upstream

https://git.openstack.org/cgit/openstack/kolla-ansible/commit/?h=stable/pike (https://git.openstack.org/cgit/openst...)

edit flag offensive delete link more

Comments

confirmed! adding 'basedir=/usr' fixed this

benray gravatar imagebenray ( 2019-03-07 13:50:02 -0600 )edit

I have the same problem. "adding 'basedir=/usr' fixed this". Great but to what and where?

Gargybloke gravatar imageGargybloke ( 2019-04-02 14:03:00 -0600 )edit

I've that problem too. Can you get some details about your fix.

lklimin gravatar imagelklimin ( 2019-04-04 02:18:29 -0600 )edit

'basedir=/usr' is here https://git.openstack.org/cgit/openstack/kolla-ansible/commit/?h=stable/pike&id=3171a384916c5fe012725ae4399a64c5956f9a94 (https://git.openstack.org/cgit/openst...)

lklimin gravatar imagelklimin ( 2019-04-04 07:06:17 -0600 )edit

Hi, I'm using latest stable version and the pointed patched is already added in the files listed in that patch (both galera.cnf.j2 and tox.ini), but the issue is still there. See question number 121166. Are those files what you have changed?

carlov gravatar imagecarlov ( 2019-04-16 03:26:07 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

2 followers

Stats

Asked: 2019-03-06 14:03:17 -0600

Seen: 604 times

Last updated: Mar 07