Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ibmdi.CommandLine connector, java.io.IOException: Too many open files

43 views
Skip to first unread message

Bjorn.H...@hydro.com

unread,
Jun 21, 2005, 7:25:44 AM6/21/05
to
Hello!

After having applied FixPack 2 (FP0002) on the top of ITDI 5.2.0 we are
experiencing problems with the following code:

var aName = "password";
var comm = "/local/bin/apg -M l -n 1 -x 8 -m 8";
var parser = system.getParser ("ibmdi.CSV");
parser.setParam("csvColumns", aName);
var conn= system.getConnector("ibmdi.CommandLine");
conn.setParam("commandLine", comm);
conn.setParser(parser);
conn.initialize(null);
conn.selectEntries();
var e= conn.getNextEntry();
var pass = e.getString(aName);
ret.value = pass.substring(0,7);

The error does not show at once but tends to occur when we have processed
a great many objects with the iterator.
I cannot remember having seen this error at all when running 5.2.0:


ERROR - [updatePEOPLE] while mapping attribute "userpassword"
java.io.IOException: Too many open files
at java.lang.UNIXProcess.forkAndExec(Native Method)
at java.lang.UNIXProcess.<init>(UNIXProcess.java:56)
at java.lang.Runtime.execInternal(Native Method)
at java.lang.Runtime.exec(Runtime.java:566)
at java.lang.Runtime.exec(Runtime.java:428)
at java.lang.Runtime.exec(Runtime.java:364)
at java.lang.Runtime.exec(Runtime.java:326)
at com.ibm.di.connector.CommandLineConnector.initialize(Unknown
Source)
at sun.reflect.GeneratedMethodAccessor29.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:230)
at
org.mozilla.javascript.ScriptRuntime.call(ScriptRuntime.java:1191)
at
org.mozilla.javascript.gen.c1276.call(updatePEOPLE.AttributeMap.userpassword:11)
at
org.mozilla.javascript.gen.c1276.exec(updatePEOPLE.AttributeMap.userpassword)
at
com.ibm.di.server.AttributeMapping$SingleAttributeMap.eval(Unknown Source)
at com.ibm.di.server.AttributeMapping.mapAttribute(Unknown Source)
at com.ibm.di.server.AttributeMapping.mapEntry(Unknown Source)
at com.ibm.di.server.AttributeMapping.mapEntry(Unknown Source)
at com.ibm.di.server.AssemblyLineComponent.modify(Unknown Source)
at com.ibm.di.server.AssemblyLineComponent.update(Unknown Source)
at com.ibm.di.server.AssemblyLine.msExecuteNextConnector(Unknown
Source)
at com.ibm.di.server.AssemblyLine.executeMainStep(Unknown Source)
at com.ibm.di.server.AssemblyLine.executeAL(Unknown Source)
at com.ibm.di.server.AssemblyLine.run(Unknown Source)


Any hints?

Thanks,
Bjorn

Christian Chateauvieux

unread,
Jun 21, 2005, 12:20:38 PM6/21/05
to
Bjorn,

the line

> ret.value = pass.substring(0,7);

suggests you're invoking this code from an attribute map. So my first
comment would be to not use

> var conn= system.getConnector("ibmdi.CommandLine");

but

> var myConn= system.getConnector("ibmdi.CommandLine");

as conn as got a meaning in ITDI (it is a bean, just like work, current,
error) and is an instance of an entry object.

Anyways, after the last line you should probably close the connector you
create by scripting by putting a

myConn.terminate();

call. This should free up ressources. Not certain why you couldn't see
this behaviour with earlier versions of ITDI, but I'd guess a Java
security setting was changed in the newer JVM ITDI provides.

Hope this helps,

Christian

Bjorn.H...@hydro.com

unread,
Jun 23, 2005, 2:29:01 AM6/23/05
to
Hello, Christian!

It seems that the problem is then solved,
thank you!

Bjorn

0 new messages