You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Jenkins无法正常启动运行,按官方指南操作仍遇多类报错

Jenkins启动失败&无法安装插件问题排查解决

Hey there, let's work through your Jenkins issues together—most of those warnings are harmless, but the SSL certificate error is the main reason you can't get past the setup wizard. Let's break this down:

核心问题:SSL握手失败(无法连接更新站点)

This is the real blocker preventing you from installing plugins. The error PKIX path building failed means your Java runtime doesn't trust the SSL certificate of Jenkins' official update site. Here are two ways to fix it:

方法1:手动导入证书到Java信任库(推荐,适合长期使用)

  1. 访问 Jenkins 更新站点,在浏览器里导出该站点的SSL证书(保存为.crt格式)
  2. 打开终端,用keytool命令把证书导入到Java的系统信任库:
    keytool -import -alias jenkins-updates -file /path/to/your/jenkins-cert.crt -keystore $JAVA_HOME/jre/lib/security/cacerts
    
    • 默认信任库密码是 changeit(如果你的Java环境修改过密码,用对应的密码)
  3. 重启Jenkins,重新运行启动命令:java -jar jenkins.war --httpPort=8080

方法2:临时跳过SSL验证(适合测试/快速入门)

如果你只是想快速完成入门向导,可以启动Jenkins时添加参数跳过证书检查:

java -Dhudson.model.DownloadService.noSignatureCheck=true -jar jenkins.war --httpPort=8080

⚠️ 注意:这个方法会关闭插件签名验证,不建议在生产环境使用。


其他警告的解释与处理(不影响启动)

Let's go through those other warnings so you don't worry about them:

1. Winstone临时文件删除失败

Jan 27, 2018 11:58:13 PM Main deleteWinstoneTempContents WARNING: Failed to delete the temporary Winstone file /var/folders/mg/r5m253mx4hz75sk1f_gn5xg80000gn/T/winstone/jenkins.war

  • 原因:Jenkins启动时尝试清理旧的临时文件,但这个文件已经被删除了
  • 处理:完全忽略,不影响任何功能

2. Jetty空上下文路径警告

Jan 27, 2018 11:58:16 PM org.eclipse.jetty.server.handler.ContextHandler setContextPath WARNING: Empty contextPath

  • 原因:这是Jenkins默认的Jetty服务器配置,上下文路径为空意味着Jenkins直接运行在http://localhost:8080/根路径下
  • 处理:正常现象,无需修改

3. 过时的Remoting协议警告

Jan 27, 2018 11:58:34 PM jenkins.slaves.DeprecatedAgentProtocolMonitor initializerCheck WARNING: This Jenkins instance uses deprecated Remoting protocols: CLI-connect,CLI2-connect,JNLP-connect,JNLP2-connect

  • 原因:Jenkins使用了旧版本的代理通信协议,可能影响稳定性(但不影响入门)
  • 处理:等你成功启动Jenkins并进入后台后,依次点击:
    Manage Jenkins → Global Security → Agent protocols
    取消勾选所有带(Deprecated)标记的协议即可

先解决SSL证书问题,你应该就能顺利完成Jenkins的入门向导和插件安装了。

内容的提问来源于stack exchange,提问作者O'Malley

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.15 04:51:34