LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 11-07-2023, 11:53 AM   #1
Mooncakes
LQ Newbie
 
Registered: Nov 2023
Posts: 2

Rep: Reputation: 0
Error with Shared Libraries Even Though Libraries Exist


Hello,

My system is RHEL 8.0 x86_64.

I installed software and after attempting to execute it I encountered the errors below:
  • error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
    error
  • error while loading shared libraries: libdl.so.2: cannot open shared object file: No such file or directory
    error

I uninstalled and reinstalled the libraries. I confirmed the files do exist in both /usr/lib and /usr/lib64. After setting the LD_LIBRARY_PATH to /usr/lib:/usr/lib64, the error changed to the following errors:
  • error while loading shared libraries: libc.so.6: wrong ELF class: ELFCLASS32
  • error while loading shared libraries: libdl.so.2: wrong ELF class: ELFCLASS64

I tried running the software in a 32-bit VM, but encountered the same error.

Any thoughts on how to fix this issue?
 
Old 11-07-2023, 01:08 PM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,976

Rep: Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337
what software is it? I guess it is a 32/64 bit mismatch
 
Old 11-07-2023, 02:36 PM   #3
Mooncakes
LQ Newbie
 
Registered: Nov 2023
Posts: 2

Original Poster
Rep: Reputation: 0
I took a look at the environment file and it's supposed to be able to run on both 32 and 64-bit operating systems. I also tried to run it separately on 32 and 64-bit systems and encountered the same error.
 
Old 11-07-2023, 03:33 PM   #4
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,976

Rep: Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337
the usual way to test is to run:
ldd <binary executable>
 
Old 11-07-2023, 07:12 PM   #5
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,679
Blog Entries: 4

Rep: Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947
Also: the Linux loader uses a cache file to quickly enable it to locate libraries. (Linux has a fairly complicated way of allowing applications to specify the libraries that they need, so this avoids "filesystem searching each time.") As root, run the ldconfig command to rebuild this cache and see if the problem goes away. (Installation scripts usually run this command for you.)
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] virt-manager not recognising uefi binary path even though it exist hackdev17 Linux - Virtualization and Cloud 2 11-03-2023 03:54 AM
Linux Mint error msg: error while loading shared libraries: libssl.so.1.0.0: cannot open shared object file: nicolaus_k Linux - Newbie 8 05-14-2022 12:32 PM
How to fix error: " error while loading shared libraries: libssl.so.1.0.0: cannot open shared object file: No such file or directory"? justa_skid Linux - Newbie 2 02-22-2021 02:23 AM
Urgent !!! rpm: error while loading shared libraries: libelf.so.1: cannot open shared tinaa Linux - Software 5 12-02-2008 03:19 PM
linux init error in loading shared shared libraries akaran Linux - Software 1 05-28-2003 04:40 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 09:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration