Server.xml in tomcat access denied

hello,
I am using tomcat 5.5.9 with suse (linux), and I am using jdk 1.6.0
The CATALINA_HOME, JAVA_HOME are defined,
When I try to startup the tomcat as root user every thing is ok, it
start (with port 8080)
I have create a new user with permissions to logs and work
directories, and try to startup the tomcat from command
like that su - tomcatuser -c /user/tomcathome/bin/startup.sh
every thing is ok
but wenn I try to start it from eclipse I get this message:
In Catalina.out
Jul  12, 2006 6:03:26 PM org.apache.catalina.startup.Catalina load
WARNING: Can't load server.xml
Jul 12, 2006 6:03:26 PM org.apache.catalina.startup.Catalina load
WARNING: Can't load server.xml
Jul 12, 2006 6:03:26 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 0 ms
java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
a:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
Impl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at
org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:271)
        at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:409)
Caused by: java.lang.NullPointerException
        at org.apache.catalina.startup.Catalina.await(Catalina.java:600)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:560) Can any one help,
Thanks

Click Start, click Run, type cmd in the
Open box, and then click OK.
Switch to the <var>Drive</var>:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 folder. In this folder, <var>Drive</var> is the drive where Windows is installed. To do this, type the following line at the command prompt, and then press Enter:
cd <var>Drive</var>:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
Add the appropriate permissions to the Network Service group for the Temporary ASP.NET Files folder. To do this, type the following line, and then press Enter:
aspnet_regiis -ir
cd <var>Drive</var>:\WINDOWS\Microsoft.NET\Framework\v4
Add the appropriate permissions to the Network Service group for the Temporary ASP.NET Files folder. To do this, type the following line, and then press Enter:
aspnet_regiis -ir
http://social.technet.microsoft.com/Forums/sharepoint/en-US/bf6bb272-eb75-4435-8264-6980e9e7268f/sharepoint-server-2010-access-denied-error?forum=sharepointadminprevious
Is this a claims based web application? If yes, the super reader and super user need to be added with the in the format "i:0#.w|domain\username". Also, add them with full read and full control on the web application as well.
Check AAM settings
Can you check that your databases are not set to read only. I had a similar issue after backing up the farm users were not allowed to do anything on the site. Turned out the database was set to read only in SQL.
If this helped you resolve your issue, please mark it Answered

