随笔 - 34, 文章 - 1, 评论 - 2, 引用 - 0
数据加载中……

WebSphere访问操作系统中文件 权限问题

参考:
http://publib.boulder.ibm.com/infocenter/wasinfo/v6r0/index.jsp?topic=/com.ibm.websphere.express.doc/info/exp/ae/rsec_serverpolicy.html

错误信息(在Systemout.Log文件中)
        java.security.AccessControlException: Access denied (java.io.FilePermission  
 解决方法
修改 server.policy 文件,在 install_root/properties/server.policy 中找到此文件。此文件包含这些缺省许可权:
// Allow to use ibm jdk extensions
grant codeBase "file:${was.install.root}/java/ext/-" {
permission java.security.AllPermission;
};
// Allow to use ibm tools
grant codeBase "file:${was.install.root}/java/tools/ibmtools.jar" {
permission java.security.AllPermission;
};
// Allow to use sun tools
grant codeBase "file:/QIBM/ProdData/Java400/jdk14/lib/tools.jar" {
permission java.security.AllPermission;
};
// Allow to use sun tools (V5R2M0 codebase)
grant codeBase "file:/QIBM/ProdData/OS400/Java400/jdk/lib/tools.jar" {
permission java.security.AllPermission;
};
// WebSphere system classes
grant codeBase "file:${was.install.root}/plugins/-" {
permission java.security.AllPermission;
};
grant codeBase "file:${was.install.root}/lib/-" {
permission java.security.AllPermission;
};
grant codeBase "file:${was.install.root}/classes/-" {
permission java.security.AllPermission;
};
// Allow the WebSphere deploy tool all permissions
grant codeBase "file:${was.install.root}/deploytool/-" {
permission java.security.AllPermission;
};
// Allow the WebSphere deploy tool all permissions
grant codeBase "file:${was.install.root}/optionalLibraries/-" {
permission java.security.AllPermission;
};
// Allow Channel Framework classes all permission
grant codeBase "file:${was.install.root}/installedChannels/-" {
permission java.security.AllPermission;
};
grant codeBase "file:${user.install.root}/lib/-" {
permission java.security.AllPermission;
};
grant codeBase "file:${user.install.root}/classes/-" {
permission java.security.AllPermission;
};

如果节点上有一些服务器程序需要许可权,而这些许可权在 server.policy 文件和 server.policy 文件中未定义为缺省值,那么更新 server.policy 文件。缺少许可权将创建 java.security.AccessControlException 异常。缺少的许可权在异常数据中列示。


然后重新启动服务器

posted on 2009-12-09 17:04 河马虎 阅读(1426) 评论(0)  编辑  收藏 所属分类: WebSphere


只有注册用户登录后才能发表评论。


网站导航: