title: Why am I getting a permission denied with JDBC and Netbeans?
body: <p>We are three developers all working with Netbeans and Java.  One developer can access the remote DB2 server just fine (using the same code).  The other two (which includes me) can not.</p>
  
  <p>Here is the context.xml file:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;Context path="/app_web"&gt;
      &lt;Resource name="jdbc/admin"
                auth="Container"
                type="javax.sql.DataSource"
                maxActive="500"
                initialSize="10"
                maxIdle="50"
                maxWait="10000"
                username="theusername"
                password="xxxxxxxxx"
                driverClassName="com.ibm.as400.access.AS400JDBCDriver"
                removeAbandoned="true"
                removeAbandonedTimeout="60"
                logAbandoned="true"
                url="jdbc:as400://192.168.1.1;prompt=false;naming=system;prompt=false;naming=system;libraries=*libl;date format=iso;time format=iso"
                /&gt;
  </code></pre>
  
  <p>Here are the exceptions we are getting: </p>
  
  <pre><code>org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (The application requester cannot establish the connection. (Permission denied: connect))
  Caused by: java.sql.SQLException: The application requester cannot establish the connection. (Permission denied: connect)
      at com.ibm.as400.access.JDError.throwSQLException(JDError.java:528)
  WARNING: Failed to register in JMX: javax.naming.NamingException: Cannot create PoolableConnectionFactory (The application requester cannot establish the connection. (Permission denied: connect))
  WARNING: Unexpected exception resolving reference
  org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (The application requester cannot establish the connection. (Permission denied: connect))
  Caused by: java.sql.SQLException: The application requester cannot establish the connection. (Permission denied: connect)
      at com.ibm.as400.access.JDError.throwSQLException(JDError.java:528)
  WARNING: Failed to register in JMX: javax.naming.NamingException: Cannot create PoolableConnectionFactory (The application requester cannot establish the connection. (Permission denied: connect))
  </code></pre>
  
  <p>I have put the <code>jt400.jar</code> file in the <code>C:\Program Files\Apache Software Foundation\apache-tomcat-6.0.35\lib</code> folder, put it in the <code>...\web\WEB-INF\lib</code> folder, etc.  Nothing seems to work.</p>