Trinity rescue - Linux help please?

Forbiddenbiker

The Enforcer
Messages
11,048
Name
Adam
Edit My Images
Yes
Story is ...Old computer, old windows XP won't boot up (system seems good otherwise) ..So instead I have now booted a basic operating system in Linux from Trinity Rescue Kit software.

I've got it to boot by CD, the .iso software ran and I'm now up and working. ..hoorah.
However I'm looking at a list of tools and/or a command prompt of the tsk software ready to take my commands ...the trouble is they all require a tiny bit of Linux knowledge to trigger the right commands and although ive been reading all day, I'm failing miserably. :help:

I'm basically wanting to down load/save lots of files (images) to an external hard drive via usb. (which usb port i don't know how to find either)
I've tried to find some files.. at the tsk prompt with ..'doc Documents/and/Settings' for instance. ..;file not found;.

I think the TsK software has already mounted the drive during ts own installation (not sure though, but it has named a drive hda1)

So i think the question im asking is How or what basic code should I use to start searching my directories? ..and how should I find my usb ports?


Does that make any sense. ..pretty desperate right now. :shake: thanks. :D
 
Last edited:
Right.

So you have the computer booted and it can see the Windows drive (as /dev/hda1) and you want to copy them to a USB drive. Correct? You can test this by seeing what is mounted with the mount command.

mount

will give you a list of mounted drives and where they are located in the filesystem. A quick read of the trk docs suggests there is a script called mountallfs which tries to mount everything it can find. It might be a good idea to see what happens if you run that (with the USB drive in).

Once you have the two HDDs mounted, they will appear as directories in the filesystem. Say the system has the drives mounted as /mnt/XP and /mnt/USB all you need to do is something like:

cd /mnt/XP
cp -R Documents\ and\ Settings/User/My\ Documents /mnt/USB

and that will copy the My Documents folder and all underneath to the USB drive. Note the \ before the space. Unix treats a space as a delimiter so you need to quote it with the \ character for it to treat it as part of the same word.

Without knowing what you're trying to do or what you've tried, it's difficult to know how tyo help.

You MAY find the command lsusb helpful too as it lists what's on the USB ports. What's clear though is that in order to use the drives, you will have to mount them into the filesystem. You can't use the raw device name to access the disk unfortunately.
 
Last edited:
Have you thought about getting a Linux magazine? Most have cover disks most months that include a live bootable CD. Indeed, most downloadable distro's can be burned as live CD's. These boot and run from CD with the full operating system and don't have to be installed to HDD.
The advantages are that you're running the distro from the CD, with a graphical interface. Drag And Drop is usually supported. Hardware detection is good and should mount your USB drive automatically when it's pugged in. It's sometimes slow due to this but may suit a Windows user (and, indeed, a newer Linux user!) more than wrestling with command lines.
One thing I noticed in your post:
Documents/and/Settings
Been a while since I tried reading a Win partition directory from command line Linux but I seem to recall that the spaces needed to be replaced by '?' rather than '/'

I'm not familiar with Trinity software command line, though.
 
Without knowing what you're trying to do or what you've tried, it's difficult to know how tyo help.

You MAY find the command lsusb helpful too as it lists what's on the USB ports. What's clear though is that in order to use the drives, you will have to mount them into the filesystem. You can't use the raw device name to access the disk unfortunately.

If so, you'll need to do the following:

Mount the USB drive

