IronPDF Ubuntu 24.04 Dependency Issue on .NET 9 and .NET 10

On Ubuntu 24.04 with .NET 9 or .NET 10, IronPDF fails to install its required system dependencies at startup. This affects Azure Linux images and non-Docker Linux environments where the application does not run with root privileges.

E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied)
E: Unable to lock directory /var/lib/apt/lists/

Ubuntu 24.04 renamed the audio library from libasound2 to libasound2t64. IronPDF's automatic dependency installer targets the original libasound2 package name and cannot acquire the APT lock when running as a non-root user, producing the permission error shown above.

Solution

Option 1: Enable automatic dependency configuration (Docker and Azure Linux)

Set LinuxAndDockerDependenciesAutoConfig to true before the first render call:

IronPdf.Installation.LinuxAndDockerDependenciesAutoConfig = true;
IronPdf.Installation.LinuxAndDockerDependenciesAutoConfig = true;
IronPdf.Installation.LinuxAndDockerDependenciesAutoConfig = True
$vbLabelText   $csharpLabel

To capture diagnostic output during startup, enable file logging:

IronSoftware.Logger.LoggingMode = IronSoftware.Logger.LoggingModes.File;
IronSoftware.Logger.LogFilePath = "ironpdf.log";
IronSoftware.Logger.LoggingMode = IronSoftware.Logger.LoggingModes.File;
IronSoftware.Logger.LogFilePath = "ironpdf.log";
IronSoftware.Logger.LoggingMode = IronSoftware.Logger.LoggingModes.File
IronSoftware.Logger.LogFilePath = "ironpdf.log"
$vbLabelText   $csharpLabel

Option 2: First-launch with elevated privileges (non-Docker Linux)

For non-Docker Linux environments, run the application once with elevated privileges so IronPDF can install the required packages:

sudo -E dotnet run
sudo -E dotnet run
SHELL

If dotnet is not found under sudo, use the full path:

sudo -E ~/.dotnet/dotnet run
sudo -E ~/.dotnet/dotnet run
SHELL

After the first launch installs dependencies, subsequent runs do not require elevated privileges. For the full list of packages required on Ubuntu 24.04, see the Linux deployment guide.

ImportantThis issue was resolved in IronPDF 2026.3.x. Upgrading to that version or later means the libasound2t64 library rename is detected automatically without requiring manual configuration.

Curtis Chau
Technical Writer

Curtis Chau holds a Bachelor’s degree in Computer Science (Carleton University) and specializes in front-end development with expertise in Node.js, TypeScript, JavaScript, and React. Passionate about crafting intuitive and aesthetically pleasing user interfaces, Curtis enjoys working with modern frameworks and creating well-structured, visually appealing manuals.

...

Read More
Ready to Get Started?
Nuget Downloads 19,345,590 | Version: 2026.6 just released
Still Scrolling Icon

Still Scrolling?

Want proof fast? PM > Install-Package IronPdf
run a sample watch your HTML become a PDF.