• Welcome to Overclockers Forums! Join us to reply in threads, receive reduced ads, and to customize your site experience!

If only part of a file is readable on a disc, can you copy just that part?

Overclockers is supported by our readers. When you click a link to make a purchase, we may earn a commission. Learn More.

c627627

c(n*199780) Senior Member
Joined
Feb 18, 2002
Let's say you have a 1GB .vob file on a disc. If the disc is damaged and say, 97% of the file can be read, can you copy just the 97% of it?

This would effectively enable you to watch 97% of that file if you could copy it partially.


Sometimes I would need 20 minutes off of a damaged 4.7GB DVD and I can get it by copying whatever I can, then simply creating empty files naming them as they are named on the DVD. I can then edit everything and make it a 20 minute DVD with just the 20 minutes that can be read.

If I could get partial files copied however, I could rescue even more...


EDIT March 28, 2011: Never mind the rest of this thread. Finally figured it out:



When it comes to recovering partially damaged DVDs, Linux gives us better results than Windows because Linux treats devices like block devices whereas Windows only reads complete files. So files can sometimes be partially read in Linux, which is useful in recovering at least part of the data from a damaged DVD, if not all of it... using Linux.


1. You can boot into Linux using an Ubuntu Linux bootable CD iso: http://www.ubuntu.com/desktop/get-ubuntu/download
or preferably by using the iso + the following program to make a bootable Linux USB flash drive: http://www.pendrivelinux.com/


Creating the Bootable Linux flash drive as described here is recommended because doing an actual install anywhere, even on another USB Flash drive will change the Master Boot Record on your Windows hard drive, making it unbootable after you take the USB stick out, even if your Windows hard drive wasn't selected anywhere during the Linux installation (!) Linux does this without any warning. Most newcomers find this out the hard way - after which they cannot boot into Windows and have to spend time fixing their system drive's master boot record. So skip the Linux installation for this, just create a bootable Linux USB flash drive.


IMPORTANT: Move the slider away from zero to set the Universal USB installer Persistent file size for storing changes so that the downloaded Depositories stay on your USB drive for use in the future.
Thank you Alternative Operating Systems section of ocforums for helping me finally accomplish that!


UbuntuInstall.jpg


2. Boot with the newly created USB drive and click on 'Run Ubuntu from this USB' when prompted.

3. Upper left part of the screen > System > Administration > Synaptic Package Manager > if another window pops up, close it > (upper left, where it says File, Edit, Package) click on Settings > Repositories > CHECK the option where it says universe and multiverse > Close > Close > (upper left corner) Reload > wait for it to download and install everything then close all windows (all windows need to be closed or else the next step will not work).

4. Do not use the temporary desktop, only files up to 1 GB may be copied from it. Instead, recover the DVD to one of your hard drives. Find out the name of your hard drive [*Case Sensitive!*] by going to Places > Computer


5. You need to actually click on the name of your hard drive and display its contents so that the drive can be recognized by the system. Also click on the DVD drive where your DVD to be recovered is located.


6. (Upper left corner) Applications > Accessories > Terminal >

sudo apt-get install gddrescue
sudo apt-get install libdvdread4
sudo /usr/share/doc/libdvdread4/install-css.sh
sudo apt-get install lsdvd
lsdvd /dev/dvd


If the name of your hard drive is D Drive [*Case Sensitive!*], then use this command:

ddrescue --no-split --verbose --block-size=2048 /dev/dvd /media/"D Drive"/CopiedDVD.iso /media/"D Drive"/CopiedDVD.iso.log



Note that all these commands may be combined in one line:
sudo apt-get install lsdvd libdvdread4 gddrescue && sudo /usr/share/doc/libdvdread4/install-css.sh && lsdvd /dev/dvd && ddrescue --no-split --verbose --block-size=2048 /dev/dvd /media/"D Drive"/CopiedDVD.iso /media/"D Drive"/CopiedDVD.iso.log


To use another DVD drive (if there are multiple DVD drives on the system), use dvd1 instead of dvd above.


7. If time from last successful read is longer than you think it should be or if you do not wish to wait any longer, end the operation by pressing CTRL+C [CTRL and C together] then type:

sudo apt-get install dvdbackup
dvdbackup -M -i /media/"D Drive"/CopiedDVD.iso -o /media/"D Drive"/



If the files have not been recovered, there are two other commands that can be used to recover data:
ddrescue --direct --max-retries=3 /dev/dvd /media/"D Drive"/dvd.iso /media/"D Drive"/dvd.iso.log
ddrescue --direct --retrim --max-retries=3 /dev/dvd /media/"D Drive"/dvd.iso /media/"D Drive"/dvd.iso.log


