Software & AppsOperating SystemLinux

How To Fix “Cannot open shared object file” Error on Ubuntu 64

Ubuntu 4

In this article, we will explore how to fix the “Cannot open shared object file” error on Ubuntu 64. This error typically arises when a program is trying to access a shared library file that is missing or not found in the expected directory.

Quick Answer

To fix the "Cannot open shared object file" error on Ubuntu 64, you can try creating a symbolic link from to using the command "sudo ln -sf /lib/i386-linux-gnu/ /lib/i386-linux-gnu/". If that doesn’t work, you can install the libudev0 package or modify the binary with a hex editor.

Understanding the Error

Before we dive into the solutions, let’s understand the error message. is a shared library file that is required by certain programs to function correctly. If the program cannot find this file, it will throw the “Cannot open shared object file” error.

Solution 1: Creating a Symbolic Link

One of the easiest ways to resolve this error is by creating a symbolic link. A symbolic link, or symlink, is a type of file that points to another file or directory.

Step-by-step Guide

  1. Open a terminal. You can do this by pressing Ctrl + Alt + T on your keyboard.
  2. Run the following command: sudo ln -sf /lib/i386-linux-gnu/ /lib/i386-linux-gnu/

In this command, ln is used to create links between files. The -s option tells ln to create a symbolic link, and the -f option forces it to remove existing destination files. The command creates a symbolic link from to, allowing the program to find the required library.

Solution 2: Installing the libudev0 Package

If creating a symbolic link doesn’t resolve the issue, you can try installing the libudev0 package.

Step-by-step Guide

  1. Go to the libudev0 package page and download the appropriate package for your system (64-bit or 32-bit).
  2. Double-click the downloaded .deb file to install it, or use the terminal to navigate to the directory where the file was downloaded and run the command dpkg -i libudev0_175-0ubuntu9_amd64.deb (replace the filename with the one you downloaded).

The dpkg -i command is used to install a package. The -i option stands for install, and it is followed by the name of the package you want to install.

Solution 3: Modifying the Binary with a Hex Editor

If the above solutions don’t work, you can use a hex editor to modify the binary. This method should be used as a last resort as it involves modifying the program’s binary code.

Step-by-step Guide

  1. Install a hex editor like hexedit by running sudo apt-get install hexedit in the terminal.
  2. Navigate to the directory where the program executable is located.
  3. Open the executable file with the hex editor using the command sudo hexedit <filename>.
  4. Search for the string and change it to
  5. Save the changes and exit the hex editor.

In this process, you’re essentially modifying the binary to look for instead of


Fixing the “Cannot open shared object file” error on Ubuntu 64 can be achieved through creating a symbolic link, installing the libudev0 package, or modifying the binary with a hex editor. However, it’s important to note that creating symbolic links or modifying binaries can have unintended consequences and may not be the best solution in all cases. Always try the solutions in the order provided and choose the one that works best for your specific situation.

What is a symbolic link?

A symbolic link, also known as a symlink, is a type of file that acts as a pointer to another file or directory. It allows you to create a shortcut or alias to a file or directory, making it easier to access or reference.

How do I open a terminal in Ubuntu?

To open a terminal in Ubuntu, you can press Ctrl + Alt + T on your keyboard. This keyboard shortcut will open a new terminal window where you can run commands and perform various tasks.

What is the purpose of the `sudo` command?

The sudo command in Ubuntu is used to execute commands with administrative privileges. It allows a user to run commands as the superuser or another specified user, granting them the necessary permissions to perform tasks that require elevated privileges.

How do I install a package using `dpkg`?

To install a package using dpkg in Ubuntu, you can use the dpkg -i command followed by the name of the package file. For example, if the package file is named package.deb, you can run the command dpkg -i package.deb in the terminal. This will install the package on your system.

What is a hex editor?

A hex editor is a software tool that allows you to view and edit binary files at a low-level. It displays the contents of a file in hexadecimal format, allowing you to modify the individual bytes of the file. Hex editors are commonly used for tasks such as modifying executable files or analyzing the structure of binary files.

Leave a Comment

Your email address will not be published. Required fields are marked *