LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 06-30-2009, 04:28 PM   #1
Seregwethrin
Member
 
Registered: Feb 2008
Posts: 112

Rep: Reputation: 16
Question [SOLVED] mv /* ./ - bin and other folders moved to home directory


Hello;

I should have entered "mv wp/* ./" but I've entered "mv /* ./" by an oversight while in a user directory.

Now bin, sbin, lib and some other root folders have gone to a user directory under home folder.


I can't access most of commands. I can use "cd" but can't use "mv"

Code:
[root@*** public_html]# /home/swtor/public_html/bin/mv   /home/swtor/public_html/bin/*   /bin

-bash: /home/swtor/public_html/bin/mv: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory
I get that error most of commands with using the real path "/home/swtor/public_html/bin/xxx", tried with ln, ls etc...

What should I do?

(Centos 5)

Last edited by Seregwethrin; 06-30-2009 at 04:57 PM.
 
Old 06-30-2009, 04:31 PM   #2
elfoozo
Member
 
Registered: Feb 2004
Location: Washington, USA
Distribution: Debian
Posts: 265

Rep: Reputation: 32
I would try booting from a Live CD and mount the volume then relocate things.
 
Old 06-30-2009, 04:32 PM   #3
Seregwethrin
Member
 
Registered: Feb 2008
Posts: 112

Original Poster
Rep: Reputation: 16
It's a web server and i'm using it from ssh

No way to reach it physically...
 
Old 06-30-2009, 04:39 PM   #4
pwc101
Senior Member
 
Registered: Oct 2005
Location: UK
Distribution: Slackware
Posts: 1,847

Rep: Reputation: 128Reputation: 128
I saw this once, a long time ago, perhaps it'll help here. I'd use cp rather than mv:
Code:
/lib/ld-linux.so.2 --library-path /lib /home/swtor/public_html/bin/cp -a /home/swtor/public_html/bin/* /bin
If you're on a 64-bit machine, you might find the paths need amending.

Last edited by pwc101; 06-30-2009 at 04:49 PM. Reason: fixed command
 
Old 06-30-2009, 04:50 PM   #5
Seregwethrin
Member
 
Registered: Feb 2008
Posts: 112

Original Poster
Rep: Reputation: 16
Quote:
Originally Posted by pwc101 View Post
I saw this once, a long time ago, perhaps it'll help here. I'd use cp rather than mv:
Code:
/lib/ld-linux.so.2 --library-path /lib /home/swtor/public_html/bin/cp -a /home/swtor/public_html/bin/* /bin
If you're on a 64-bit machine, you might find the paths need amending.
Thank you pwc101! Worked successfully with a little modify Really thank you!
 
  


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
/bin/bash: permission denied(after / partition moved) xbuffalo Linux - General 7 06-19-2008 01:18 AM
How can I copy hidden home directory configuration files and folders? rm_-rf_windows Linux - General 3 06-29-2007 05:26 AM
Bin Moved David@330 Linux - Newbie 3 08-17-2004 12:58 PM
/bin in my home directory? shanenin Linux - Software 6 06-06-2004 04:05 PM
imap folders show my whole /home/user directory nuzzy Linux - Software 2 04-16-2003 06:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

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