(Windows/Linux) Sprint-Boot Tomcat: An incompatible version [1.x.x] of the Apache Tomcat Native ...

情景:
启动spring-boot项目,报错 An incompatible version [1.2.12] of the Apache Tomcat Native library is installed, while Tomcat requires [1.2.14]。
原因:
spring-boot内置tomcat要求的native库版本和本地native库版本不一致,需要升级。
解决办法:

  1. Windows:
  1. Linux:

sudo apt-get autoremove libtcnative-1 #删除安装的库
cd native
./configure --with-apr=/usr/bin/apr-1-config
sudo make
sudo make install

  1. 重新运行spring-boot项目一般就不再报错误了。
    完毕。
最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

友情链接更多精彩内容