Solved

Seeing contents of linux drive in another PC?

Posted on 2006-11-06
4
263 Views
Last Modified: 2010-04-20
Hi all,

We have a client who had someone setup a Linux file server for them (which they were conecting too via Windows XP). The server has died. Unfortunately, the motherboard cpu etc is so old i cant "replace" it. So we need to rebuild server for them. Hard Drive works fine, however, I cannot login as "root" as they have not got the password and the original persin cant remember it.

Not sure what my choices are here, but i need to get the data off the drive. Thought i could install say Ubuntu on another PC and place the "servers" drive in as a slave into the new Ubuntu PC. Would i be able to see the data on it? Or can anyone suggest a better way of appoaching this?

PS. I'm windows user (blush)....so not to technical on the Linux please....

Thanks
Sean

0
Comment
Question by:SeanNij
  • 2
4 Comments
 
LVL 45

Accepted Solution

by:
sunnycoder earned 500 total points
ID: 17886859
Hi SeanNij,

> Thought i could install say Ubuntu on another PC and place the "servers" drive in
> as a slave into the new Ubuntu PC. Would i be able to see the data on it?
Yes ... you can mount the filesystem on the slave using mount command and browse the information

>Or can
> anyone suggest a better way of appoaching this?
If you can boot off this disk, you can try logging in single user mode, something like
http://www.redhat.com/docs/manuals/linux/RHL-7.3-Manual/custom-guide/s1-rescuemode-booting-single.html

Exact details will vary somewhat depending on your bootloader, but in essence, it can be done.

Cheers!
sunnycoder
0
 
LVL 1

Author Comment

by:SeanNij
ID: 17886885
Mount command. mount //help get me going?

Does Ubuntu have a "windows user friendly version"......
0
 
LVL 45

Expert Comment

by:sunnycoder
ID: 17886899
Hi Sean,

"man mount" will help you get going .. Online version here
http://www.die.net/doc/linux/man/man8/mount.8.html

It takes a while to get used to Linux. There was something called Lindows that was friendly for a windows user but I am not aware if that distro still exists.

Cheers!
sunnycoder
0
 
LVL 14

Expert Comment

by:ppfoong
ID: 17886913

Normally, boot from the Linux Installation CD and you will have an option to enter "rescue mode" or "recovery mode", which will mount all the partitions of the harddisk, and put you in a command shell.

From the command shell, you can enter /etc directory of the target harddisk, normally mounted as "/mnt/etc" and find the file named as shadow.

Find the root entry in th shadow file, and you will see something like this:

root:$1$xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/:13081:0:99999:7:::

Use VI or other available editor, zero out the second field (anything between the first and second semicolon), so that it become:

root::13081:0:99999:7:::

and save the file.

The action above has removed the root password, and you can login root without any password now.

Alternatively, if you have the password field of any other user which you know the password, you may copy over the user's encrypted password to the root's encrypted password field as above, and login with that password.

Good luck.



0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Join & Write a Comment

Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
In my business, I use the LTS (Long Term Support) versions of Linux. My workstations do real work, and so I rarely have the patience to deal with silly problems caused by an upgraded kernel that had experimental software on it to begin with from a r…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now