Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Access mis-aligned partition

Need help with peripherals or devices?
Post Reply
Message
Author
Wokka65
Posts: 4
Joined: 2017-07-09 14:49

Access mis-aligned partition

#1 Post by Wokka65 »

How do I access a mis-aligned partition (does not start on sector boundary) under Debian Squeeze?
The disk is a 4T drive, partitioned into 2 equal NTFS partitions under Windows XP (now placed in the Debian box).
I can access partition 1, but not partition 2 under Debian Squeeze.
I need to extract the data from the 2nd partition, preferably without removing the drive from the computer.
I do NOT wish to move the 2nd partition as this may result in loss or corruption of the data.

I have tried google searching and searching the "Hardware" and "System Configuration" sections, but can't locate what I'm after. :(
I'm sure the question will have been asked before, I just can't find the information.

Please do NOT give me any answers about how to format or align (move) the partition. This is NOT the quiery and is totally OFF TOPIC.
I do NOT wish to move the 2nd partition as this may result in loss or corruption of the data.

User avatar
Thorny
Posts: 542
Joined: 2011-02-27 13:40

Re: Access mis-aligned partition

#2 Post by Thorny »

Wokka65 wrote:How do I access a mis-aligned partition (does not start on sector boundary) under Debian Squeeze?
In the first place, Debian Squeeze has been totally out of support since the end of Feb. 2016. I hope you aren't using that system connected to the Internet.

In addition, that misaligned partition should not prevent you from accessing the data on it, but it might make writes run a little slower than if it was properly aligned for 4K physical sectors. I assume it was a 4K physical sector drive partitioned by XP.

Perhaps there are errors in the filesystem on that drive. I think it is usually best to correct errors in an NTFS filesystem from Windows.

User avatar
dasein
Posts: 7680
Joined: 2011-03-04 01:06
Location: Terra Incantationum

Re: Access mis-aligned partition

#3 Post by dasein »

I can access partition 1, but not partition 2 under Debian Squeeze.
"Can't access" is not diagnostically useful. If you expect help, you need to specify exactly what you tried and the verbatim text of any error messages.

A random thought about style: repetition and gratuitous capitalization do NOT improve communication, particularly in one's very first post.

(And a hearty +1 to Thorny's observations/suggestions, which, ironically enough, is exactly what you'd have learned from your purported Google search.)

Wokka65
Posts: 4
Joined: 2017-07-09 14:49

Re: Access mis-aligned partition

#4 Post by Wokka65 »

Thorny wrote: Debian Squeeze has been totally out of support since the end of Feb. 2016
I wasn't aware. I'll update the system. Thanks for the notification.
Thorny wrote:Perhaps there are errors in the filesystem on that drive.
Quite possibly. The previous system it was in (WXP64) lost power "quite a few" times without a proper shutdown.
This may also have damaged the drive. I am having an issue with it disappearing from the "fdisk -l" listing. I get an I/O error when trying to do a fdisk on it.
Thorny wrote:I assume it was a 4K physical sector drive partitioned by XP.
Correct assumption on both counts. Partitioned and formatted under WXP64, using a driver to allow access to the full drive under XP.

From what you say, it looks like I may just have to bite the bullet and put the drive into a Windoze system to retrieve the data :(

Wokka65
Posts: 4
Joined: 2017-07-09 14:49

Re: Access mis-aligned partition

#5 Post by Wokka65 »

dasein wrote:"Can't access" is not diagnostically useful.
My apologies on the vagueness. It's been several weeks since I tried to mount the partitions, and I don't remember the error message(s) when I tried to mount the partition.
dasein wrote:A random thought about style:
I apologise for any percieved rudeness. I didn't want any "trained monkey" replies about how to format or re-align the drive.
Thorny wrote:Debian Squeeze has been totally out of support since the end of Feb. 2016.
I kicked off a distro update last night. As at the time of writing it's been going for about 23 hours, including waiting for my input while I was at work during the day.
For the last couple of hours, it's sitting at "Checking init scripts", with apt-get using about 3% CPU (according to "top").
dasein wrote:a hearty +1 to Thorny's observations/suggestions
I will when I locate where to do that.
dasein wrote:have learned from your purported Google search
The search mostly turned up information about formatting history, formatting the current 4k sector drives and why it's important to be sector aligned (which Thorny reiterated). I basicly found the same information repeated, but nothing about actually accessing or mounting a mis-aligned drive or partition, or any problem mounting a mis-aligned partition.

Conclusion :
Thorny's suggestion of errors on (or with) the drive appears to be the correct diagnosis for my issue.
It's giving I/O errors and needs to be reset with either a reboot or power cycle to enable access again, but only the first partition will mount under Debian.

After the distro upgrade has completed, I'll move the drive to a Windoze system and extract everything when it's there.
Following the extraction, the drive will be reformatted sector aligned with a GPT partition table.

Thankyou both for your assistance and input.

User avatar
dasein
Posts: 7680
Joined: 2011-03-04 01:06
Location: Terra Incantationum

Re: Access mis-aligned partition

#6 Post by dasein »

Wokka65 wrote:It's giving I/O errors and needs to be reset with either a reboot or power cycle...
You are making things worse.

Step 1: Add

Code: Select all

kernel.sysrq=1
to the file /etc/sysctl.conf

Step 2: Reboot

Step 3: Google "magic sysreq keys"

Wokka65
Posts: 4
Joined: 2017-07-09 14:49

Re: Access mis-aligned partition

#7 Post by Wokka65 »

dasein wrote: Wokka65 wrote:
It's giving I/O errors and needs to be reset with either a reboot or power cycle...

You are making things worse.
My apologies for not making things clear.
The Debian system the drive's in at present is acting as a file server and this drive is one of the data drives. It has only been a data drive in any system.
I only shut down or reboot systems with a normal shutdown or reboot command. It is only if the system has crashed that I use the reset or power buttons.
The system the drive came out of was a WXP64 system which lost power too many times and WXP64 on the boot drive became corrupted. I was unable to resurect it as WXP64. Debian Live has enabled me to access to drives remaining in that system.

My power cycle procedure is : login as root ; shut the system down with either the "halt" or "shutdown" commands with the "power off' option ; count to 20 after the power goes off ; switch back on.
Reboot procedure is (obviously) : login as root and type "reboot", then twiddle thumbs while it shuts down and reboots.
Wokka65 wrote:For the last couple of hours, it's sitting at "Checking init scripts", with apt-get using about 3% CPU (according to "top").
Not moved on 2 hours later, but that's an issue for another section.

Post Reply