Archived

This forum has been archived. Please start a new discussion on GitHub.

createAdminSession() not working after upgrade to 3.5.1

This Python code used to work on 3.4.2, and still seems correct according to the documentation:

self.communicator = Ice.initialize(['supervise.py', \
'--Ice.Default.Locator=IceGrid/Locator:tcp -h hostname -p 4061'])
commAdmin = self.communicator.getAdmin()
registry = IceGrid.RegistryPrx.uncheckedCast(\
self.communicator.stringToProxy("IceGrid/Registry"))
self.session = registry.createAdminSession("ice", "XXXXXXXX")

(password elided).

However, I now get this error:

self.session = registry.createAdminSession("ice", "XXXXXXXXX")
File "/usr/lib64/python2.6/site-packages/Ice/IceGrid_Registry_ice.py", line 198, in createAdminSession
return _M_IceGrid.Registry._op_createAdminSession.invoke(self, ((userId, password), _ctx))
SocketException: Ice.SocketException:
Permission denied

I made sure the password was set correctly on the ice user account.

Clues welcome...

Comments

  • benoit
    benoit Rennes, France
    Hi,

    I'm not sure why this occurs but I suspect it might be caused by the fact that Ice 3.5 now enables IPv6 by default. Could you try to disable IPv6 by setting the property Ice.IPv6 to 0?

    Cheers,
    Benoit.
  • Turned out to be an SELinux issue
    benoit wrote: »
    Hi,

    I'm not sure why this occurs but I suspect it might be caused by the fact that Ice 3.5 now enables IPv6 by default. Could you try to disable IPv6 by setting the property Ice.IPv6 to 0?

    Cheers,
    Benoit.

    I tried the suggestion. I found that if I ran the code from a shell prompt, I had no problem, no need for the setting. However, it did not work from a web.py application. Disabling SElinux did the trick.

    Thanks for the help.