log4j:ERROR setFile(null,true)调用失败.java.io.FileNotFoundException: [英] log4j:ERROR setFile(null,true) call failed.java.io.FileNotFoundException:

查看:155
本文介绍了log4j:ERROR setFile(null,true)调用失败.java.io.FileNotFoundException:的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在编译应用程序时出现以下错误

I'm getting the below error while compiling the application

log4j:ERROR setFile(null,true) call failed.java.io.FileNotFoundException:\gel\ms\ex\ms.log (The system cannot find the path specified)

下面是我的log4j配置文件:

Below is my log4j config file:

#root log level
log4j.rootCategory=debug, R
log4j.logger.java.sql=DEBUG
log4j.logger.com.ibatis=DEBUG

# First type of log, output to file
log4j.appender.R=org.apache.log4j.RollingFileAppender
log4j.appender.R.File=/gel/ms/ex/ms.log
log4j.appender.R.MaxFileSize=5000KB
log4j.appender.R.MaxBackupIndex=3
log4j.appender.R.layout=org.apache.log4j.PatternLayout
log4j.appender.R.layout.ConversionPattern=%d [%40c] %5p - %m%n

我的项目文件夹层次化

MS(项目名称)

  1. Java资源

  1. Java Resource

WebContext

WebContext

2.a -META-INF

2.a -META-INF

2.b -WEB-INF

2.b -WEB-INF

请告知.谢谢

推荐答案

要快速解决,请设置绝对路径.

For a quick solution, set the absolute path.

这篇关于log4j:ERROR setFile(null,true)调用失败.java.io.FileNotFoundException:的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