Hi. thanks ..I did some of the things you said
I've run mount...
/dev/root on / type rootfs (rw)
few none ons then...
/dev/hdc on /trk type iso9660 (ro,relatime)
/dev/loop/0 on /linkedfs-ro type squashfs (ro-relatime)
two more none on then...
/dev/hda1 on /pibck type fuseblk (rw,relatime ,user_id=0 ,group_id-0 ,default_permissions,allow_other ,blksize=4096

...

so then I tried /dev/hda1
Permission denied.

then ran lsusb

bus 1, 2, 2, 3, 4, 4, only two devices in all, ones a web cam...no idea about the other.

I want to try and run that mountallfs ....erm how do I get back to the list at the start any idea.



Have you thought about getting a Linux magazine? Most have cover disks most months that include a live bootable CD. Indeed, most downloadable distro's can be burned as live CD's. These boot and run from CD with the full operating system and don't have to be installed to HDD.
The advantages are that you're running the distro from the CD, with a graphical interface. Drag And Drop is usually supported. Hardware detection is good and should mount your USB drive automatically when it's pugged in. It's sometimes slow due to this but may suit a Windows user (and, indeed, a newer Linux user!) more than wrestling with command lines.
One thing I noticed in your post:
Documents/and/Settings
Been a while since I tried reading a Win partition directory from command line Linux but I seem to recall that the spaces needed to be replaced by '?' rather than '/'

I'm not familiar with Trinity software command line, though.

Sounds like a good plan ... Ill consider it the back up when I realise if linux beyond me. Do you have any names of software at all?

im still not getting the slash thing, but I can copy. thanks for the clues. :)
 
Last edited:
So now run

mountallfs

and what does

mount

give you.

Also, what does

cd /pibck
ls -al

give you?
 
Does the USB drive appear in the mount command now you have powered it?
 
Why thank you (blushes)

Now all you have to do to get the files off is find where the system has put the USB drive.

What does mount say now?
 
Sounds like a good plan ... Ill consider it the back up when I realise if linux beyond me. Do you have any names of software at all?

:)
Depending on your machine's spec, I'd probably go for a slightly older distro, especially if it's say, 2gb ram. Not an ancient one, though :) Maybe a 2008/9/10 version. Hardware support, stability and the GUI are better for newer versions but of course, the trade-offs are speed and resource/memory use.

A quick guide: http://www.labnol.org/software/best-linux-distros/12757/

Linux Mint pretty (relatively) quick, from Live CD.

Ubuntu: Lucid Lucid was ok. If your machine can handle it, I use 10.10 Maverick as my day-to-day OS. Comes in 32bit and 64bit.

Tiny sample of loads but some are a real PITA, designed for nerds :) Stick to the end-user friendly popular distros!

*Edit
Looks like you're doing just fine with Arad and Trinity, hope it work out without resorting to Live CD's :)
 
Last edited:
unmountallfs ?
umountallfs

The spelling is important ;)

Have you discovered file completion yet? Type a few letters of the command and press <tab> and it will try to autocomplete.
 
Depending on your machine's spec, I'd probably go for a slightly older distro, especially if it's say, 2gb ram. Not an ancient one, though :) Maybe a 2008/9/10 version. Hardware support, stability and the GUI are better for newer versions but of course, the trade-offs are speed and resource/memory use.

A quick guide: http://www.labnol.org/software/best-linux-distros/12757/

Linux Mint pretty (relatively) quick, from Live CD.

Ubuntu: Lucid Lucid was ok. If your machine can handle it, I use 10.10 Maverick as my day-to-day OS. Comes in 32bit and 64bit.

Tiny sample of loads but some are a real PITA, designed for nerds :) Stick to the end-user friendly popular distros!

*Edit
Looks like you're doing just fine with Arad and Trinity, hope it work out without resorting to Live CD's :)

Thanks good stuff. its a 2009-2001 xp , 2.8 pent I'll take a look.

Fingerscrossed ...that would be hell. :thumbs:
 
umountallfs

The spelling is important ;)

Have you discovered file completion yet? Type a few letters of the command and press <tab> and it will try to autocomplete.


not yet

ok missed your middle post their. :thinking:

I ran umountallfs some stfuf about invalid argument, not mounted, can t mont, giving up ..then ran mountallfs again

disc contains unnclean file system etc
badly close (guilty) fixing...
result of mounting
/dev/sdb1 on sdb1 type fuseblk (rw allow etc)...(Have i just mounted my external HD.)

then went cd /

mount

and both dev/hda1 on /pibck type fuseblk (rw etc)
and .. dev/sdb1 type fuseblk ( rw noatime , useretc)

