uyuni icon indicating copy to clipboard operation
uyuni copied to clipboard

Can't bootstrap new servers with Uyuni 2022.06

Open phibid opened this issue 2 years ago • 5 comments

After the upgrade of the Uyuni proxies/server to 2022.06, I am not able to bootstrap anymore:

# spacecmd -u admin -p xx -- system_bootstrap --hostname rocky8 --ssh-user uyuni --ssh-password xx --activation-key 1-rocky8 --proxyid '1000010024'
INFO: Spacewalk Username: admin
INFO: Connected to https://uyuni_proxy/rpc/api as admin
Bootstrapping 'rocky8'. This may take a while.
ERROR: redstone.xmlrpc.XmlRpcFault: [An error has occurred during salt execution: unable to establish ssh connection.]

Not working with any OS.

The only log I have spot until now is this one in /var/log/salt/api

2022-07-25 18:18:54,574 [salt.client.ssh  :1207][ERROR   ][52889] Error running ssh_pre_flight script preflight.sh for host 'rocky8'

phibid avatar Jul 25 '22 18:07 phibid

As mentioned by Simon Avery by mail, seems that now the noexec flag is not welcome on /tmp anymore. And the user used for registration (in my case I use a temp user for registration only) needs to have a home directory:

Standard output:
uyuni@rocky8's password:

Standard error:
Could not chdir to home directory /home/uyuni: No such file or directory
Error: Unable to extract the bundle from /tmp/salt-bundle-aQl2bspII5/venv-salt-minion-3004-3.7.uyuni.x86_64.rpm!

I have removed the noexec flag and created the home for the registration user, however it still does not work. Something is still missing:

ERROR: Failure deploying ext_mods: 
uyuni@rocky8's password: 
_edbc7885e4f9aac9b83b35999b68d015148caf467b78fa39c05f669c0ff89878
ext_mods

Note that bootstrapping does not work with spacecmd nor from the GUI. Will update this issue description accordingly.

phibid avatar Jul 26 '22 08:07 phibid

Ah, found this (https://www.suse.com/releasenotes/x86_64/SUSE-MANAGER/4.3/index.html):

image

Have tried this:

[root@rocky8 tmp]# chown -R uyuni: /var/tmp/.*_salt

And the bootstrapping now works. Do you know if this has been corrected in 2022.07, because for us this is pretty annoying :-)

phibid avatar Jul 26 '22 08:07 phibid

As a working workaround, instead of having a first failed attempt, the creation of the empty salt thin directory with the correct ownership permissions works.

phibid avatar Jul 26 '22 08:07 phibid

I was mistaken with the noexec flag. Issue during bootstrapping is when this flag is present on /var/tmp FS and not on /tmp.

phibid avatar Jul 26 '22 10:07 phibid

Same on 2022.08 running bootstrap from GUI, non-root user - getting ERROR: Failure deploying ext_mods: Password: _edbc7885e4f9aac9b83b35999b68d015148caf467xxxxxxxxxxxxxxxxxxxx ext_mods

folder /var/tmp/venv-salt-minion is with correct permissions folder and all inside /var/tmp/.kssystem_79a8cb_salt/ is root:root

when I use root for bootstrap all is ok, but this option I dont want to use.

Luiginoo007 avatar Aug 22 '22 22:08 Luiginoo007