Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

启动脚本无法加载到log,不知道是哪里的错误,请帮忙看下 #26

Open
xiaocainia opened this issue Feb 19, 2019 · 12 comments

Comments

@xiaocainia
Copy link

初学jlogstash,启动时遇到一些问题,请帮忙看下
操作时上传打成的jar包jlogstash-1.0.0.jar到lib目录下,编写test.yml文件,执行命令报错:
Error: Could not find or load main class .test.jlogstash.lib.logs
test是目录名

@yangsishu
Copy link
Contributor

你的目录结构截个图看下

@yangsishu
Copy link
Contributor

你在启动脚本 打印 basedir 这个值是什么

@yangsishu
Copy link
Contributor

就是主类找不到,所以得看下包路径是不是对的,启动脚本没有对不同的linux版本做适配

@xiaocainia
Copy link
Author

/gsg/jlogstash,是当前bin的父目录

@yangsishu
Copy link
Contributor

就是主类找不到,所以得看下包路径是不是对的,启动脚本没有对不同的linux版本做适配

@xiaocainia
Copy link
Author

应该是可以找到主类的,之前没有上传jlogstash-1.0.0.jar的时候报的错误是找不到主类Main方法,上传后找不到的是这个log,不知道哪里的错误

@xiaocainia
Copy link
Author

能否给我提供一下jlogstash.jar,是否是我打的包有问题啊

@yangsishu
Copy link
Contributor

logs 目录默认是${user.dir}/logs,加 -l 参数可以配置的

@xiaocainia
Copy link
Author

Error: Could not find or load main class .gsg.jlogstash.lib.README.MD
我重新打开又运行了一次,变成了这个错误,能否帮忙再看下

@yangsishu
Copy link
Contributor

你把lib目录下面的除了jar包其他的都删掉

@xiaocainia
Copy link
Author

能否提供一个完整的测试的yml文件配置

@yangsishu
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants