Link to home
Start Free TrialLog in
Avatar of steve_bagnall
steve_bagnall

asked on

(Access is denied) Exception when trying to deploy WebStart on Terminal Services

Hi,

We're getting the following Web Start errors when attempting to deploy an application using Java WebStart over Terminal Services.  Anybody have any experience with doing this?

Cheers, Steve


General

An error occurred while launching/running the application.

Category: Invalid Argument Error

Could not load file/URL specified: \\churchill-ts-99\c$\Documents and Settings\
All Users\Application Data\Sun\Java\Deployment\cache\javaws\http\D10.0.1.55\P80\DMjnlp




Exception

CouldNotLoadArgumentException[ Could not load file/URL specified:
\\churchill-ts-99\c$\Documents and Settings\All Users\Application Data\Sun\Java
\Deployment\cache\javaws\http\D10.0.1.55\P80\DMjnlp]
      at com.sun.javaws.Main.launchApp(Unknown Source)
      at com.sun.javaws.Main.main(Unknown Source)







Wrapped Exception

java.io.FileNotFoundException: \\churchill-ts-99\c$\Documents and Settings\All Users
\Application Data\Sun\Java\Deployment\cache\javaws\http\D10.0.1.55\P80\DMjnlp
(Access is denied)
      at java.io.FileInputStream.open(Native Method)
      at java.io.FileInputStream.<init>(Unknown Source)
      at java.io.FileInputStream.<init>(Unknown Source)
      at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
      at com.sun.javaws.Main.launchApp(Unknown Source)
      at com.sun.javaws.Main.main(Unknown Source)
Avatar of aozarov
aozarov

It seems as if you don't have permissions to acces that shared folder
Try usign explorer and go to : : \\churchill-ts-99\c$\Documents and Settings\All Users\Application Data\Sun\Java\Deployment\cache\javaws\http\D10.0.1.55\P80\DMjnlp
Avatar of steve_bagnall

ASKER

Hi thanks for your response.  I got a windows error saying "windows cannot find, ........check your spelling and try again".

Cheers.

Steve
if you cann't use standard file explorer to see \\churchill-ts-99\c$\Documents and Settings\All Users\Application Data\Sun\Java\Deployment\cache\javaws\http\D10.0.1.55\P80\DMjnlp
 you will definetly not be able to see it from Java.
How do you start javaws (what is the argument)?
Sorry - that was from a browser.  In Windows explorer we get the message "Access to the resource is disallowed".  This is from the TS session, is that what you mean.

With respect to starting javaws, we just point a browser at the jnlp file - is this what you mean?

Cheers, Steve
>>   In Windows explorer we get the message "Access to the resource is disallowed".  
So that is your problem. you need to have permissions to access this folder/file

>> With respect to starting javaws, we just point a browser at the jnlp file - is this what you mean?
Right.

Is the jnlp file you are trying to access directly also visible thru an http server?
Can you access it thru http://some_ip_address/path_to_jnlp/file_name.jnlp?
That is the prefered way.
Our admin is telling me that any authenticated user has full access rights to NTFS and share permissions.  

Also, when we point the browser directly at the JNLP file on the web server, it starts to load the application, but then nothing happens (the splash screen displays and then disappears and that's it).  Note: doing this does not start a javaws task in the task manager on the TS server.  Strange.
>> Our admin is telling me that any authenticated user has full access rights to NTFS and share permissions.  
But you told me "In Windows explorer we get the message "Access to the resource is disallowed". " so you can't gain direct access
to it.

>> Also, when we point the browser directly at the JNLP file on the web server, it starts to load the application
That is a good start (if javaws was invoked and triggered your application)

Can you provide the jnlp text file here.
I've left her looking into that - I think this is some sort of TS security thing.

The jnlp file follows (this works on stand-alone machines - just not on TS sessions):


JNLP FILE ==================


<?xml version="1.0" encoding="utf-8"?>
<!-- JNLP File for Gap Analysis Application -->
<jnlp spec="1.5+" codebase="http://10.0.1.55" href="jnlp/gapdataclient.jnlp">
      <information>    
            <title>Gap Analysis Client</title>
            <vendor>Churchill China (UK) Ltd</vendor>
            <homepage href="docs/help.html" />
            <description>Gap Analysis Client</description>
            <description kind="short">Client-Server application for recording and viewing product placement marketing data.</description>
          <icon href="assets/gap_logo_48_48.gif" />
          <icon kind="splash" href="assets/gap_logo_48_48.gif" />
          <offline-allowed />
          <association mime-type="application-x/gapanalysis-file" extensions="gapanalysis" />
          <shortcut online="false">
                <desktop />
                <menu submenu="Churchill China Applications" />
          </shortcut>  
   </information>  
   
   <information os="linux">      
            <title>Gap Analysis on Linux</title>
            <homepage href="docs/linuxhelp.html" />  
      </information>  
      <security>
            <all-permissions/>  
      </security>  
      <resources>    
            <j2se version="1.4.2+" java-vm-args="-esa -Xnoclassgc" />    
            <jar href="/jars/gapdataclient.jar"/>  
      </resources>  
      <application-desc main-class="com.churchillchina.gapanalysis.GapDataClient" />
</jnlp>
ASKER CERTIFIED SOLUTION
Avatar of aozarov
aozarov

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
OK ... going to http://10.0.1.55/jnlp/gapdataclient.jnlp using a Terminal Services session browser loads the splash image of the application, the image disappears, and the web page goes to a 404 File Not Found.

Background info:
We have a test Terminal Services server, which to try and solve this problem we went into as administrator and downloaded and launched the application on the server directly using WS we call this server 99 (this is the server used up until now).  We also have a live server 01 which we have not done anthing to, no JRE nothing.

Interestingly going to http://10.0.1.55/jars/gapdataclient.jar using a browser in a Terminal Services session logged on to server 99 launches the application!  

Going to http://10.0.1.55/jars/gapdataclient.jar using a browser in a Terminal Services session logged on to server 01 causes  the error "Could not find the main class.  The program will exit"

The Terminal services server (99), as described above has the JRE1.5 runtime installed on it.

Presumably just pointing a browser at the jar will bypass all the functions of WS or something?

>> Going to http://10.0.1.55/jars/gapdataclient.jar using a browser in a Terminal Services session logged on to server 01 causes  the error "Could not find the main class.  The program will exit"
what JDK do you have there. (probably require java SDK >= 1.4.2)

>> Interestingly going to http://10.0.1.55/jars/gapdataclient.jar using a browser in a Terminal Services session logged on to server 99 launches the application!  
Looks like an executable jar.

try doing:
telnet  10.0.1.55 80
GET /jnlp/gapdataclient.jnlp <enter>
<enter>

and see what you get back.
Good morning,

We have JDK1.5.0 installed on the TS server, and unfortunately our TS sessions do not have a command prompt available, or any kind of telnet client.

Cheers, Steve.
Not quite solved this, but think it is something to do with access rights - will post solution when I find it.