Some people and I were having the same problem and the solution we came up with (accidentally, by the way) was to replace localhost with the machine's IP address when specifying the URL, both in the ORB config in the server and on the value passed to the env variable.
Apperently the app server assumes localhost means that both EARs are located on the same app server.
Hope this helps,

[ November 12, 2004: Message edited by: Jorge Villalobos ]