both the same size?
 
Last edited:
and both dev/hda1 on /pibck type fuseblk (rw etc)
and .. dev/sdb1 type fuseblk ( rw noatime , useretc)

both the same size?
mount doesn't normally return the size...

so... we have your XP disk mounted on /pibck and your USB drive mounted on ??? (it will say in the mount command).

You now need to find the files you want to copy and copy them. So, assuming the files are in your home directory...

cd /pibck/Documents\ and\ Settings/<user>/My\ Documents

you can probably press <tab> when you have typed the "Doc" of "Documents and Settings" and it will autocomplete.

Next problem is to copy. You will need to do:

cp -R <from files> <to directory>

the -R copies all subdirectories too...
 
mount doesn't normally return the size...

so... we have your XP disk mounted on /pibck and your USB drive mounted on ??? (it will say in the mount command).

You now need to find the files you want to copy and copy them. So, assuming the files are in your home directory...

cd /pibck/Documents\ and\ Settings/<user>/My\ Documents

you can probably press <tab> when you have typed the "Doc" of "Documents and Settings" and it will autocomplete.

Next problem is to copy. You will need to do:

cp -R <from files> <to directory>

the -R copies all subdirectories too...

('NewSPARE' is an empty folder on the top level on my external HD. cd /sdb1 then I think ../ NewSPARE/ same ../ level as doc and settings anyway.
.
so something like this?
cd /-R /pibck/Documents\ and\ Settings/<user>/sdb1/NewSPARE/
 
Last edited:
('NewSPARE' is an empty folder on the top level on my external HD. cd /sdb1 then I think ../ NewSPARE/ same ../ level as doc and settings anyway.
.
so something like this?
cd /R /pibck/Documents\ and\ Settings/<user>/sdb1/ NewSpare/
Hang on....

cd = change directory
cp = copy

And the switch in linux is - not /

You have the devices mounted now. mountallfs mounted the USB at /<device name> so I think your command sequence should be (but I'm interpreting what you typed here)

cd /pibck/Documents\ and\ Settings/<user>
cp -R * /sda1/NewSpare

That will copy everything in the user directory to the USB drive NewSpare directory.
 
Hang on....

cd = change directory
cp = copy

And the switch in linux is - not /

You have the devices mounted now. mountallfs mounted the USB at /<device name> so I think your command sequence should be (but I'm interpreting what you typed here)

cd /pibck/Documents\ and\ Settings/<user>
cp -R * /sda1/NewSpare



That will copy everything in the user directory to the USB drive NewSpare directory.

So the switch is the space?

I think your reading me right, Im getting it a bit now, maybe ... but you meant sdb1 not sda1 right?


cd /pibck/Documents\ and\ Settings/<user>
cp -R * /sdb1/NewSpare

* is all files*

? or have I missed something.

thank you very much for your help Andy... rescued from hours of frustration. greatly appreciated.
 
Last edited:
Did it work?
 
glad it worked.

I downloaded this one when I had a similar problem with someones virus laden computer- http://www.ubuntu.com/download/ubuntu/download

All graphical windows ish interface and very easy. I know even less linux than you do and booting from CD and copying to a usb drive was easy.
 
shutdown


Or just ping the power switch. Glad we got you there :thumbs: :)
 
The Trinity CD is a live Linux distro for repairing Windows PCs.
I thought the OP just wanted to recover certain files (pics+docs), rather than repair Windows and learn Linux to do so.
A live distro with a GUI such as Ubuntu, Mandriva, Mint, can be run without having to learn any Linux.
 
I thought the OP just wanted to recover certain files (pics+docs), rather than repair Windows and learn Linux to do so.
A live distro with a GUI such as Ubuntu, Mandriva, Mint, can be run without having to learn any Linux.
Sorry... my reply was a tad curt. I was cooking tea and trying to make sure I gave timely advice. Yes, something like Ubuntu would probably have been better...
 
Back
Top