CLI command "omero login" crashes on LDAP user
Posted: Mon Oct 13, 2014 3:26 pm
Hi,
when I try to login with an existing LDAP user that has not yet been (automatically) imported into omero, i.e. the user hasn't logged in yet and I want to do that for him/her on the command line so that his account gets created, Java crashes. The command I am trying to use is:
The crash looks like this:
So it is apparantly not possible to login via the CLI when using --sudo=root in case the LDAP user is not yet in the OMERO db.
What would be the proper way to do this?
Cheers,
Tristan
when I try to login with an existing LDAP user that has not yet been (automatically) imported into omero, i.e. the user hasn't logged in yet and I want to do that for him/her on the command line so that his account gets created, Java crashes. The command I am trying to use is:
- Code: Select all
omero login -s localhost -u jdoe --sudo=root
The crash looks like this:
- Code: Select all
InternalException: Failed to connect: exception ::omero::RemovedSessionException
{
serverStackTrace = ome.conditions.RemovedSessionException: Cannot find a user with name jdoe
at ome.services.sessions.SessionManagerImpl.executeLookupUser(SessionManagerImpl.java:1239)
at ome.services.sessions.SessionManagerImpl.access$100(SessionManagerImpl.java:87)
at ome.services.sessions.SessionManagerImpl$2.doWork(SessionManagerImpl.java:314)
at sun.reflect.GeneratedMethodAccessor263.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at ome.services.util.Executor$Impl$Interceptor.invoke(Executor.java:576)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at ome.security.basic.EventHandler.invoke(EventHandler.java:154)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.orm.hibernate3.HibernateInterceptor.invoke(HibernateInterceptor.java:111)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:108)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at ome.tools.hibernate.ProxyCleanupFilter$Interceptor.invoke(ProxyCleanupFilter.java:241)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at ome.services.util.ServiceHandler.invoke(ServiceHandler.java:116)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at com.sun.proxy.$Proxy69.doWork(Unknown Source)
at ome.services.util.Executor$Impl.execute(Executor.java:457)
at ome.services.sessions.SessionManagerImpl.createSession(SessionManagerImpl.java:306)
at ome.services.sessions.SessionManagerImpl.createWithAgent(SessionManagerImpl.java:254)
at ome.services.sessions.SessionBean$2.call(SessionBean.java:112)
at ome.services.sessions.SessionBean$2.call(SessionBean.java:110)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
serverExceptionClass = ome.conditions.RemovedSessionException
message = Cannot find a user with name jdoe
}
So it is apparantly not possible to login via the CLI when using --sudo=root in case the LDAP user is not yet in the OMERO db.
What would be the proper way to do this?
Cheers,
Tristan