LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-04-2011, 10:33 PM   #1
b_senthilbe
LQ Newbie
 
Registered: Feb 2011
Posts: 8

Rep: Reputation: 0
chroot fails with "error while loading shared libraries"


Hi,

I am newbee to linux. I am trying to executing a script which does "chroot" for an executable. But I am getting following error.

The chroot in the script is
chroot /var/mnt/test /testbin/myapp

The script bails out with following error.

/testbin/myap: error while loading shared libraries: cannot open shared object file: cannot load shared object file: No such file or directory


I tried ldd for the application. All the shared libraries which are required for myapp are present. Please help me to solve this

- Thanks,
Senthil
 
Old 02-05-2011, 04:36 AM   #2
Person_1873
Member
 
Registered: Sep 2007
Location: Australia
Distribution: Gentoo / Debian / Rasbian / Proxmox
Posts: 519

Rep: Reputation: 44
is your chroot environment the same architecture as the host environment? that is generally (to my experience) the cause of this error
 
1 members found this post helpful.
Old 02-05-2011, 06:02 AM   #3
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
...and in addition to what's posted already:
Quote:
Originally Posted by b_senthilbe View Post
I tried ldd for the application. All the shared libraries which are required for myapp are present.
Libs present, cool, but are they available inside the chroot in a location the loader (ld: /var/mnt/test/etc/ld.so.conf: /var/mnt/test/lib, /var/mnt/test/usr/lib) expects them to be?
 
1 members found this post helpful.
Old 02-05-2011, 01:00 PM   #4
b_senthilbe
LQ Newbie
 
Registered: Feb 2011
Posts: 8

Original Poster
Rep: Reputation: 0
Great. I found a library missing in the chroot jail. I am having some other issues with my system now. I will let you know once it becomes ready.
Thanks for your replies.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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] At run time get: "Error while loading shared libraries: libgdal.so.1:" firani Linux - Newbie 1 06-14-2010 01:05 PM
[SOLVED] XFburn, Slackware 13 64bit, "error while loading shared libraries: libburn.so.4" fearfactory Linux - Software 1 05-16-2010 08:30 PM
"error while loading shared libraries: libstdc++.so.5" shiv_379 Linux - Newbie 6 03-30-2009 02:30 PM
Did something get installed wrong? "error while loading shared libraries" Romanus81 Slackware 4 03-28-2008 11:11 PM
Linux boot hang : "init: error loading shared libraries" colinprice72 Linux - General 0 01-16-2004 09:04 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:23 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