LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 07-25-2014, 11:50 PM   #1
Meph00
LQ Newbie
 
Registered: Jul 2014
Posts: 4

Rep: Reputation: Disabled
No init found after uninstaling libc6


Hi everyone. I'm a disaster, so please be patient, and I've unistalled libc6. Someone here had the same problem back in 2004, I'm in this exact situation:
http://www.linuxquestions.org/questi...-libc6-176619/
(hoping that reposting is better than necromancing)
and I get stuck on "Step 4" of ToniT's guide.
I have a live CD and booted from there, so my steps are a bit different from torriate's.
Here it is, more or less, what I've done so far:

sudo -i
mkdir /mnt/sda2
#/mnt/ directory is empty and I get an error if I mount before making the directory myself
mount /dev/sda2 /mnt/sda2
#i have two partitions: sda1 and sda2. sda1 contains /home and sda2 contains /, so i GUESS i should mount sda2
#mount seems to work fine as I see a lot of directories in /mnt/sda2 such as bin, etc, root, lib, usr, var
#if I go with 'chroot /mnt/sda2' it fails saying that it can't find /bin/bash
cp /lib/x86_64-linux-gnu/libc.so.6 /mnt/sda2/lib/x86_64-linux-gnu
#i found libc.so.6 in my live CD and i copy it where i THINK it should be
chroot /mnt/sda2 /sbin/ldconfig
chroot: failed to run command: 'sbin/ldconfig': No such file or directory

