IronPDF 故障排除 部署Chrome依赖项时出错 解决 IronPDF 中的 Chrome 浏览器依赖性问题。 Curtis Chau 已更新:八月 20, 2025 下载 IronPDF NuGet 下载 DLL 下载 Windows 安装程序 免费试用 法学硕士副本 法学硕士副本 将页面复制为 Markdown 格式,用于 LLMs 在 ChatGPT 中打开 向 ChatGPT 咨询此页面 在双子座打开 向 Gemini 询问此页面 在双子座打开 向 Gemini 询问此页面 打开困惑 向 Perplexity 询问有关此页面的信息 分享 在 Facebook 上分享 分享到 X(Twitter) 在 LinkedIn 上分享 复制链接 电子邮件文章 This article was translated from English: Does it need improvement? Translated View the article in English Google Chromium HTML渲染器是IronPDF"Html转PDF"渲染过程的重要组成部分。 这个渲染器的必要二进制文件应可在IronPDF NuGet包中找到。 项目文件夹中缺少此二进制文件将抛出以下错误: Unhandled exception. IronSoftware.Exceptions.IronSoftwareDeploymentException: Error while deploying IronPdf Chrome renderer: 'Unable to locate 'IronInterop'. 如果IronPDF无法自动部署Chrome依赖,可能需要通过NuGet手动添加到项目中。 可以添加多种依赖: IronPdf.Native.Chrome.Windows IronPdf.Native.Chrome.Linux IronPdf.Native.Chrome.MacOS 请注意在 IronPdf 的后续版本中,如果项目文件夹中没有所需的二进制文件,则会根据运行时使用的操作系统自动从 NuGet 源中下载。 只要项目连接到互联网,并拥有对项目文件夹的读取、写入和执行权限,翻译就会成功。 在Windows上,确保目标操作系统安装了Visual C++ Runtimes是个好主意。 许多现代应用程序无法在没有这个重要的操作系统组件的情况下运行。 我们还有Linux和Docker的兼容性指南。 Linux 确保使用正确的Docker文件。 使用IronPdf.Linux NuGet包而不是IronPdf。 设置Chrome渲染的GPU模式为禁用: IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled; IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled; IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled $vbLabelText $csharpLabel 禁用Linux和Docker依赖的自动配置: csharp Installation.LinuxAndDockerDependenciesAutoConfig = false; csharp Installation.LinuxAndDockerDependenciesAutoConfig = false; csharp Installation.LinuxAndDockerDependenciesAutoConfig = False $vbLabelText $csharpLabel MacOS 检查.NET运行时设置为正确的架构 - x64或arm64。 如果这不能解决问题怎么办? 如果这不能解决问题,我们随时准备提供帮助。兼容性是我们工程团队的重中之重。 请发送电子邮件错误报告至 support@ironsoftware.com。 所有兼容性问题将由高级工程师认真审查。 务必告知我们正在部署的操作系统/平台,特别是如果是像AWS或Azure这样的云平台。 如何在IronPDF中启用本机日志记录 附加日志文件到错误报告中可以使我们隔离问题并迅速解决的概率增加一倍以上。 在运行任何IronPDF方法之前,将此放置在代码顶部(所有2021.3.1之后的版本): // Set the log file path, this can be a directory or a full file path IronPdf.Logging.Logger.LogFilePath = "Default.log"; // Enable all logging modes for detailed logging information IronPdf.Logging.Logger.LoggingMode = IronPdf.Logging.Logger.LoggingModes.All; // Set the log file path, this can be a directory or a full file path IronPdf.Logging.Logger.LogFilePath = "Default.log"; // Enable all logging modes for detailed logging information IronPdf.Logging.Logger.LoggingMode = IronPdf.Logging.Logger.LoggingModes.All; ' Set the log file path, this can be a directory or a full file path IronPdf.Logging.Logger.LogFilePath = "Default.log" ' Enable all logging modes for detailed logging information IronPdf.Logging.Logger.LoggingMode = IronPdf.Logging.Logger.LoggingModes.All $vbLabelText $csharpLabel IronPDF生成的日志文件位于DLL部署的项目/bin目录中: default.log(部署过程) cef.log(渲染) IronSoftwareCefSubprocess.log(渲染与线程) IronSoftwareEngine.log(对调试以"从...生成 PDF 错误"开头的异常非常有用) 云服务器通常有特定的日志文件存放位置。 我们有在Azure和AWS生成日志文件的指南。 Curtis Chau 立即与工程团队聊天 技术作家 Curtis Chau 拥有卡尔顿大学的计算机科学学士学位,专注于前端开发,精通 Node.js、TypeScript、JavaScript 和 React。他热衷于打造直观且美观的用户界面,喜欢使用现代框架并创建结构良好、视觉吸引力强的手册。除了开发之外,Curtis 对物联网 (IoT) 有浓厚的兴趣,探索将硬件和软件集成的新方法。在空闲时间,他喜欢玩游戏和构建 Discord 机器人,将他对技术的热爱与创造力相结合。 准备开始了吗? Nuget 下载 16,493,056 | Version: 2025.11 刚刚发布 免费 NuGet 下载 总下载量:16,493,056 查看许可证