linux 之 nested exception is java.awt.AWTError: Can’t connect to X11 window server using ‘localhost:10.0’ as the value of the DISPLAY variable.


linux 环境下执行kettle报

nested exception is java.awt.AWTError: Can’t connect to X11 window server using ‘localhost:10.0’ as the value of the DISPLAY variable.

 

1.原因:因为用到了图形处理,java程序会去寻找linux上的图形界面是否启动
2.解决:不让java寻找linux图形界面即可,在java 启动时加选项java -Djava.awt.headless=true 
3.实现:在执行的脚本前加入 export JAVA_OPTS=-Djava.awt.headless=true,即可

 

 

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM