Believe me, Dan: I tried. See what's happen:

hel...@xavante:~/jini/servicos$ ls
jsk-all.policy                   start-transient-jeri-all.config~
transient-jeri-mahalo.config~
jsk-all.policy~                  start-transient-jeri-mahalo.config
transient-jeri-mercury.config
start-jeri-all                   start-transient-jeri-reggie.config
transient-jeri-norm.config
start-jeri-mahalo                start-transient-jrmp-reggie.config
transient-jeri-outrigger.config
start-jeri-reggie                start-ws
transient-jeri-reggie.config
start-jrmp-reggie                transient-jeri-fiddler.config
transient-jrmp-reggie.config
start-transient-jeri-all.config  transient-jeri-mahalo.config
transient-jrmp-reggie.config~

hel...@xavante:~/jini/servicos$ java
-Djava.security.policy=/home/helcio/jini/servicos/jsk-all.policy -jar
/usr/local/apache-river-2.1.1/lib/start.jar
start-transient-jeri-all.config
12/01/2011 14:06:24 com.sun.jini.tool.ClassServer run
INFO: ClassServer started [[/usr/local/apache-river-2.1.1/lib-dl/],
port 8080]
fiddler-dl.jar requested from localhost:53966
jsk-dl.jar requested from localhost:53967
12/01/2011 14:06:25 com.sun.jini.fiddler.FiddlerImpl logInfoStartup
INFO: Fiddler started: be294032-160b-4f4e-85df-b81f15020e29, [public],
[]
fiddler-dl.jar probed from localhost:53968
fiddler-dl.jar requested from localhost:53969
jsk-dl.jar requested from localhost:53970
mahalo-dl.jar requested from localhost:53971
jsk-dl.jar requested from localhost:53972
12/01/2011 14:06:25 com.sun.jini.mahalo.TxnManagerImpl doInit
INFO: Mahalo started: com.sun.jini.mahalo.transientmahaloi...@1c9b9ca
mahalo-dl.jar probed from localhost:53973
mahalo-dl.jar requested from localhost:53974
mercury-dl.jar requested from localhost:53975
jsk-dl.jar requested from localhost:53976
12/01/2011 14:06:25 com.sun.jini.mercury.MailboxImpl doInit
INFO: Mercury started:
com.sun.jini.mercury.transientmercuryi...@12c7568
mercury-dl.jar probed from localhost:53977
mercury-dl.jar requested from localhost:53978
norm-dl.jar requested from localhost:53979
jsk-dl.jar requested from localhost:53980
12/01/2011 14:06:25 com.sun.jini.norm.NormServerBaseImpl init
INFO: Norm service started:
TransientNormServerImpl[05c1a71a-3039-4db6-a990-c98aa866c009]
norm-dl.jar probed from localhost:53981
norm-dl.jar requested from localhost:53982
outrigger-dl.jar requested from localhost:53983
jsk-dl.jar requested from localhost:53984
12/01/2011 14:06:26 com.sun.jini.outrigger.OutriggerServerImpl <init>
INFO: Outrigger server started:
com.sun.jini.outrigger.outriggerserveri...@145f0e3
outrigger-dl.jar probed from localhost:53985
outrigger-dl.jar requested from localhost:53986
reggie-dl.jar requested from localhost:53987
jsk-dl.jar requested from localhost:53988
12/01/2011 14:06:26 com.sun.jini.reggie.RegistrarImpl init
INFO: started Reggie: 526769d4-d710-45c8-9f3e-ce567f75976f, [public],
ConstrainableLookupLocator[[jini://xavante/], [null]]
reggie-dl.jar probed from localhost:53989
reggie-dl.jar requested from localhost:53991
12/01/2011 14:06:27 net.jini.lookup.JoinManager$ProxyReg fail
INFO: JoinManager - failure
java.security.AccessControlException: access denied
(java.net.SocketPermission 127.17.3.161:47898 connect,resolve)
        at 
java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
        at 
java.security.AccessController.checkPermission(AccessController.java:546)
        at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
        at java.lang.SecurityManager.checkConnect(SecurityManager.java:1034)
        at java.net.Socket.connect(Socket.java:524)
        at 
net.jini.jeri.tcp.TcpEndpoint$ConnectionEndpointImpl.connectToSocketAddress(TcpEndpoint.java:678)
        at 
net.jini.jeri.tcp.TcpEndpoint$ConnectionEndpointImpl.connectToHost(TcpEndpoint.java:608)
        at 
net.jini.jeri.tcp.TcpEndpoint$ConnectionEndpointImpl.connect(TcpEndpoint.java:543)
        at 
net.jini.jeri.connection.ConnectionManager.connect(ConnectionManager.java:228)
        at 
net.jini.jeri.connection.ConnectionManager$ReqIterator.next(ConnectionManager.java:629)
        at 
net.jini.jeri.BasicObjectEndpoint$1.next(BasicObjectEndpoint.java:371)
        at 
net.jini.jeri.BasicInvocationHandler.invokeRemoteMethodOnce(BasicInvocationHandler.java:708)
        at 
net.jini.jeri.BasicInvocationHandler.invokeRemoteMethod(BasicInvocationHandler.java:659)
        at 
net.jini.jeri.BasicInvocationHandler.invoke(BasicInvocationHandler.java:528)
        at com.sun.jini.reggie.$Proxy13.register(Unknown Source)
        at com.sun.jini.reggie.RegistrarProxy.register(RegistrarProxy.java:107)
        at net.jini.lookup.JoinManager$ProxyReg.register(JoinManager.java:1222)
        at net.jini.lookup.JoinManager$RegisterTask.run(JoinManager.java:784)
        at 
net.jini.lookup.JoinManager$ProxyRegTask.tryOnce(JoinManager.java:608)
        at com.sun.jini.thread.RetryTask.run(RetryTask.java:131)
        at com.sun.jini.thread.TaskManager$TaskThread.run(TaskManager.java:331)
12/01/2011 14:06:27 net.jini.lookup.JoinManager$ProxyReg fail
INFO: JoinManager - failure
java.security.AccessControlException: access denied
(java.net.SocketPermission 127.17.3.161:47898 connect,resolve)
        at 
java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
        at 
java.security.AccessController.checkPermission(AccessController.java:546)
        at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
        at java.lang.SecurityManager.checkConnect(SecurityManager.java:1034)
        at java.net.Socket.connect(Socket.java:524)
        at 
net.jini.jeri.tcp.TcpEndpoint$ConnectionEndpointImpl.connectToSocketAddress(TcpEndpoint.java:678)

  In other words, the exception occured again!

   Helcio Wagner.

011/1/12 Dan Creswell <dan.cresw...@gmail.com>:
> Try specifying a full path for that policy file instead of a relative
> one....
>
> On 12 January 2011 16:52, helcio silva <sunnywheathe...@gmail.com> wrote:
>
>>   Hi, Dan. The policy file is properly located. See where it is located:
>>
>> hel...@xavante:~/jini/servicos$ ls
>> jsk-all.policy                   start-transient-jeri-all.config~
>> transient-jeri-mahalo.config~
>> jsk-all.policy~                  start-transient-jeri-mahalo.config
>> transient-jeri-mercury.config
>> start-jeri-all                   start-transient-jeri-reggie.config
>> transient-jeri-norm.config
>> start-jeri-mahalo                start-transient-jrmp-reggie.config
>> transient-jeri-outrigger.config
>> start-jeri-reggie                start-ws
>> transient-jeri-reggie.config
>> start-jrmp-reggie                transient-jeri-fiddler.config
>> transient-jrmp-reggie.config
>> start-transient-jeri-all.config  transient-jeri-mahalo.config
>> transient-jrmp-reggie.config~
>>
>>   Now, see how I try to start ServiceStarter and what's happen:
>>
>> hel...@xavante:~/jini/servicos$ java
>> -Djava.security.policy=jsk-all.policy -jar
>> /usr/local/apache-river-2.1.1/lib/start.jar
>> start-transient-jeri-all.config
>> 12/01/2011 13:45:24 com.sun.jini.tool.ClassServer run
>> INFO: ClassServer started [[/usr/local/apache-river-2.1.1/lib-dl/],
>> port 8080]
>> fiddler-dl.jar requested from localhost:55436
>> jsk-dl.jar requested from localhost:55437
>> 12/01/2011 13:45:24 com.sun.jini.fiddler.FiddlerImpl logInfoStartup
>> INFO: Fiddler started: 5c9bdbf4-8622-4847-b3e2-dd82cf955272, [public],
>> []
>> fiddler-dl.jar probed from localhost:55438
>> fiddler-dl.jar requested from localhost:55439
>> jsk-dl.jar requested from localhost:55440
>> mahalo-dl.jar requested from localhost:55441
>> jsk-dl.jar requested from localhost:55442
>> 12/01/2011 13:45:25 com.sun.jini.mahalo.TxnManagerImpl doInit
>> INFO: Mahalo started: com.sun.jini.mahalo.transientmahaloi...@1c9b9ca
>> mahalo-dl.jar probed from localhost:55443
>> mahalo-dl.jar requested from localhost:55444
>> mercury-dl.jar requested from localhost:55445
>> jsk-dl.jar requested from localhost:55446
>> 12/01/2011 13:45:25 com.sun.jini.mercury.MailboxImpl doInit
>> INFO: Mercury started:
>> com.sun.jini.mercury.transientmercuryi...@12c7568
>> mercury-dl.jar probed from localhost:55447
>> mercury-dl.jar requested from localhost:55448
>> norm-dl.jar requested from localhost:55449
>> jsk-dl.jar requested from localhost:55450
>> 12/01/2011 13:45:25 com.sun.jini.norm.NormServerBaseImpl init
>> INFO: Norm service started:
>> TransientNormServerImpl[bd9baf0a-cd81-4387-91ea-db85dba01f20]
>> norm-dl.jar probed from localhost:55451
>> norm-dl.jar requested from localhost:55452
>> outrigger-dl.jar requested from localhost:55453
>> jsk-dl.jar requested from localhost:55454
>> 12/01/2011 13:45:26 com.sun.jini.outrigger.OutriggerServerImpl <init>
>> INFO: Outrigger server started:
>> com.sun.jini.outrigger.outriggerserveri...@145f0e3
>> outrigger-dl.jar probed from localhost:55455
>> outrigger-dl.jar requested from localhost:55456
>> reggie-dl.jar requested from localhost:55457
>> jsk-dl.jar requested from localhost:55458
>> 12/01/2011 13:45:26 com.sun.jini.reggie.RegistrarImpl init
>> INFO: started Reggie: 3585a177-03c4-4213-bb55-1b432693fdd9, [public],
>> ConstrainableLookupLocator[[jini://xavante/], [null]]
>> reggie-dl.jar probed from localhost:55459
>> reggie-dl.jar requested from localhost:55460
>> 12/01/2011 13:45:26 net.jini.lookup.JoinManager$ProxyReg fail
>> INFO: JoinManager - failure
>> java.security.AccessControlException: access denied
>> (java.net.SocketPermission 127.17.3.161:48814 connect,resolve)
>>         at
>> java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
>>        at
>> java.security.AccessController.checkPermission(AccessController.java:546)
>>        at
>> java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
>>        at java.lang.SecurityManager.checkConnect(SecurityManager.java:1034)
>>        at java.net.Socket.connect(Socket.java:524)
>>        at
>> net.jini.jeri.tcp.TcpEndpoint$ConnectionEndpointImpl.connectToSocketAddress(TcpEndpoint.java:678)
>>        at
>> net.jini.jeri.tcp.TcpEndpoint$ConnectionEndpointImpl.connectToHost(TcpEndpoint.java:608)
>>        at
>> net.jini.jeri.tcp.TcpEndpoint$ConnectionEndpointImpl.connect(TcpEndpoint.java:543)
>>        at
>> net.jini.jeri.connection.ConnectionManager.connect(ConnectionManager.java:228)
>>        at
>> net.jini.jeri.connection.ConnectionManager$ReqIterator.next(ConnectionManager.java:629)
>>        at
>> net.jini.jeri.BasicObjectEndpoint$1.next(BasicObjectEndpoint.java:371)
>>        at
>> net.jini.jeri.BasicInvocationHandler.invokeRemoteMethodOnce(BasicInvocationHandler.java:708)
>>        at
>> net.jini.jeri.BasicInvocationHandler.invokeRemoteMethod(BasicInvocationHandler.java:659)
>>        at
>> net.jini.jeri.BasicInvocationHandler.invoke(BasicInvocationHandler.java:528)
>>         at com.sun.jini.reggie.$Proxy11.register(Unknown Source)
>>
>>   I can't see what is wrong. I really don't know where is the error...
>>
>>   Best regards.
>>
>>   Helcio Wagner.
>>
>> 2011/1/12 Dan Creswell <dan.cresw...@gmail.com>:
>> > Looks like you're policy isn't right on first blush.
>> >
>> > That could be because it's not located on the path you've specified or
>> > because the path in the policy file isn't right.
>> >
>> > It could also be down to where you run the start command from. I'm
>> looking
>> > at this:
>> >
>> > -Djava.security.policy=jsk-all.policy
>> >
>> > And noting that's a relative path so unless your current working
>> directory
>> > is the one in which this file is located, it won't be loaded.
>> >
>> >
>> > On 12 January 2011 15:15, helcio silva <sunnywheathe...@gmail.com>
>> wrote:
>> >
>> >>   Hello to everybody.
>> >>
>> >>   I've used to start reggie to build my client/server applications.
>> >> Now, I need to use the transaction manager, named mahalo, but I can't
>> >> start it. My first trial was try to start it after reggie, but it
>> >> throws an exception. Next, I tried to use the servicestarter utility,
>> >> but it didn't work. Some information will be provided below:
>> >>
>> >> i) the way I start the servicestarter:
>> >>
>> >> java -Djava.security.policy=jsk-all.policy -jar
>> >> /usr/local/apache-river-2.1.1/lib/start.jar
>> >> start-transient-jeri-all.config
>> >>
>> >> ii) the policy file, named jsk-all.policy:
>> >>
>> >> grant codebase "file:/usr/local/apache-river-2.1.1/lib/*" {
>> >>    permission java.security.AllPermission;
>> >> };
>> >>
>> >>
>> >
>>
>

Reply via email to