Similar Messages

  • URgent !!!!!!!!! How do i add information to server.xml of tomcat

    Hi ,
    I want to add the conext information to my server.xml of tomcat for my hibernate configuration.....
    the conext information is as follows ....
    <Context path="/quickstart" docBase="quickstart">
    <Resource name="jdbc/quickstart" scope="Shareable" type="javax.sql.DataSource"/>
    <ResourceParams name="jdbc/quickstart">
    <parameter>
    <name>factory</name>
    <value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
    </parameter>
    <!-- DBCP database connection settings -->
    <parameter>
    <name>url</name>
    <value>jdbc:postgresql://localhost/quickstart</value>
    </parameter>
    <parameter>
    <name>driverClassName</name><value>org.postgresql.Driver</value>
    </parameter>
    <parameter>
    <name>username</name>
    <value>quickstart</value>
    </parameter>
    <parameter>
    <name>password</name>
    <value>secret</value>
    </parameter>
    <!-- DBCP connection pooling options -->
    <parameter>
    <name>maxWait</name>
    <value>3000</value>
    </parameter>
    <parameter>
    <name>maxIdle</name>
    <value>100</value>
    </parameter>
    <parameter>
    <name>maxActive</name>
    <value>10</value>
    </parameter>
    </ResourceParams>
    </Context>
    Where in my server.xml should i put
    the server.xml looks like this :
    <!-- Example Server Configuration File -->
    <!-- Note that component elements are nested corresponding to their
    parent-child relationships with each other -->
    <!-- A "Server" is a singleton element that represents the entire JVM,
    which may contain one or more "Service" instances. The Server
    listens for a shutdown command on the indicated port.
    Note: A "Server" is not itself a "Container", so you may not
    define subcomponents such as "Valves" or "Loggers" at this level.
    -->
    <Server port="8005" shutdown="SHUTDOWN">
    <!-- Comment these entries out to disable JMX MBeans support used for the
    administration web application -->
    <Listener className="org.apache.catalina.core.AprLifecycleListener" />
    <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener" />
    <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener" />
    <Listener className="org.apache.catalina.storeconfig.StoreConfigLifecycleListener"/>
    <!-- Global JNDI resources -->
    <GlobalNamingResources>
    <!-- Test entry for demonstration purposes -->
    <Environment name="simpleValue" type="java.lang.Integer" value="30"/>
    <!-- Editable user database that can also be used by
    UserDatabaseRealm to authenticate users -->
    <Resource name="UserDatabase" auth="Container"
    type="org.apache.catalina.UserDatabase"
    description="User database that can be updated and saved"
    factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
    pathname="conf/tomcat-users.xml" />
    </GlobalNamingResources>
    <!-- A "Service" is a collection of one or more "Connectors" that share
    a single "Container" (and therefore the web applications visible
    within that Container). Normally, that Container is an "Engine",
    but this is not required.
    Note: A "Service" is not itself a "Container", so you may not
    define subcomponents such as "Valves" or "Loggers" at this level.
    -->
    <!-- Define the Tomcat Stand-Alone Service -->
    <Service name="Catalina">
    <!-- A "Connector" represents an endpoint by which requests are received
    and responses are returned. Each Connector passes requests on to the
    associated "Container" (normally an Engine) for processing.
    By default, a non-SSL HTTP/1.1 Connector is established on port 8080.
    You can also enable an SSL HTTP/1.1 Connector on port 8443 by
    following the instructions below and uncommenting the second Connector
    entry. SSL support requires the following steps (see the SSL Config
    HOWTO in the Tomcat 5 documentation bundle for more detailed
    instructions):
    * If your JDK version 1.3 or prior, download and install JSSE 1.0.2 or
    later, and put the JAR files into "$JAVA_HOME/jre/lib/ext".
    * Execute:
    %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows)
    $JAVA_HOME/bin/keytool -genkey -alias tomcat -keyalg RSA (Unix)
    with a password value of "changeit" for both the certificate and
    the keystore itself.
    By default, DNS lookups are enabled when a web application calls
    request.getRemoteHost(). This can have an adverse impact on
    performance, so you can disable it by setting the
    "enableLookups" attribute to "false". When DNS lookups are disabled,
    request.getRemoteHost() will return the String version of the
    IP address of the remote client.
    -->
    <!-- Define a non-SSL HTTP/1.1 Connector on port 8080 -->
    <Connector
    port="8080" maxHttpHeaderSize="8192"
    maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
    enableLookups="false" redirectPort="8443" acceptCount="100"
    connectionTimeout="20000" disableUploadTimeout="true" />
    <!-- Note : To disable connection timeouts, set connectionTimeout value
    to 0 -->
         <!-- Note : To use gzip compression you could set the following properties :
                   compression="on"
                   compressionMinSize="2048"
                   noCompressionUserAgents="gozilla, traviata"
                   compressableMimeType="text/html,text/xml"
         -->
    <!-- Define a SSL HTTP/1.1 Connector on port 8443 -->
    <!--
    <Connector port="8443" maxHttpHeaderSize="8192"
    maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
    enableLookups="false" disableUploadTimeout="true"
    acceptCount="100" scheme="https" secure="true"
    clientAuth="false" sslProtocol="TLS" />
    -->
    <!-- Define an AJP 1.3 Connector on port 8009 -->
    <Connector port="8009"
    enableLookups="false" redirectPort="8443" protocol="AJP/1.3" />
    <!-- Define a Proxied HTTP/1.1 Connector on port 8082 -->
    <!-- See proxy documentation for more information about using this. -->
    <!--
    <Connector port="8082"
    maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
    enableLookups="false" acceptCount="100" connectionTimeout="20000"
    proxyPort="80" disableUploadTimeout="true" />
    -->
    <!-- An Engine represents the entry point (within Catalina) that processes
    every request. The Engine implementation for Tomcat stand alone
    analyzes the HTTP headers included with the request, and passes them
    on to the appropriate Host (virtual host). -->
    <!-- You should set jvmRoute to support load-balancing via AJP ie :
    <Engine name="Standalone" defaultHost="localhost" jvmRoute="jvm1">
    -->
    <!-- Define the top level container in our container hierarchy -->
    <Engine name="Catalina" defaultHost="localhost">
    <!-- The request dumper valve dumps useful debugging information about
    the request headers and cookies that were received, and the response
    headers and cookies that were sent, for all requests received by
    this instance of Tomcat. If you care only about requests to a
    particular virtual host, or a particular application, nest this
    element inside the corresponding <Host> or <Context> entry instead.
    For a similar mechanism that is portable to all Servlet 2.4
    containers, check out the "RequestDumperFilter" Filter in the
    example application (the source for this filter may be found in
    "$CATALINA_HOME/webapps/examples/WEB-INF/classes/filters").
    Request dumping is disabled by default. Uncomment the following
    element to enable it. -->
    <!--
    <Valve className="org.apache.catalina.valves.RequestDumperValve"/>
    -->
    <!-- Because this Realm is here, an instance will be shared globally -->
    <!-- This Realm uses the UserDatabase configured in the global JNDI
    resources under the key "UserDatabase". Any edits
    that are performed against this UserDatabase are immediately
    available for use by the Realm. -->
    <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
    resourceName="UserDatabase"/>
    <!-- Comment out the old realm but leave here for now in case we
    need to go back quickly -->
    <!--
    <Realm className="org.apache.catalina.realm.MemoryRealm" />
    -->
    <!-- Replace the above Realm with one of the following to get a Realm
    stored in a database and accessed via JDBC -->
    <!--
    <Realm className="org.apache.catalina.realm.JDBCRealm"
    driverName="org.gjt.mm.mysql.Driver"
    connectionURL="jdbc:mysql://localhost/authority"
    connectionName="test" connectionPassword="test"
    userTable="users" userNameCol="user_name" userCredCol="user_pass"
    userRoleTable="user_roles" roleNameCol="role_name" />
    -->
    <!--
    <Realm className="org.apache.catalina.realm.JDBCRealm"
    driverName="oracle.jdbc.driver.OracleDriver"
    connectionURL="jdbc:oracle:thin:@ntserver:1521:ORCL"
    connectionName="scott" connectionPassword="tiger"
    userTable="users" userNameCol="user_name" userCredCol="user_pass"
    userRoleTable="user_roles" roleNameCol="role_name" />
    -->
    <!--
    <Realm className="org.apache.catalina.realm.JDBCRealm"
    driverName="sun.jdbc.odbc.JdbcOdbcDriver"
    connectionURL="jdbc:odbc:CATALINA"
    userTable="users" userNameCol="user_name" userCredCol="user_pass"
    userRoleTable="user_roles" roleNameCol="role_name" />
    -->
    <!-- Define the default virtual host
    Note: XML Schema validation will not work with Xerces 2.2.
    -->
    <Host name="localhost" appBase="webapps"
    unpackWARs="true" autoDeploy="true"
    xmlValidation="false" xmlNamespaceAware="false">
    <!-- Defines a cluster for this node,
    By defining this element, means that every manager will be changed.
    So when running a cluster, only make sure that you have webapps in there
    that need to be clustered and remove the other ones.
    A cluster has the following parameters:
    className = the fully qualified name of the cluster class
    name = a descriptive name for your cluster, can be anything
    mcastAddr = the multicast address, has to be the same for all the nodes
    mcastPort = the multicast port, has to be the same for all the nodes
    mcastBindAddr = bind the multicast socket to a specific address
    mcastTTL = the multicast TTL if you want to limit your broadcast
    mcastSoTimeout = the multicast readtimeout
    mcastFrequency = the number of milliseconds in between sending a "I'm alive" heartbeat
    mcastDropTime = the number a milliseconds before a node is considered "dead" if no heartbeat is received
    tcpThreadCount = the number of threads to handle incoming replication requests, optimal would be the same amount of threads as nodes
    tcpListenAddress = the listen address (bind address) for TCP cluster request on this host,
    in case of multiple ethernet cards.
    auto means that address becomes
    InetAddress.getLocalHost().getHostAddress()
    tcpListenPort = the tcp listen port
    tcpSelectorTimeout = the timeout (ms) for the Selector.select() method in case the OS
    has a wakup bug in java.nio. Set to 0 for no timeout
    printToScreen = true means that managers will also print to std.out
    expireSessionsOnShutdown = true means that
    useDirtyFlag = true means that we only replicate a session after setAttribute,removeAttribute has been called.
    false means to replicate the session after each request.
    false means that replication would work for the following piece of code: (only for SimpleTcpReplicationManager)
    <%
    HashMap map = (HashMap)session.getAttribute("map");
    map.put("key","value");
    %>
    replicationMode = can be either 'pooled', 'synchronous' or 'asynchronous'.
    * Pooled means that the replication happens using several sockets in a synchronous way. Ie, the data gets replicated, then the request return. This is the same as the 'synchronous' setting except it uses a pool of sockets, hence it is multithreaded. This is the fastest and safest configuration. To use this, also increase the nr of tcp threads that you have dealing with replication.
    * Synchronous means that the thread that executes the request, is also the
    thread the replicates the data to the other nodes, and will not return until all
    nodes have received the information.
    * Asynchronous means that there is a specific 'sender' thread for each cluster node,
    so the request thread will queue the replication request into a "smart" queue,
    and then return to the client.
    The "smart" queue is a queue where when a session is added to the queue, and the same session
    already exists in the queue from a previous request, that session will be replaced
    in the queue instead of replicating two requests. This almost never happens, unless there is a
    large network delay.
    -->
    <!--
    When configuring for clustering, you also add in a valve to catch all the requests
    coming in, at the end of the request, the session may or may not be replicated.
    A session is replicated if and only if all the conditions are met:
    1. useDirtyFlag is true or setAttribute or removeAttribute has been called AND
    2. a session exists (has been created)
    3. the request is not trapped by the "filter" attribute
    The filter attribute is to filter out requests that could not modify the session,
    hence we don't replicate the session after the end of this request.
    The filter is negative, ie, anything you put in the filter, you mean to filter out,
    ie, no replication will be done on requests that match one of the filters.
    The filter attribute is delimited by ;, so you can't escape out ; even if you wanted to.
    filter=".*\.gif;.*\.js;" means that we will not replicate the session after requests with the URI
    ending with .gif and .js are intercepted.
    The deployer element can be used to deploy apps cluster wide.
    Currently the deployment only deploys/undeploys to working members in the cluster
    so no WARs are copied upons startup of a broken node.
    The deployer watches a directory (watchDir) for WAR files when watchEnabled="true"
    When a new war file is added the war gets deployed to the local instance,
    and then deployed to the other instances in the cluster.
    When a war file is deleted from the watchDir the war is undeployed locally
    and cluster wide
    -->
    <!--
    <Cluster className="org.apache.catalina.cluster.tcp.SimpleTcpCluster"
    managerClassName="org.apache.catalina.cluster.session.DeltaManager"
    expireSessionsOnShutdown="false"
    useDirtyFlag="true"
    notifyListenersOnReplication="true">
    <Membership
    className="org.apache.catalina.cluster.mcast.McastService"
    mcastAddr="228.0.0.4"
    mcastPort="45564"
    mcastFrequency="500"
    mcastDropTime="3000"/>
    <Receiver
    className="org.apache.catalina.cluster.tcp.ReplicationListener"
    tcpListenAddress="auto"
    tcpListenPort="4001"
    tcpSelectorTimeout="100"
    tcpThreadCount="6"/>
    <Sender
    className="org.apache.catalina.cluster.tcp.ReplicationTransmitter"
    replicationMode="pooled"
    ackTimeout="15000"/>
    <Valve className="org.apache.catalina.cluster.tcp.ReplicationValve"
    filter=".*\.gif;.*\.js;.*\.jpg;.*\.htm;.*\.html;.*\.txt;"/>
    <Deployer className="org.apache.catalina.cluster.deploy.FarmWarDeployer"
    tempDir="/tmp/war-temp/"
    deployDir="/tmp/war-deploy/"
    watchDir="/tmp/war-listen/"
    watchEnabled="false"/>
    </Cluster>
    -->
    <!-- Normally, users must authenticate themselves to each web app
    individually. Uncomment the following entry if you would like
    a user to be authenticated the first time they encounter a
    resource protected by a security constraint, and then have that
    user identity maintained across all web applications contained
    in this virtual host. -->
    <!--
    <Valve className="org.apache.catalina.authenticator.SingleSignOn" />
    -->
    <!-- Access log processes all requests for this virtual host. By
    default, log files are created in the "logs" directory relative to
    $CATALINA_HOME. If you wish, you can specify a different
    directory with the "directory" attribute. Specify either a relative
    (to $CATALINA_HOME) or absolute path to the desired directory.
    -->
    <!--
    <Valve className="org.apache.catalina.valves.AccessLogValve"
    directory="logs" prefix="localhost_access_log." suffix=".txt"
    pattern="common" resolveHosts="false"/>
    -->
    <!-- Access log processes all requests for this virtual host. By
    default, log files are created in the "logs" directory relative to
    $CATALINA_HOME. If you wish, you can specify a different
    directory with the "directory" attribute. Specify either a relative
    (to $CATALINA_HOME) or absolute path to the desired directory.
    This access log implementation is optimized for maximum performance,
    but is hardcoded to support only the "common" and "combined" patterns.
    -->
    <!--
    <Valve className="org.apache.catalina.valves.FastCommonAccessLogValve"
    directory="logs" prefix="localhost_access_log." suffix=".txt"
    pattern="common" resolveHosts="false"/>
    -->
    </Host>
    </Engine>
    </Service>
    </Server>
    Can Some one Help me pleaseeeeee

    Please don't cross-post in multiple forums. I have answered
    this in your other thread.

  • URG !!!!!!! How do i add the conext information to my server.xml of tomcat

    Hi ,
    I want to add the conext information to my server.xml of tomcat for my hibernate configuration.....
    the conext information is as follows ....
    <Context path="/quickstart" docBase="quickstart">
    <Resource name="jdbc/quickstart" scope="Shareable" type="javax.sql.DataSource"/>
    <ResourceParams name="jdbc/quickstart">
    <parameter>
    <name>factory</name>
    <value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
    </parameter>
    <!-- DBCP database connection settings -->
    <parameter>
    <name>url</name>
    <value>jdbc:postgresql://localhost/quickstart</value>
    </parameter>
    <parameter>
    <name>driverClassName</name><value>org.postgresql.Driver</value>
    </parameter>
    <parameter>
    <name>username</name>
    <value>quickstart</value>
    </parameter>
    <parameter>
    <name>password</name>
    <value>secret</value>
    </parameter>
    <!-- DBCP connection pooling options -->
    <parameter>
    <name>maxWait</name>
    <value>3000</value>
    </parameter>
    <parameter>
    <name>maxIdle</name>
    <value>100</value>
    </parameter>
    <parameter>
    <name>maxActive</name>
    <value>10</value>
    </parameter>
    </ResourceParams>
    </Context>
    Where in my server.xml should i put

    I don't think you should have to edit the server.xml
    at all. your app can have its own context.xml that
    obviates the need for editing server.xml
    %I did try that in many permutations. For some reason, the server.xml worked for me in 5.5 but not the context.xml. (Granted, it was late on Friday and I might have missed a step). :^)
    - Saish

  • How to specify URL in server.xml of Tomcat

    Hi Everybody,
    I need help.How to specify url in the server.xml.
    I developed one application in the Tomcat 3.3.I want to access the by entering uri(like:http:test.com).
    What are tags to enter in the server.xml.
    Right now i am accessing like:http://localhost:8080/Test/Login.jsp
    I want replace this with (www.test.com).
    This site will access from anywhere means it is going to live.
    So what are things have to do in the server.xml
    Please provide the solution.
    Regards
    Sridhar

    Hi Raktim:
    I looked around on SDN and it seems that i have found what you have been looking for.
    Kindly look at page number 24 and 25 of this page
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/4d46fb8a-0b01-0010-9fbe-e4b96533b222
    P.S: Kindly assign points if your query is resolved, also close the question to assist other users narrow the search and find solutions

  • Apache/Tomcat Access denied????

    hello.
    I am trying3 to run. Apache 1.3.26 and tomcat 4.0 together on Windows 2000 Pro and have had no luck. I configured the httpd.conf file with these statements and the corresponding files are in the correct directories
    <statements>
    # Load mod_jk
    LoadModule jk_module libexec/mod_jk.dll
    # Configure mod_jk
    JkWorkersFile c:/apache-tomcat-4.0/conf/jk/workers.properties
    JkLogFile c:/apache-tomcat-4.0/logs/mod_jk.log
    JkLogLevel info
    Include c:\apache-tomcat-4.0\conf\auto\mod_jk.conf
    </statements>
    now when I start up Apache.(I use a console to start it.) It tells me that Apache 1.3.26 and mod_jk1.1.0 are both running. But.... if I go to the url http://localhost/examples/jsp. I get a page not found error. Same for the http://localhost:8080(page not found). So I went to the services manager, and I tried to run the service from there and it gave me an access denied prompt. I tried the startup.bat and that didn't work either. Plus I did a reboot and did the steps in reverse order, no luck there eithr.
    Anyone ever had this problem , anyone know what it is. Any help would be appreciated.
    Brian

    Okay I have woked it down that I need to tag some properties or conf file but I need to know which file. I saw somthing about using <ApacheConfig path="<MOD_JK_Home>"> but where would I set this tag.
    Brian

  • Server 2008 R2 DC - Access Denied All Logins

    This is what the Google has to offer.
    http://serverfault.com/questions/376116/cant-login-to-windows-server-2008-as-any-user-not-even-local...

    Something weird happened today... I have a BDC that had some updates to do... I ran them and rebooted... When it came back up, I tried to RDP to it but it failed with access denied... I went to the console and I'm still getting access denied... Doesn't matter who logs in... local admins, domain admins, non admins... nothing... I can't figure out what happened... none of my other DC's are having this issue... What do I do?
    This topic first appeared in the Spiceworks Community

  • Windows Server 2008 r2 printer access denied.

    i have a windows server 2008 r2 PC with a printer installed and shared on it. when trying to access the printer from any other PC in the network i get "windows cannot connect to the printer. access is denied" this is from both a windows 7 and
    windows 8 PC.

    Helped me to set Security permissions on system with printer (Win 2008) of folder "C:\Windows\System32\spool\drivers" for group NETWORK to "Full control".

  • Access Denied while starting server   in SAPMMC

    Hi All,
    I have installed SAP ECC 5.0 sucessfully on my system and i am able to start and stop the server.
    But after installing the SAP GUI i am unable to start and stop the server.it is giving Access Denied start falied 80070005 message.
    Even if i give the start\stop instance permissions to all the users it is not accepting.
    Kindly help me to resolve the problem.
    Regards,
    HymaRao

    Hello,
    Have you tried searching this up on SDN Forums ?
    https://www.sdn.sap.com/irj/sdn/advancedsearch?query=80070005&cat=sdn_all
    You will get the following results
    SAP Note 1010540 DCOM Interface Configuration for Remote Access
    SAP Note 142100 Windows: Problems with new SAP service as of Rel. 4.5B
    Hope that helps.
    Regards,
    Siddhesh

  • Where to put server.xml

    hi!
    i am trying to deploy a servlet on tomcat.i have put files as per following tree structure
    TOMCAT_HOME
    webapps
    myApp
    web-inf(web.xml)
    classes(TestingServlet.class)
    contents of web.xml are
    <web-app>
    <servlet>
    <servlet-name>Testing</servlet-name>
    <servlet-class>TestingServlet</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>TestingServlet</servlet-name>
    <url-pattern>/Servlet/*</url-pattern>
    </servlet-mapping>
    </web-app>
    i am accessing this with URL
    http://localhost:8080/myApp/servlet/Testing
    but i am getting this error
    HTTP Status 404 - /myApp/servlet
    The requested resource (/myApp/servlet) is not available.
    i have not made context entry in conf/server.xml ,is this error due to it.
    further when i added following lines to /conf/server.xml
    my tomcat server failed to start.
    <Context path="/myApp"
    docBase="webapps/myApp"
    crossContext="false"
    debug="0"
    reloadable="true" >
    </Context>
    can anyone help me to understand this and suggest a solution.

    change web.xml
    <servlet-mapping>
       <servlet-name>TestingServlet</servlet-name>
       <url-pattern>/test</url-pattern>
    </servlet-mapping>and use
    http://localhost:8080/myApp/test
    " i have not made context entry in conf/server.xml ,is this error due to it."
    no need to add anything to server.xml to get simple apps runnning

  • HTTP tunneling T3 when using WebStart - java.security.AccessControlException: access denied

    Hi !
    WLS version: 5.1 with SP10
    Server OS: NT4
    Client distr.: Java WebStart
    Client OS: Windows 2000
    I get the following exception when I try to create a T3 connection
    (tunnelled through HTTP) to my WLS server:
    java.security.AccessControlException: access denied
    (java.util.PropertyPermission proxyHost read)
    at java.security.AccessControlContext.checkPermission(Unknown Source)
    at java.security.AccessController.checkPermission(Unknown Source)
    at java.lang.SecurityManager.checkPermission(Unknown Source)
    at java.lang.SecurityManager.checkPropertyAccess(Unknown Source)
    at java.lang.System.getProperty(Unknown Source)
    at weblogic.net.http.HttpClient.resetProperties(HttpClient.java:62)
    at weblogic.net.http.HttpClient.openServer(HttpClient.java:186)
    at weblogic.net.http.HttpClient.<init>(HttpClient.java:85)
    at weblogic.net.http.HttpClient.New(HttpClient.java:117)
    at weblogic.net.http.HttpURLConnection.connect(HttpURLConnection.java:97)
    at
    weblogic.net.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1
    44)
    at weblogic.socket.JVMSocketHTTPClient.sendMsg(JVMSocketHTTPClient.java:260)
    at weblogic.socket.JVMAbbrevSocket.sendOutMsg(JVMAbbrevSocket.java:348)
    at weblogic.socket.JVMAbbrevSocket.sendMsg(JVMAbbrevSocket.java:237)
    at weblogic.rjvm.ConnectionManager.sendMsg(ConnectionManager.java:420)
    at weblogic.rjvm.RJVMImpl.send(RJVMImpl.java:564)
    at
    weblogic.rjvm.MsgAbbrevOutputStream.flushAndSendRaw(MsgAbbrevOutputStream.ja
    va:155)
    at
    weblogic.rjvm.MsgAbbrevOutputStream.flushAndSend(MsgAbbrevOutputStream.java:
    163)
    at
    weblogic.rjvm.MsgAbbrevOutputStream.sendRecv(MsgAbbrevOutputStream.java:186)
    at
    weblogic.rmi.internal.BasicOutgoingRequest.sendRecv(BasicOutgoingRequest.jav
    a:23)
    at
    weblogic.rmi.extensions.AbstractRequest.sendReceive(AbstractRequest.java:73)
    at
    com.unitor.message.server.UserInformationServiceBeanHomeImpl_WLStub.create(U
    serInformationServiceBeanHomeImpl_WLStub.java:151)
    at
    com.unitor.message.server.UserInformationServiceBeanHomeImpl_ServiceStub.cre
    ate(UserInformationServiceBeanHomeImpl_ServiceStub.java:121)
    at
    com.unitor.message.beans.gui.MessageLogic.getUserInformationService(MessageL
    ogic.java:230)
    at
    com.unitor.message.beans.gui.MessageLogic.addUserInformation(MessageLogic.ja
    va:186)
    at com.unitor.message.beans.gui.MessageLogic.<init>(MessageLogic.java:104)
    at
    com.unitor.message.beans.gui.MessageApplication.internalStartApplication(Mes
    sageApplication.java:64)
    at
    com.unitor.ifs.util.gui.UnitorApplication.startApplication(UnitorApplication
    .java:167)
    at
    com.unitor.ifs.util.gui.DesktopApplication$ApplicationLoader.run(DesktopAppl
    ication.java:676)
    at
    com.unitor.ifs.util.gui.DesktopApplication.startApplication(DesktopApplicati
    on.java:303)
    at
    com.unitor.ifs.util.gui.UnitorDesktopAppStarter$SwingEventCall.run(UnitorDes
    ktopAppStarter.java:294)
    at java.awt.event.InvocationEvent.dispatch(Unknown Source)
    at java.awt.EventQueue.dispatchEvent(Unknown Source)
    at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
    at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
    at java.awt.EventDispatchThread.run(Unknown Source)
    The strange thing is that I can connect to my server if I run the client on
    NT4 !!!
    I solved the problem by modifying my local java.policy file with the
    following settings:
    // Test with HTTP tunnelling. 18.10.2001
    [email protected]
    permission java.util.PropertyPermission "proxyHost", "read";
    permission java.util.PropertyPermission "proxyPort", "read";
    permission java.util.PropertyPermission "http.proxyHost", "read";
    permission java.util.PropertyPermission "http.proxyPort", "read";
    permission java.net.SocketPermission "*","connect,resolve";
    // Test with HTTP tunnelling. 18.10.2001
    [email protected]
    Have someone else experienced the same or similar problems ?
    How can I make sure that the client gets access to read the properties
    http.proxyHost, http.proxyPort, proxyHost and proxyPort without telling the
    users of the client application to modify their java.policy files ?
    Any leads will be greatly appreciated !
    Regards
    Sten Richard

    This is in reply to the first post. I don't know what happened after.
    Caused by: java.security.AccessControlException: access denied (java.util.PropertyPermission sun.arch.data.model read)
         at java.security.AccessControlContext.checkPermission(Unknown Source)
         at java.security.AccessController.checkPermission(Unknown Source)
         at java.lang.SecurityManager.checkPermission(Unknown Source)
         at java.lang.SecurityManager.checkPropertyAccess(Unknown Source)
         at java.lang.System.getProperty(Unknown Source)
         at org.eclipse.swt.internal.Library.loadLibrary(Library.java:167)
         at org.eclipse.swt.internal.Library.loadLibrary(Library.java:151)
         at org.eclipse.swt.internal.C.<clinit>(C.java:21)
    If you read the above trace from bottom to top, it shows none of you classes, only classes from that Eclipse library, which seems to loadLibrary() a native DLL. In order to do this, it needs to call System.getProperty( "sun.arch.data.model" ). This call is not allowed from un unsigned applet. So I guess you need to sign the applet and this problem will go away. Many other problems may follow. Just read very very carefully all the related documentation, which I did not.

  • Does anyone have a good server.xml file for tomcat?

    I am trying to link apache and tomcat on a RedHat 9 computer. I previously posted a message stating that I could not get tomcat to "automagically" make the configuration files (mod_jk.conf-auto) that all the manuals promised it would. However, I found that my problem was the lack of an ApacheConfig tag in the server.xml file. After looking at my server.xml file, I found that it was much more simplistic than I would hoped = it did not have enough comments or commented out options. It had none of the directives that the manuals said it included by default.
    In short, does anyone who has apache and tomcat linked have a server.xml file that I can look at so that I can figure out what I must add to mine to get tomcat working with apache? I would greatly appreciate it if you could copy and paste the whole thing here.
    Thank you very much in advance.
    Edward S. Rice

    Hi!
    I am having the Apache-Tomcat4.0 version installed on a Win2000 machine. I am pasting here my server.xml. Hope it will be useful to you. I even didnot do much modifications to my server.xml except for adding a context.
    Please come back if problem persists.
    <!-- Example Server Configuration File -->
    <!-- Note that component elements are nested corresponding to their
    parent-child relationships with each other -->
    <!-- A "Server" is a singleton element that represents the entire JVM,
    which may contain one or more "Service" instances. The Server
    listens for a shutdown command on the indicated port.
    Note: A "Server" is not itself a "Container", so you may not
    define subcomponents such as "Valves" or "Loggers" at this level.
    -->
    <Server port="8005" shutdown="SHUTDOWN" debug="0">
    <!-- A "Service" is a collection of one or more "Connectors" that share
    a single "Container" (and therefore the web applications visible
    within that Container). Normally, that Container is an "Engine",
    but this is not required.
    Note: A "Service" is not itself a "Container", so you may not
    define subcomponents such as "Valves" or "Loggers" at this level.
    -->
    <!-- Define the Tomcat Stand-Alone Service -->
    <Service name="Tomcat-Standalone">
    <!-- A "Connector" represents an endpoint by which requests are received
    and responses are returned. Each Connector passes requests on to the
    associated "Container" (normally an Engine) for processing.
    By default, a non-SSL HTTP/1.1 Connector is established on port 8080.
    You can also enable an SSL HTTP/1.1 Connector on port 8443 by
    following the instructions below and uncommenting the second Connector
    entry. SSL support requires the following steps (see the SSL Config
    HOWTO in the Tomcat 4.0 documentation bundle for more detailed
    instructions):
    * Download and install JSSE 1.0.2 or later, and put the JAR files
    into "$JAVA_HOME/jre/lib/ext".
    * Execute:
    %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows)
    $JAVA_HOME/bin/keytool -genkey -alias tomcat -keyalg RSA (Unix)
    with a password value of "changeit" for both the certificate and
    the keystore itself.
    By default, DNS lookups are enabled when a web application calls
    request.getRemoteHost(). This can have an adverse impact on
    performance, so you can disable it by setting the
    "enableLookups" attribute to "false". When DNS lookups are disabled,
    request.getRemoteHost() will return the String version of the
    IP address of the remote client.
    -->
    <!-- Define a non-SSL HTTP/1.1 Connector on port 8080 -->
    <Connector className="org.apache.catalina.connector.http.HttpConnector"
    port="8080" minProcessors="5" maxProcessors="75"
    enableLookups="true" redirectPort="8443"
    acceptCount="10" debug="0" connectionTimeout="60000"/>
    <!-- Note : To disable connection timeouts, set connectionTimeout value
    to -1 -->
    <!-- Define an SSL HTTP/1.1 Connector on port 8443 -->
    <!--
    <Connector className="org.apache.catalina.connector.http.HttpConnector"
    port="8443" minProcessors="5" maxProcessors="75"
    enableLookups="true"
         acceptCount="10" debug="0" scheme="https" secure="true">
    <Factory className="org.apache.catalina.net.SSLServerSocketFactory"
    clientAuth="false" protocol="TLS"/>
    </Connector>
    -->
    <!-- Define an AJP 1.3 Connector on port 8009 -->
    <!--
    <Connector className="org.apache.ajp.tomcat4.Ajp13Connector"
    port="8009" minProcessors="5" maxProcessors="75"
    acceptCount="10" debug="0"/>
    -->
    <!-- Define a Proxied HTTP/1.1 Connector on port 8081 -->
    <!-- See proxy documentation for more information about using this. -->
    <!--
    <Connector className="org.apache.catalina.connector.http.HttpConnector"
    port="8081" minProcessors="5" maxProcessors="75"
    enableLookups="true"
    acceptCount="10" debug="0" connectionTimeout="60000"
    proxyPort="80"/>
    -->
    <!-- Define a non-SSL HTTP/1.0 Test Connector on port 8082 -->
    <!--
    <Connector className="org.apache.catalina.connector.http10.HttpConnector"
    port="8082" minProcessors="5" maxProcessors="75"
    enableLookups="true" redirectPort="8443"
    acceptCount="10" debug="0"/>
    -->
    <!-- An Engine represents the entry point (within Catalina) that processes
    every request. The Engine implementation for Tomcat stand alone
    analyzes the HTTP headers included with the request, and passes them
    on to the appropriate Host (virtual host). -->
    <!-- Define the top level container in our container hierarchy -->
    <Engine name="Standalone" defaultHost="localhost" debug="0">
    <!-- The request dumper valve dumps useful debugging information about
    the request headers and cookies that were received, and the response
    headers and cookies that were sent, for all requests received by
    this instance of Tomcat. If you care only about requests to a
    particular virtual host, or a particular application, nest this
    element inside the corresponding <Host> or <Context> entry instead.
    For a similar mechanism that is portable to all Servlet 2.3
    containers, check out the "RequestDumperFilter" Filter in the
    example application (the source for this filter may be found in
    "$CATALINA_HOME/webapps/examples/WEB-INF/classes/filters").
    Request dumping is disabled by default. Uncomment the following
    element to enable it. -->
    <!--
    <Valve className="org.apache.catalina.valves.RequestDumperValve"/>
    -->
    <!-- Global logger unless overridden at lower levels -->
    <Logger className="org.apache.catalina.logger.FileLogger"
    prefix="catalina_log." suffix=".txt"
    timestamp="true"/>
    <!-- Because this Realm is here, an instance will be shared globally -->
    <Realm className="org.apache.catalina.realm.MemoryRealm" />
    <!-- Replace the above Realm with one of the following to get a Realm
    stored in a database and accessed via JDBC -->
    <!--
    <Realm className="org.apache.catalina.realm.JDBCRealm" debug="99"
    driverName="org.gjt.mm.mysql.Driver"
    connectionURL="jdbc:mysql://localhost/authority?user=test;password=test"
    userTable="users" userNameCol="user_name" userCredCol="user_pass"
    userRoleTable="user_roles" roleNameCol="role_name" />
    -->
    <!--
    <Realm className="org.apache.catalina.realm.JDBCRealm" debug="99"
    driverName="oracle.jdbc.driver.OracleDriver"
    connectionURL="jdbc:oracle:thin:@ntserver:1521:ORCL?user=scott;password=tiger"
    userTable="users" userNameCol="user_name" userCredCol="user_pass"
    userRoleTable="user_roles" roleNameCol="role_name" />
    -->
    <!--
    <Realm className="org.apache.catalina.realm.JDBCRealm" debug="99"
    driverName="sun.jdbc.odbc.JdbcOdbcDriver"
    connectionURL="jdbc:odbc:CATALINA"
    userTable="users" userNameCol="user_name" userCredCol="user_pass"
    userRoleTable="user_roles" roleNameCol="role_name" />
    -->
    <!-- Define the default virtual host -->
    <Host name="localhost" debug="0" appBase="webapps" unpackWARs="true">
    <!-- Normally, users must authenticate themselves to each web app
    individually. Uncomment the following entry if you would like
    a user to be authenticated the first time they encounter a
    resource protected by a security constraint, and then have that
    user identity maintained across all web applications contained
    in this virtual host. -->
    <!--
    <Valve className="org.apache.catalina.authenticator.SingleSignOn"
    debug="0"/>
    -->
    <!-- Access log processes all requests for this virtual host. By
    default, log files are created in the "logs" directory relative to
    $CATALINA_HOME. If you wish, you can specify a different
    directory with the "directory" attribute. Specify either a relative
    (to $CATALINA_HOME) or absolute path to the desired directory.
    -->
    <Valve className="org.apache.catalina.valves.AccessLogValve"
    directory="logs" prefix="localhost_access_log." suffix=".txt"
    pattern="common"/>
    <!-- Logger shared by all Contexts related to this virtual host. By
    default (when using FileLogger), log files are created in the "logs"
    directory relative to $CATALINA_HOME. If you wish, you can specify
    a different directory with the "directory" attribute. Specify either a
    relative (to $CATALINA_HOME) or absolute path to the desired
    directory.-->
    <Logger className="org.apache.catalina.logger.FileLogger"
    directory="logs" prefix="localhost_log." suffix=".txt"
         timestamp="true"/>
    <!-- Define properties for each web application. This is only needed
    if you want to set non-default properties, or have web application
    document roots in places other than the virtual host's appBase
    directory. -->
    <!-- Tomcat Root Context -->
    <!--
    <Context path="" docBase="ROOT" debug="0"/>
    -->
              <Context path="/vijay" docBase="D:\Java\servlets" debug="0"/>
    <!-- Tomcat Manager Context -->
    <Context path="/manager" docBase="manager"
    debug="0" privileged="true"/>
    <!-- Tomcat Examples Context -->
    <Context path="/examples" docBase="examples" debug="0"
    reloadable="true">
    <Logger className="org.apache.catalina.logger.FileLogger"
    prefix="localhost_examples_log." suffix=".txt"
         timestamp="true"/>
    <Ejb name="ejb/EmplRecord" type="Entity"
    home="com.wombat.empl.EmployeeRecordHome"
    remote="com.wombat.empl.EmployeeRecord"/>
    <!-- PersistentManager: Uncomment the section below to test Persistent
              Sessions.
    saveOnRestart: If true, all active sessions will be saved
    to the Store when Catalina is shutdown, regardless of
    other settings. All Sessions found in the Store will be
    loaded on startup. Sessions past their expiration are
    ignored in both cases.
    maxActiveSessions: If 0 or greater, having too many active
    sessions will result in some being swapped out. minIdleSwap
    limits this. -1 means unlimited sessions are allowed.
    0 means sessions will almost always be swapped out after
    use - this will be noticeably slow for your users.
    minIdleSwap: Sessions must be idle for at least this long
    (in seconds) before they will be swapped out due to
    maxActiveSessions. This avoids thrashing when the site is
    highly active. -1 or 0 means there is no minimum - sessions
    can be swapped out at any time.
    maxIdleSwap: Sessions will be swapped out if idle for this
    long (in seconds). If minIdleSwap is higher, then it will
    override this. This isn't exact: it is checked periodically.
    -1 means sessions won't be swapped out for this reason,
    although they may be swapped out for maxActiveSessions.
    If set to >= 0, guarantees that all sessions found in the
    Store will be loaded on startup.
    maxIdleBackup: Sessions will be backed up (saved to the Store,
    but left in active memory) if idle for this long (in seconds),
    and all sessions found in the Store will be loaded on startup.
    If set to -1 sessions will not be backed up, 0 means they
    should be backed up shortly after being used.
    To clear sessions from the Store, set maxActiveSessions, maxIdleSwap,
    and minIdleBackup all to -1, saveOnRestart to false, then restart
    Catalina.
    -->
              <!--
    <Manager className="org.apache.catalina.session.PersistentManager"
    debug="0"
    saveOnRestart="true"
    maxActiveSessions="-1"
    minIdleSwap="-1"
    maxIdleSwap="-1"
    maxIdleBackup="-1">
    <Store className="org.apache.catalina.session.FileStore"/>
    </Manager>
              -->
    <Environment name="maxExemptions" type="java.lang.Integer"
    value="15"/>
    <Parameter name="context.param.name" value="context.param.value"
    override="false"/>
    <Resource name="jdbc/EmployeeAppDb" auth="SERVLET"
    type="javax.sql.DataSource"/>
    <ResourceParams name="jdbc/EmployeeAppDb">
    <parameter><name>user</name><value>sa</value></parameter>
    <parameter><name>password</name><value></value></parameter>
    <parameter><name>driverClassName</name>
    <value>org.hsql.jdbcDriver</value></parameter>
    <parameter><name>driverName</name>
    <value>jdbc:HypersonicSQL:database</value></parameter>
    </ResourceParams>
    <Resource name="mail/Session" auth="Container"
    type="javax.mail.Session"/>
    <ResourceParams name="mail/Session">
    <parameter>
    <name>mail.smtp.host</name>
    <value>localhost</value>
    </parameter>
    </ResourceParams>
    </Context>
    </Host>
    </Engine>
    </Service>
    <!-- The MOD_WEBAPP connector is used to connect Apache 1.3 with Tomcat 4.0
    as its servlet container. Please read the README.txt file coming with
    the WebApp Module distribution on how to build it.
    (Or check out the "jakarta-tomcat-connectors/webapp" CVS repository)
    To configure the Apache side, you must ensure that you have the
    "ServerName" and "Port" directives defined in "httpd.conf". Then,
    lines like these to the bottom of your "httpd.conf" file:
    LoadModule webapp_module libexec/mod_webapp.so
    WebAppConnection warpConnection warp localhost:8008
    WebAppDeploy examples warpConnection /examples/
    The next time you restart Apache (after restarting Tomcat, if needed)
    the connection will be established, and all applications you make
    visible via "WebAppDeploy" directives can be accessed through Apache.
    -->
    <!-- Define an Apache-Connector Service -->
    <Service name="Tomcat-Apache">
    <Connector className="org.apache.catalina.connector.warp.WarpConnector"
    port="8008" minProcessors="5" maxProcessors="75"
    enableLookups="true"
    acceptCount="10" debug="0"/>
    <!-- Replace "localhost" with what your Apache "ServerName" is set to -->
    <Engine className="org.apache.catalina.connector.warp.WarpEngine"
    name="Apache" debug="0" appBase="webapps">
    <!-- Global logger unless overridden at lower levels -->
    <Logger className="org.apache.catalina.logger.FileLogger"
    prefix="apache_log." suffix=".txt"
    timestamp="true"/>
    <!-- Because this Realm is here, an instance will be shared globally -->
    <Realm className="org.apache.catalina.realm.MemoryRealm" />
    </Engine>
    </Service>
    </Server>

  • "access denied" message on tomcat

    i have downloaded jakarta tomcat, set classpaths etc,
    set JAVA_HOME environment and CATALLINA_HOME environment.
    Catalina connects, but the J2sdk1.4.1_01 reads back in MSDOS
    "access denied".
    I have a personal firewall "Zone Alarm" and do not think it is
    preventing the server from running because i usually get an alert.
    Please advise if there is a work around.
    thanks in advance

    Ok. If anyone is interested, do not attempt to set the
    CATALINA_HOME environment since it appears to default to the
    root directory "." or searches ".." in windows 98. Attempting
    to do it manually by for example, setting the catalina home
    environment in autoexec.bat, will result in you getting
    a bad file command and an "access denied" error message when
    trying to connect to the jdk.

  • Server Error  403 - Forbidden: Access is denied. You do not have permission to view this directory or page using the credentials that you supplied.

    Hi,
    I`d like to get your advice on Server Error 403 - Forbidden: Access is denied. I use to visit a webpage with no issues so far but now i getting this error each time i`m trying to get into. Any ideas in how to solve it? A step to step process will be highly appreciated.
    Thanks.
    PS, I`m using the latest safari 8.0.3 and OS X 10.10.2.

    It's an error message from the web server, not from Safari. There's a slight chance that you might be able to clear it as follows.
    From the Safari menu bar, select
              Safari ▹ Preferences... ▹ Privacy ▹ Remove All Website Data...
    and confirm. Test.

  • "Access denied" when opening report on RAS Server

    I'm sure I'm doing something wrong, but I've only been able to open a report using the rassdk protocol from the server where my java code is running.    This is fine, but I was hoping for efficiency sake that I could have reports reside on the RAS server itself.
    My ras server definitely has a Crystal report called EBTest.rpt in the c:\temp directory.  I run this code...
    ReportClientDocument rcd = new ReportClientDocument();
    rcd.setReportAppServer(ReportConstants.RAS_HOST);
    rcd.open("c:\\temp\\EBTest.rpt", OpenReportOptions._openAsReadOnly);
    rcd.close();
    According to the JavaDoc, this should work, but I get this error ...
    Caused by: com.crystaldecisions.sdk.occa.report.lib.ReportSDKServerException: Access denied. Please check directory setting for files you can access.---- Error code:-2147467259 Error code name:failed
         at com.crystaldecisions.sdk.occa.report.lib.ReportSDKServerException.throwReportSDKServerException(Unknown Source)
         at com.crystaldecisions.proxy.remoteagent.s.a(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.if(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.if(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.a(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ClientDocument.open(Unknown Source)
    Am I missing something trivial?  
    Thanks,
    Eric

    Now that I've got it working, I expected that the RAS-local approach would be much faster than the RAS-remote, but I didn't find that to be the case in a quick test that I did.  Is this what you'd expect?  Or is there a different part of the ReportClientDocument interaction that would be more efficient. 
    From what I've seen, the ReportClientDocument construct and open() are one of the expensive aspects of the report rendering.
    Enclosed are the results from a test I did:
    --PERF--20 iteration test for 'Test local report initialization'
    --PERF--WARMED UP in 3359 ms
    --PERF--,Iterations          ,Total Time (mS)     ,Avg(ms)/Iteration   ,Transactions/sec   
    --PERF--,20                  ,35515               ,1775.75             ,0.5631423          
    --PERF--20 iteration test for 'Test remote report initialization'
    --PERF--WARMED UP in 1828 ms
    --PERF--,Iterations          ,Total Time (mS)     ,Avg(ms)/Iteration   ,Transactions/sec   
    --PERF--,20                  ,37109               ,1855.45             ,0.5389528          
    And here's the bulk of the code that generated those results...
    int numIterations = 20;
    PerformanceUtils.runPerformanceTest("Test local report initialization", numIterations, new Command(){
         public void execute() {
              try{
                   ReportClientDocument rcd = new ReportClientDocument();
                   rcd.setReportAppServer(ReportConstants.RAS_HOST);
                   rcd.open("D:\\Program Files\\Business Objects\\BusinessObjects Enterprise 12.0\\Samples\\EN\\Reports\\triCalendarPeriod___-___Find___-___Months.rpt", OpenReportOptions._openAsReadOnly);
                   rcd.close();
              }catch(Exception e){
                   throw new RuntimeException(e);
    PerformanceUtils.runPerformanceTest("Test remote report initialization", numIterations, new Command(){
         public void execute() {
              try{
                   ReportClientDocument rcd = new ReportClientDocument();
                   rcd.setReportAppServer(ReportConstants.RAS_HOST);
                   rcd.open("rassdk://./test/data/crystal/triCalendarPeriod___-___Find___-___Months.rpt", OpenReportOptions._openAsReadOnly);
                   rcd.close();
              }catch(Exception e){
                   throw new RuntimeException(e);

  • Access Denied to report file on Windows Server 2003 Enterprise

    Hi,
    I have a deployment problem for which I am out of ideas. I have an ASP.NET web site deployed on a server running Windows Server 2003 R2, sp2.  It makes extensive use of Crystal Reports, including both displaying them and e-mailing them to specified recipients as PDF files. It all works great.
    Now I need to port the web site to a different server, running Windows Server 2003 Enterprise, sp1. The reports display fine as long as I am not trying to convert it to PDF for e-mailng. When it gets to the following line in my code:
    MemoryStream memStream = (MemoryStream)rptDoc.ExportToStream(ExportFormatType.PortableDocFormat);
    It reports the following error:
    Access denied.Error in File JobDetails {DC64A5D3-9DD7-4E4C-90F5-A08731409B29}.rpt:
    Access to report file denied. Another program may be using it.
    I finally got it to work by granting Modify permission to Everyone for the c:\Windows\Temp folder. Obviously this is not a good practice.  Granting Full Control  to the IUSR_servername account did not solve the problem on Windows Server Enterprise, although it did the trick on R2.
    So the question is, which account needs which permission to the Temp folder to enable the PDF to get written?
    Thanks.
    Dan

    What ever account the app is running under will need read / write permissions on the temp folder. Your working server should be a good place to look to see how the premissions were set there. The same will apply to any other server(?).
    Ludek
    Follow us on Twitter http://twitter.com/SAPCRNetSup
    Got Enhancement ideas? Try the [SAP Idea Place|https://ideas.sap.com/community/products_and_solutions/crystalreports]

Maybe you are looking for