LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-06-2009, 12:02 PM   #1
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Lubuntu 17.10 x64
Posts: 510

Rep: Reputation: 33
I've deleted /bin by mistake. Now I can't boot my Slackware64 13 system.


Well, as the title says, I deleted /bin by mistake. I wanted to remove a bin folder that was in a backup partition and I think I used rm -r /bin as root instead of rm -r bin (this happens when one is tired and needs some sleep :-).

From there on, terminal did not recognize commands. I didn't realized what happened until I rebooted my computer and it stopped loading and, of course, there isn't any prompt nor X.

So, before I start to cry :-( Is there something I can do to recover my /bin folder and Slackware64 13?

Now, I can write this thread because I am running Debian Lenny. I can also mount Slackware partitions from here. Advantages of using more than a Linux OS.

Thanks my friends!
 
Old 09-06-2009, 12:07 PM   #2
uteck
Senior Member
 
Registered: Oct 2003
Location: Elgin,IL,USA
Distribution: Ubuntu based stuff for the most part
Posts: 1,170

Rep: Reputation: 500Reputation: 500Reputation: 500Reputation: 500Reputation: 500Reputation: 500
Do you still have the Slack install disk? I think it is a live-CD, so you could boot from it and copy /bin to your Slack partition.
 
Old 09-06-2009, 12:11 PM   #3
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Lubuntu 17.10 x64
Posts: 510

Original Poster
Rep: Reputation: 33
Quote:
Originally Posted by uteck View Post
Do you still have the Slack install disk? I think it is a live-CD, so you could boot from it and copy /bin to your Slack partition.
Yes, I have it but I am not sure it is a livedvd. Is it possible to copy the /bin folder to my slackware partition but from Debian (which I am using now)?

If that is possible, Do I have just to copy it as root or I have to do something else? Where is /bin in the Slackware DVD?

I also have partedmagic livecd.


Thanks for your help. I keep listening...

Last edited by glore2002; 09-06-2009 at 12:15 PM.
 
Old 09-06-2009, 12:28 PM   #4
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
If you have a backup of /bin at hand, just copy it to / -- but I guess you don't so AFAIK all you can do is reinstall, not forgetting backup directories containing files that you wish to keep, at least /home (if you need to re-format the partition where it lives), /etc and maybe /var (e.g. for databases files).
 
Old 09-06-2009, 12:29 PM   #5
uteck
Senior Member
 
Registered: Oct 2003
Location: Elgin,IL,USA
Distribution: Ubuntu based stuff for the most part
Posts: 1,170

Rep: Reputation: 500Reputation: 500Reputation: 500Reputation: 500Reputation: 500Reputation: 500
I don't think coping /bin from Debian will work, even if Debian is the 64-bit version. It may even make things worse.

From Debian you could mount the Slack install disk (or the iso file) and look to see if their is /bin on the disk that you can copy.
 
Old 09-06-2009, 12:34 PM   #6
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Lubuntu 17.10 x64
Posts: 510

Original Poster
Rep: Reputation: 33
Quote:
Originally Posted by Didier Spaier View Post
If you have a backup of /bin at hand, just copy it to / -- but I guess you don't so AFAIK all you can do is reinstall, not forgetting backup directories containing files that you wish to keep, at least /home (if you need to re-format the partition where it lives), /etc and maybe /var (e.g. for databases files).
No, I don't have any /bin backup :-(

And...What about the packages I've installed? Will I have to reinstall them?

My partition scheme in slackware is:

/
/home
SWAP

I didn't mean to copy /bin from Debian to Slackware. What I was trying to say was if I could copy /bin from the slacware dvd to /bin in slackware root partition but using debian to copy those files. But, as far as I can see, there isn't any /bin folder in slackware dvd.

Is there a way to backup my installed packages?

Thanks for your cooperation.

Last edited by glore2002; 09-06-2009 at 12:36 PM.
 
Old 09-06-2009, 12:35 PM   #7
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
I didn't see your last message before posting.

Do not copy /bin from Debian, if you do Slackware won't work for long after that.

And there is no /bin directory available on you installation disk, it is created by the installer on your disk drive.

Last edited by Didier Spaier; 09-06-2009 at 12:36 PM.
 
Old 09-06-2009, 12:44 PM   #8
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
I answer to your last post.

Yes, you'll have to reinstall all your Slackware packages.

No big deal if you did a full install, its a matter of 15-20 minutes or so on your machine.
 
Old 09-06-2009, 01:05 PM   #9
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Lubuntu 17.10 x64
Posts: 510

Original Poster
Rep: Reputation: 33
Quote:
Originally Posted by Didier Spaier View Post
I answer to your last post.

Yes, you'll have to reinstall all your Slackware packages.

No big deal if you did a full install, its a matter of 15-20 minutes or so on your machine.
Thanks Didier! What about the packages I've installed after installing Slackware (openoffice and so many others). Do I have to reinstall them too?

I will copy my /tmp folder. That way I may reinstall those packages with

installpkg *.t?z.

I will also copy /etc and /var. Since /home is on a different partition, I wont reformat it when reinstalling. Do I have to backup anything else?

Thanks again,

Germán.-
 
Old 09-06-2009, 01:13 PM   #10
samac
Senior Member
 
Registered: Mar 2004
Location: Kirkwall, Orkney
Distribution: Linux Mint 20.3 - Cinnamon
Posts: 1,425

Rep: Reputation: 139Reputation: 139
You will possibly not have to install your packages if they installed to /usr/bin, but be prepared to install them if they don't work. If you just go to the slackware directory on your cd and you will see a, d, e, f .... etc and run

upgradepkg --reinstall */*.t?z

that should look at /var/log/packages and only install the packages that you have installed on your system. This is useful if, like me, you trim your install.

samac
 
Old 09-06-2009, 01:30 PM   #11
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
Yes, you will have to reinstall all packages, be it included or not in the distribution, as all directories but /home will have to be formatted during setup.

If you installed some packages in /opt (e.g. this could be the case for OpenOffice and Adobe Reader), you could backup their directories. But then you will have to re-create the symbolic links to it after having copied it to the new system, so I'm not sure this is worth the hassle. All in all I think you'll be better off reinstalling everything, to make sure you have a clean system.

Then if you happen to build yourself a package, e.g. using the slackbuilds available at http://slackbuilds.org, keep the package after installing it just in case.
 
Old 09-06-2009, 01:48 PM   #12
titopoquito
Senior Member
 
Registered: Jul 2004
Location: Lower Rhine region, Germany
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,640

Rep: Reputation: 144Reputation: 144
Chances that you have to reinstall your custom compiled packages are low. That depends of course on which packages exactly that are, but on my system I don't have a single (of many custom compiled) package which saves a file in /bin.

If you are not sure and if you can identify the packages (by a special tag or something) you can check that. For example to look for all packages build by script from Slackbuilds.org:
Code:
grep -e "^bin" /var/log/packages/*SBo*
grep -e "^bin" /var/log/scripts/*SBo*
 
Old 09-06-2009, 02:04 PM   #13
samac
Senior Member
 
Registered: Mar 2004
Location: Kirkwall, Orkney
Distribution: Linux Mint 20.3 - Cinnamon
Posts: 1,425

Rep: Reputation: 139Reputation: 139
Quote:
Yes, you will have to reinstall all packages, be it included or not in the distribution, as all directories but /home will have to be formatted during setup.
You really will not have to re-install your entire system. Just boot your computer using the install cd/dvd and then follow the instructions in my previous post, and all your settings will be intact.

samac
 
Old 09-06-2009, 02:12 PM   #14
titopoquito
Senior Member
 
Registered: Jul 2004
Location: Lower Rhine region, Germany
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,640

Rep: Reputation: 144Reputation: 144
Do what samac says

What came to my mind in addition: After reinstalling all apps you will probably have some ".new" files let's say in /etc. Be sure to search for them (find /etc -type -f -name "*.new"), merge eventually made changes and remove the duplicate files.
 
Old 09-06-2009, 03:36 PM   #15
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Lubuntu 17.10 x64
Posts: 510

Original Poster
Rep: Reputation: 33
Will I have to reinstall multilib? :-( Buahhhhhhhhh
 
  


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
deleted by mistake .thunderbird valemon Linux - General 6 08-28-2007 05:12 PM
Am i done for? Deleted /etc by mistake AriciU Slackware 10 07-07-2007 06:07 AM
Deleted rc.local by mistake Fredstar *BSD 4 06-18-2007 08:44 AM
Deleted linux partition on a dual boot system...made mistake? shahidsaab1 Linux - Newbie 6 07-06-2006 12:38 AM
help pls! deleted something by mistake marlor Slackware 2 02-05-2005 08:06 AM

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

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