8. D Drive will now contain a new *folder* (named after the DVD) containing partial or complete DVD files which could not be read in Windows but were successfully read in Linux.



Be sure to run lsdvd /dev/dvd again before running the ddrescue command on another DVD.




If you wish to also save your modded Bootable Linux flash drive, modern Imaging software such as Norton Ghost cannot make drive images of USB Flash Drives but this can be done using pay-for WinImage or freeware Image Writer for Windows.







 
Last edited:
Boot up a linux live cd(/usb) and use ddrescue to make an image of the dvd. It probably can recover almost the entire dvd.
 
Please post instructions a four year old can follow or else it will take people who don't know linux 1hr to figure out what to do.

I have an Ubuntu 9.04 CD.
 
Please post instructions a four year old can follow or else it will take people who don't know linux 1hr to figure out what to do.

I have an Ubuntu 9.04 CD.

Usually people in the windows sections ignore any linux comments, so I thought I'd wait and see if you were interested, and I'm glad you are :grouphug:.

I know I sent this to you in the pm but I figured I'd post it for everyone also.


First off, I am/was 99.9% sure that Ubuntu came with ddrescue preinstalled, but the ubuntu wiki seems to think otherwise, but idk if it's just on old versions or what. To be safe, installing it is a simple command. From the command line (applications -> Accessories -> Terminal) type the following and press enter.

Code:
sudo apt-get install gddrescue

Now it should be installed and we can use it. [There are prettier/gui ways to install things, most people never use the CLI, but I figured since you were already here, might as well teach ya the good 'ol ways. If you are interested in installing other ways you can use the "Add/Remove Programs" and search fro gddrescue (Or GNU ddrescue), and there is also the synaptic package manager.]

It's actually not to bad at all. Normally I just run (in the terminal)

Code:
ddrescue /path/to/drive /path/to/save/file

so for you it'd be

Code:
ddrescue /dev/dvd ~/Desktop/dvd.iso

(the ~/ is the symbol for your "home" directory. Then Desktop is the folder for everything that appears on your desktop. I can give you more instruction on what everything specifically does, but I'm at work right now.)

That will create an image of the dvd to your desktop. It just uses ddrescue's default settings. It seems to work for me. However I was just reading the Ubuntu wiki and they recommend a slightly different approach.

https://help.ubuntu.com/community/DataRecovery#Imaging a damaged device, filesystem or drive

Code:
ddrescue --no-split /dev/dvd ~/Desktop/dvd.iso ~/Desktop/dvd.iso.log
Code:
ddrescue --direct --max-retries=3 /dev/dvd ~/Desktop/dvd.iso ~/Desktop/dvd.iso.log
Code:
ddrescue --direct --retrim --max-retries=3 /dev/dvd ~/Desktop/dvd.iso ~/Desktop/dvd.iso.log

Basically what they are doing is just first running it and it grabs all the good sectors. Second time it goes after only the bad sectors, it knows the bad sectors cause it reads the log file. Third time it goes after the bad sectors in a different way.

Hopefully this will work, I've had pretty good luck with it. You might have to experiment a little bit, but usually worst case scenario I just rerun my command 2 or 3 times and it gets like 99.9% of it, which should be good enough.

Once you have an iso, hopefully we can just mount it/open it with the zip tool and it will be good, or I know for a fact vlc will be able to play it, which means you can just use vlc to transcode it/save it to a video file, worst case scenario.
 
Thank you kindly! I will try it later today and report back.

This should be useful in the future and very informative for all the Windows-only users out there.
 
Here we go, I downloaded ubuntu 9.10, burnt a CD, and booted using the CD.

The program 'ddrescue' is currently not installed. You can install it by typing:
sudo apt-get install gddrescue
You will have to enable the component called 'universe'


So obviously universe is needed and not just typing sudo apt-get install gddrescue


1. How do we enable universe?
2. How do we specify that it isn't the CD we booted off of that we wish to create the iso from but a DVD from another DVD drive connected to the system?
3. How do we specify the destination to be the root of one of the hard drives on the system?


side question: I have two DVD drives currently connected but is this even possible on systems with just one DVD drive if you boot in using the boot CD...
 
Here we go, I downloaded ubuntu 9.10, burnt a CD, and booted using the CD.

The program 'ddrescue' is currently not installed. You can install it by typing:
sudo apt-get install gddrescue
You will have to enable the component called 'universe'


So obviously universe is needed and not just typing sudo apt-get install gddrescue


1. How do we enable universe?
2. How do we specify that it isn't the CD we booted off of that we wish to create the iso from but a DVD from another DVD drive connected to the system?
3. How do we specify the destination to be the root of one of the hard drives on the system?


side question: I have two DVD drives currently connected but is this even possible on systems with just one DVD drive if you boot in using the boot CD...

1) I could explain it, but they have pretty picture, https://help.ubuntu.com/community/Repositories/Ubuntu . Just check the box for universe and it will enable it. You might as well use this method, "Synaptic : System > Administration > Synaptic Package Manager : >> Settings >> Repositories. ", then after you have selected universe, save/close the window, but leave the synaptic package manager open. Click on the "refresh" or it might be "reload" button. It's in the top left side of the window. When it's done, you can either search for gddrescue, or just click in the middle on any of the "package" that are listed, and then start typing gddrescue, and it will bring you down to the package automatically. Right click the package and mark for installation. Then click on the "apply" button. Now gddrescue is installed.

[That is the GUI but still kind of like the cli way to install packages, the really nice and friendly way is the add/remove programs (aka Ubuntu Software Center now)]

2) Ah, I assumed you had a dvd and a cd drive not 2 dvd drives. I'm not entirely sure of the best way to differentiate the two in ubuntu, but it'll be one of the following. Either the drives will be /dev/dvd /dev/dvd1 (or maybe /dev/dvd0, /dev/dvd1), or it'll be be /dev/hda /dev/hdb (I'm almost 100% that no matter way you'll have hda/hdb). Or ubuntu might have some other method. Can you post the output of
Code:
ls /dev
? I'll be able to tell you for sure. I don't normally use Ubuntu and I haven't had two dvd drives before, so we'll have to double check.