I red torriate's post and he has the same problem; to resolve it he copies ldconfig (that i'm able to locate) somewhere. I copied it pratically everywhere (/mnt/sda2, /mnt/sda2/sbin <- it's already there, /mnt/), but nothing seems to work. I'm deeply confused by mounting, I think I'm just misunderstanding something. Sorry for language errors, I hope you can help me. Thanks in advance.

Last edited by Meph00; 07-25-2014 at 11:52 PM.
 
Old 07-26-2014, 12:05 AM   #2
Randicus Draco Albus
Senior Member
 
Registered: May 2011
Location: Hiding somewhere on planet Earth.
Distribution: No distribution. OpenBSD operating system
Posts: 1,711
Blog Entries: 8

Rep: Reputation: 635Reputation: 635Reputation: 635Reputation: 635Reputation: 635Reputation: 635
Why on Earth did you remove the C library?
To add to that, what were you trying to do? An upgrade? A few more details would be helpful.
 
Old 07-26-2014, 12:16 AM   #3
Meph00
LQ Newbie
 
Registered: Jul 2014
Posts: 4

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Randicus Draco Albus View Post
Why on Earth did you remove the C library?
To add to that, what were you trying to do? An upgrade? A few more details would be helpful.
Pretty much for the same reason torriate did it ten years ago :C I got stuck in a dependency problem trying to install something. I think ToniT's guide and torriate's response should already give me the solution, but i need help to understand them... I think/hope I may be fine if I manage to chroot.
 
Old 07-26-2014, 12:53 AM   #4
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
I don't have Debian, but run "which ldconfig" to find out where it lives nowadays and adjust command appropriately - may be /usr/sbin these days.
 
Old 07-26-2014, 01:19 AM   #5
Randicus Draco Albus
Senior Member
 
Registered: May 2011
Location: Hiding somewhere on planet Earth.
Distribution: No distribution. OpenBSD operating system
Posts: 1,711
Blog Entries: 8

Rep: Reputation: 635Reputation: 635Reputation: 635Reputation: 635Reputation: 635Reputation: 635
Quote:
Originally Posted by Meph00 View Post
Pretty much for the same reason torriate did it ten years ago :C I got stuck in a dependency problem trying to install something.
That tells us very little. What are you using: Stable or Testing? What are you trying to install?
My guess is you are using Stable, but did, or tried to, upgrade libc6 to the version in Testing. Yes, no? If so, you have created a big mess. If you are using Testing and are having an upgrade problem, then I do not possess any knowledge to help.
 
Old 07-26-2014, 08:17 AM   #6
Meph00
LQ Newbie
 
Registered: Jul 2014
Posts: 4

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by syg00 View Post
I don't have Debian, but run "which ldconfig" to find out where it lives nowadays and adjust command appropriately - may be /usr/sbin these days.
Output is "/sbin/ldconfig". The problem has something to do with this: http://unix.stackexchange.com/questi...e-or-directory
"This error means that there is no [program name] directory inside chroot".
torriate resolve this copying it:

cp /mnt/tmp/sbin/ldconfig /mnt/sbin
chroot /mnt /sbin/ldconfig

but I can't understand where I should copy it.
Quote:
That tells us very little. What are you using: Stable or Testing? What are you trying to install?
My guess is you are using Stable, but did, or tried to, upgrade libc6 to the version in Testing. Yes, no? If so, you have created a big mess. If you are using Testing and are having an upgrade problem, then I do not possess any knowledge to help.
I'm using Testing (jessie). I was trying to install SimpleScreenRecorder and I found a package which installed me an older version of libc6; this gave me an error (when trying to apt-get install -f) that I don't remember (I googled it from that debian, so I can write it if I manage to recover it). I then unistalled libc6.
 
Old 07-26-2014, 08:10 PM   #7
widget
Senior Member
 
Registered: Oct 2008
Location: S.E. Montana
Distribution: Debian Testing, Stable, Sid and Manjaro, Mageia 3, LMDE
Posts: 2,628

Rep: Reputation: 497Reputation: 497Reputation: 497Reputation: 497Reputation: 497
So, to sum this up, you are using Debian testing, an unstable version, and installing a 3rd party application on it that has not been updated for over a year and then trying to use 10 year old directions for fixing a broken system.

Remove the package you installed and install a modern libc6.

Learn to use ffmpeg to do your screen recording.
 
1 members found this post helpful.
Old 07-27-2014, 01:02 AM   #8
Meph00
LQ Newbie
 
Registered: Jul 2014
Posts: 4

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by widget View Post
So, to sum this up, you are using Debian testing, an unstable version, and installing a 3rd party application on it that has not been updated for over a year and then trying to use 10 year old directions for fixing a broken system.

Remove the package you installed and install a modern libc6.

Learn to use ffmpeg to do your screen recording.
Yes, and all of that is totally unrelated to the problem. I was basically asking if someone could help me understanding those directions (which are 100% correct); the title of this thread could have just been "how to install libc6 from a live CD", regardless the reasons why someone unistalled it. All the difficulty (personally speaking) was in mounting and chrooting; I managed to solve the problem after reading torriate's reply more carefully, and I actually learned a lot from this.
We probably have different ideas about what linux is. I find getting in trouble and trying to adapt to your problem solutions you find online highly instructive. I use windows when I want a boring os.

Last edited by Meph00; 07-27-2014 at 01:07 AM.
 
Old 07-27-2014, 02:16 AM   #9
Randicus Draco Albus
Senior Member
 
Registered: May 2011
Location: Hiding somewhere on planet Earth.
Distribution: No distribution. OpenBSD operating system
Posts: 1,711
Blog Entries: 8

Rep: Reputation: 635Reputation: 635Reputation: 635Reputation: 635Reputation: 635Reputation: 635
Quote:
Originally Posted by Meph00 View Post
Yes, and all of that is totally unrelated to the problem.
No is not unrelated. It is the cause of the problem. With a few rare exceptions, the only safe way to add third-party packages is to compile them from source. Simply adding packages or repositories from non-Debian sources will mostly likely result in a damaged, or sometimes completely broken, system.

In this case, you are messing around with the C library, which is a fundamental component of the core of the system. It is a bad idea to tamper with it, unless there is a very good reason, and then the utmost care is needed.
 
  


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] libstdc++-libc6.2-2.so.3 => not found dotilaso Red Hat 4 07-30-2010 01:42 AM
kernel panic: No init found after uninstaling libc6 torriate Debian 4 01-26-2008 02:18 PM
kernal panic no init found try passing init option to kernel m2azer Linux - General 3 11-08-2007 01:51 PM
libstdc++-libc6.2.2.so.3 not found dennisparrott Linux - Software 3 01-24-2005 06:10 AM
error "Kernel panic: No init found. Try passing init= option Anauj0101 Linux - Newbie 3 05-06-2003 10:18 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 10:40 AM.

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