0

I am trying to install microstack on 20.04.1 LTS (Focal Fossa). When I try to init, it fails with below error:

sudo microstack init --auto --control
2021-02-23 03:42:58,127 - microstack_init - INFO - Configuring clustering ...
2021-02-23 03:42:58,254 - microstack_init - INFO - Setting up as a control node.
2021-02-23 03:43:03,025 - microstack_init - INFO - Configuring networking ...
2021-02-23 03:43:10,238 - microstack_init - INFO - Opening horizon dashboard up to *
2021-02-23 03:43:11,968 - microstack_init - INFO - Waiting for RabbitMQ to start ...
Waiting for 10.0.2.15:5672
2021-02-23 03:43:12,562 - microstack_init - INFO - RabbitMQ started!
2021-02-23 03:43:12,562 - microstack_init - INFO - Configuring RabbitMQ ...
2021-02-23 03:43:14,159 - microstack_init - INFO - RabbitMQ Configured!
2021-02-23 03:43:14,190 - microstack_init - INFO - Waiting for MySQL server to start ...
Waiting for 10.0.2.15:3306
2021-02-23 03:43:15,194 - microstack_init - INFO - Mysql server started! Creating databases ...
2021-02-23 03:43:16,218 - microstack_init - INFO - Configuring Keystone Fernet Keys ...
2021-02-23 03:43:27,706 - microstack_init - INFO - Bootstrapping Keystone ...
2021-02-23 03:43:48,805 - microstack_init - INFO - Creating service project ...
Traceback (most recent call last):
  File "/snap/microstack/222/bin/microstack", line 11, in <module>
    load_entry_point('microstack==0.0.1', 'console_scripts', 'microstack')()
  File "/snap/microstack/222/lib/python3.8/site-packages/microstack/main.py", line 44, in main
    cmd()
  File "/snap/microstack/222/lib/python3.8/site-packages/init/main.py", line 58, in wrapper
    return func(*args, **kwargs)
  File "/snap/microstack/222/lib/python3.8/site-packages/init/main.py", line 206, in init
    question.ask()
  File "/snap/microstack/222/lib/python3.8/site-packages/init/questions/question.py", line 210, in ask
    self.yes(awr)
  File "/snap/microstack/222/lib/python3.8/site-packages/init/questions/__init__.py", line 435, in yes
    check('openstack', 'project', 'create', '--domain',
  File "/snap/microstack/222/lib/python3.8/site-packages/init/shell.py", line 69, in check
    raise subprocess.CalledProcessError(proc.returncode, " ".join(args))
subprocess.CalledProcessError: Command 'openstack project create --domain default --description Service Project service' returned non-zero exit status 1.

What could be the reason?

fatihc
  • 1

2 Answers2

1

I didn't had lxd installed and solved by running:

sudo snap install lxd && sudo lxd init

After that, just run the following command again and you're done:

sudo microstack init
0

Update: I ended up doing a complete reinstall of Ubuntu 20.04 on the machine. I was using it previously as a k8s node and stopping all the services + using kubeadm reset didn't fix it the microstack install issues.

After the fresh install, I hit this error later in the init:

subprocess.CalledProcessError: Command 'openstack network create test' returned non-zero exit status 1.

And solved it by installing python3-neutronclient and retring the microstack init.

sudo apt install python3-neutronclient

It finally finished with no errors after that!


I faced the same issue and followed the steps in this answer by kyodake to make sure my Ubuntu machine was fully updated:

Follow these steps:

  1. Try configuring unconfigured packages:

    sudo dpkg --configure -a
    
  2. Update the contents of the repositories

    sudo apt-get update
    
  3. Try to fix missing dependencies:

    sudo apt-get -f install
    
  4. Update all packages with new versions available:

    sudo apt-get full-upgrade
    
  5. Reinstall Ubuntu desktop:

    sudo apt-get install --reinstall ubuntu-desktop
    
  6. Remove unnecessary packages:

    sudo apt-get autoremove
    
  7. Delete downloaded packages already installed:

    sudo apt-get clean
    
  8. Reboot the system to see if the issue was resolved:

    sudo reboot
    

After doing all the updates, upgrades, clean, and reboot, I was able to successfully run the same init command you used.