3) Using ddresuce it takes the form of
Code:
ddrescue [options] input output
So in our case we are using
Code:
ddrescue [options] /dev/dvd /path/to/file
In linux harddrives are mounted to folders. There is no "c:", "d:", etc. (all drives, floppy, usb, cd, hdd are treated this way). That way there is seamless integration on your system. In ubuntu it doesn't automount your harddrive, but it *should* appear on your desktop, just double click on it and it will automount it. This will mount it as /media/uid . Where uid is the uid of the drive, some big huge ugly thing. You have two ways to browse the files/folders to find where you want to put it. Since you've double clicked on the hdd, it *should* now be open in the file browser and you can browse it like in windows. The 2nd option is to use the CLI and you can use cd to change directories, or ls to browse them. In linux your CLI 99.99999% of the time has tab-completion. Meaning that in the terminal you can type "ls /me" then press tab and it'll get "ls /media". You can keep doing that as much as you want, and if you double press tab it gives you all possibilities. Such as "ls /dev/hd[tab][tab]" would list "/dev/hda" "dev/hdb" and then put you back to "ls /dev/hd".

in the cli to create a directory you use mkdir /path/to/folder/you/want/to/make . Also in linux everything can be absolute or relative. So when you open up the terminal, you are at first in your "home" directory, from there the desktop is just "ls Desktop" and it'll list the desktop. :).

Now that you have create your folder you want, you can either type in the path manually into our command, or if you drag/drop the folder into the terminal it will automatically give you the path. Now you just had the /dvd.iso to the path and you are saving to your harddrive.


To answer the side question, you have 3 options. 1) Just use a usb stick and make a liveusb stick. 2) Use the ddrescue in cywgin. 3) Install Ubuntu on your harddrive, or install it inside of windows via wubi.

Option 1) is the best, option 2) well cywgin is easy to install and setup and use and all but it's a lot of baggage to install just for one program. Cywgin sets up a whole linux environment inside windows. (Of course you can uninstall it when you are done, but it's a lot of installing/downloading imo.)


Hopefully I didn't ramble on too much, I just felt like you were trying to understand what you were doing and didn't want just a click this, type that, guide. If you want a simple, click this, type that guide. I can do that too:thup:
 
Manual install worked just as you said.

I tried ddrescue /dev/dvd ~/Desktop/dvd.iso and it immediately started copying the data from the second DVD drive to desktop's dvd.iso.

Let's say I have a drive called C Drive, which shows up as named C Drive, how do I output to C:\dvd.iso



Also, how do I know what the estimated time left is? Time from last successful read is changing, do I interrupt after a while or does it stop by itself...
 
Last edited:
Manual install worked just as you said.

I tried ddrescue /dev/dvd ~/Desktop/dvd.iso and it immediately started copying the data from the second DVD drive to desktop's dvd.iso.

Let's say I have a drive called C Drive, which shows up as named C Drive, how do I output to C:\dvd.iso



Also, how do I know what the estimated time left is? Time from last successful read is changing, do I interrupt after a while or does it stop by itself...

