hard drives come up "no partition table" and "in use by another program"
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
hard drives come up "no partition table" and "in use by another program"
I'm a newbie.
I'm trying to do a ddrescue but there terminology has lost me. I've been dealing with references to sdc, sdd which see to refer to my hard drives but I can't seem to go their and look at files. I can go to the hard drives as /dev/"FreeAgent Drive"/ but I don't see there the files that I thought I would.
I'm trying to sudo ddrescue /dev/sdd /dev/sdc ddlog
which seems to be working but I thought it would shoot it over to the /dev/"FreeAgent Drive"/ but I see nothing there.
Both SDD and SDC say they have "doesn't contain a valid partition table"
I know SDD has bad sectors, that's why I started this project. SDC was fine but I guess I've messed it up with ddrescue.
I did get ddrescue to run but where in the world is the result?
What is ddrescue? Is it a disk tool installed or you mean the GNU/Linux command "dd"? Sorry asking this, I'm a newbie like you.
Your post says: "I'm trying to sudo ddrescue /dev/sdd /dev/sdc ddlog
which seems to be working but I thought it would shoot it over to the /dev/"FreeAgent Drive"/ but I see nothing there."
Comment: {I hope I can be wrong for your own good}
By issuing your command: sudo ddrescue /dev/sdd /dev/sdc, if you mean under linux dd command, you have ordered to "copy the entire" disk /sdd, or at least the entire contents, to the /sdc disk and that's without specifying from what sector to begin and ironically WITHOUT SPECIFYING to what FILE on /sdc drive to save. That in spite, dd is very willing to do for you without question. But the danger to this is "what if your master boot record, partition table and files in /sdc were overwritten?"
Your post: "Both SDD and SDC say they have "doesn't contain a valid partition table"
Comment: The likelihood that they were corrupted after being overwritten. Your command dd started from the first sector of the disk, dd if=/dev/sdd; both the boot record and partition table are contained within the first 512 bytes of the disk; and wrote them beginning the first sector of /sdc <you did not specify a filename> thus you cannot see the recorded output as a file.
If done, go and see if /dev/sdc holds a file named MYREMEDY, if found you're lucky. Next step you may want to create this file into an ISO image by mkisofs command, mount loop it then you can access it as if as it is a separated but writable cd/dvd drive.
Read manual first:
$ man dd
$ man mkisofs
NOTE: Backup important files to external drives before playing with dd.
It's is my understanding that dd maybe dd_rescue, but that ddrescue is another variation of the same idea, of maybe gddrescue to confuse things.
I've spent 3 days on this simple problem.
It seems I just can't keep the 2 external drives mounted. Although at time one says it's mounted, in another place it says it's not mounted, and it never wants to show up mounted in gnome.
I give up, it's back to Windows tomorrow, so that I can get something done, instead of wasting my time on stupid things that are never explained properly.
ddrescue is a specialized version of dd designed for recovering bad filesystems. Unlike dd, it won't stop when it hits an error, and you can set it to retry for as long as you want it to. I believe dd_rescue is a different variation on the same concept.
In either program you have to be VERY careful when specifying the input and output devices or locations, because dd works at disk level and will happily overwrite anything with anything. It does look to me like you overwrote your /dev/sdc device with the contents of /dev/sdd. I'm afraid you probably destroyed your sdc device.
I'm sorry to hear that you want to give up, but please don't go blaming the problem on Linux here. There's a wealth of information out there if you just look for it (although I must admit that it's often confusing to sift through sometimes confusing and contradictory stuff). It was your own ignorance of the proper input and output names that caused the problem. If you were unsure about it, you could've asked us first. It does get easier with experience.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.