First you need to mount the drive, simpliest way is to "double click" on it. Ubuntu will auto mount it.
Next just drag a folder or file or anything from it to the terminal and you'll get the path. For example, say you have c:\foo.txt, when you double click on c: and Ubuntu mount it, drag the file foo.txt to the cli. Now at the cli it will say something like /media/u91289u-asdjkahsdkjh-129asd/foo.txt . What you want is the "/media/u91289u-asdjkahsdkjh-129asd/".

you can then run
Code:
ddrescue /dev/dvd /media/u91289u-asdjkahsdkjh-129asd/dvd.iso /media/u91289u-asdjkahsdkjh-129asd/dvd.iso.log

That will recover it to the harddrive c:\dvd.iso in windows.

Now you've probably been running it for a while, so just let it go right now, and you can copy/move the iso over just by click and dragging. Or if you want to restart you can run the command again. Also idk how much room you have on the livecd, copying to the desktop probably wasn't a good idea, I forgot it was a livecd.

Also the log file is important, right now your log file is in the "home" folder of the livecd, if you are just copying the file over, make sure to copy the logfile too. The logfile tell's ddrescue were to pick back up from.

The estimated time will vary but it's cause it keeps chaning based on the progress it's making. It'll tell you when it's finished, but my rule of thumb is if for a long time 30 minutes-couple hours (depends on how patient you are) that it's not recoverying anything/0kb/s then I consider that probably as good as it's going to get.
 
It is only copying 1 GB of the ISO and not allowing the rest to be copied anywhere, claiming it is running out of space after it copies 1 GB to *any* of my drives. Both Copy and Cut give out the same error: Error splicing file: No space left on device

Is the location of the Desktop temporary? This is why I wanted it done on C Drive root...



 
Last edited:
Yes the desktop is temporary, delete the ISO on you desktop and then clear trash. Then try to ddrescue it to your hard drive like I discribed above. That should do it :)
 
You mean all this work for nothing :) It is not possible to copy a file larger than 1GB from temporary desktop to anywhere else?! Why?

:(
 
You mean all this work for nothing :) It is not possible to copy a file larger than 1GB from temporary desktop to anywhere else?! Why?

:(

You can try the mv function on the cli, just
Code:
 ~/Desktop/dvd.iso /media/hdddddddd/DVD.iso
(where hdddddd is the folder/uid of your hdd).

I'm not sure why its not letting you move it. It should be working fine :(
 
buntu@ubuntu:~$ ddrescue /dev/dvd /media/D Drive/1/dvd.iso /media/D Drive/1/dvd.iso.log
ddrescue: too many files

ubuntu@ubuntu:~$ ddrescue /dev/dvd /media/D Drive/dvd.iso
ddrescue: cannot open output file: Permission denied


Frikkin' Linux. :)
 
ubuntu@ubuntu:~$ ~/Desktop/dvd.iso /media/D Drive/DVD.iso
bash: /home/ubuntu/Desktop/dvd.iso: Permission denied



And this is why It's hard to give up Microsoft.
 
Ah ok, no everything is working fine but you've just missunderstood me. There is no drive c or drive d, its called something else in Ubuntu, Ubuntu uses uid's which most of us find dumb compared to just using the old partition scheme, but okay post the output of "ls /media". (I'm assuming you've already opened the drive d you want as I describbed before.)

The only problem you are having is trying to copy it to a folder that doesn't exist! :)

I appoligise because I wasn't clear enough with you on this
 
ubuntu@ubuntu:~$ ls /media
ls: reading directory /media: Input/output error
 
Last edited:
You said "drag/drop the folder into the terminal it will automatically give you the path."
The path was D Drive. That is the name of my drive.
 
I feel so dumb man, such a n00b mistake:bang head. Okay in linux, just as in windows and every other OS, you can't have spaces in a name on the command line. So "D Drive" should be "D\ Drive". The "\" is an escape character and basically says, "Hey the space after me is part of the name!".

Code:
ddrescue /dev/dvd /media/D\ Drive/1/dvd.iso /media/D\ Drive/1/dvd.iso.log

(note: you can also put paths in "", so "/media/D Drive/1/dvd.iso" also works, but quotes are bad practice in general.)
 
I rebooted into Windows so I suppose all is lost now.

Yes, I will try this again, perhaps in a few hours tonight or tomorrow but I also need to find the answer to this:
It is only copying 1 GB of the ISO and not allowing the rest to be copied anywhere, claiming it is running out of space after it copies 1 GB to *any* of my drives. Both Copy and Cut give out the same error: Error splicing file: No space left on device

Do you mind if I see ask in the Blue Room if others can take a look and see since this thing does have potential.


Also, what is it that prevents this entire procedure to be done in Windows?
 
Back