[opensuse] help with DD
Looking at https://bugzilla.novell.com/show_bug.cgi?id=328038#c3 and the DD man page I figured to see a hex dump of the dmraid data I should be able to do: dd if=/dev/hda of=somefile.bin seek=156301440 count=1 bs=512 However, doing that generates a somefile.bin file of purported size of 76319M (80,026,337,280), the size of the whole hard disk. What am I doing wrong? Is there a better way to examine the dmraid data that supposedly exists at that (virtual end of disk) location? -- "It yet remains a problem to be solved in human affairs, whether any free government can be permanent, where the public worship of God, and the support of religion, constitute no part of the policy or duty of the state in any assignable shape." Chief Justice Joseph Story Team OS/2 ** Reg. Linux User #211409 Felix Miata *** http://mrmazda.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On 2007/09/27 20:54 (GMT-0400) Felix Miata apparently typed:
Looking at https://bugzilla.novell.com/show_bug.cgi?id=328038#c3 and the DD man page I figured to see a hex dump of the dmraid data I should be able to do:
dd if=/dev/hda of=somefile.bin seek=156301440 count=1 bs=512
However, doing that generates a somefile.bin file of purported size of 76319M (80,026,337,280), the size of the whole hard disk. What am I doing wrong?
OK, I figured out to use skip in place of seek, but still I can't find the dmraid data. :-(
Is there a better way to examine the dmraid data that supposedly exists at that (virtual end of disk) location?
dmraid -D just displays an error message "invalid option combination with -D". :-( dmraid -s -s hpt37x_ccedfbhiib shows a size of 156301440, but gives no indication where this data that defines it to be that is located. :-( -- "It yet remains a problem to be solved in human affairs, whether any free government can be permanent, where the public worship of God, and the support of religion, constitute no part of the policy or duty of the state in any assignable shape." Chief Justice Joseph Story Team OS/2 ** Reg. Linux User #211409 Felix Miata *** http://mrmazda.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Thursday 27 September 2007 17:54, Felix Miata wrote:
Looking at https://bugzilla.novell.com/show_bug.cgi?id=328038#c3 and the DD man page I figured to see a hex dump of the dmraid data I should be able to do:
dd if=/dev/hda of=somefile.bin seek=156301440 count=1 bs=512
Dd is just a fancy copy program. It does not format the data it transfers. Look at the "od" command (literally, "octal dump"), which, despite its name, can produce decimal, octal and / or hexadecimal output of 8-, 16- and 32-bit entities from the data stream it reads.
...
Felix Miata *** http://mrmazda.no-ip.com/
Why won't you use your real name? Do you love cars more than your god? Randall Schulz -- "God is dead." —Friedrich Nietzsche "Good riddance" —Randall R. Schulz -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On 2007/09/27 20:22 (GMT-0700) Randall R Schulz apparently typed:
Felix Miata wrote:
Looking at https://bugzilla.novell.com/show_bug.cgi?id=328038#c3 and the DD man page I figured to see a hex dump of the dmraid data I should be able to do:
dd if=/dev/hda of=somefile.bin seek=156301440 count=1 bs=512
Dd is just a fancy copy program. It does not format the data it transfers.
The desired sectors are beyond the last full cylinder on disk. Not being within any filesystem, ordinary file viewers wouldn't be able to find them even if part of a file. As dmraid data, I didn't expect them to be within any file anyway. Formatting is a non-issue.
Look at the "od" command (literally, "octal dump"), which, despite its name, can produce decimal, octal and / or hexadecimal output of 8-, 16- and 32-bit entities from the data stream it reads.
mc is all the file viewer I need to find a string "hpt37", no special formatting required. ;-) -- "It yet remains a problem to be solved in human affairs, whether any free government can be permanent, where the public worship of God, and the support of religion, constitute no part of the policy or duty of the state in any assignable shape." Chief Justice Joseph Story Team OS/2 ** Reg. Linux User #211409 Felix Miata *** http://mrmazda.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Thursday 27 September 2007 20:44, Felix Miata wrote:
On 2007/09/27 20:22 (GMT-0700) Randall R Schulz apparently typed:
Felix Miata wrote:
Looking at https://bugzilla.novell.com/show_bug.cgi?id=328038#c3 and the DD man page I figured to see a hex dump of the dmraid data I should be able to do:
dd if=/dev/hda of=somefile.bin seek=156301440 count=1 bs=512
Dd is just a fancy copy program. It does not format the data it transfers.
The desired sectors are beyond the last full cylinder on disk. Not being within any filesystem, ordinary file viewers wouldn't be able to find them even if part of a file.
That is nonsensical. If the data in question is "part of a file" then by definition it's within a file system.
As dmraid data, I didn't expect them to be within any file anyway. Formatting is a non-issue.
You asked for a "hex dump." That's data formatting. Nonetheless, when using a raw device, such as /dev/hda, you are not subject to the boundaries of a file system or of the partioning of the device, only of its total capacity. If you use a partition, e.g., /dev/hda0, then you're only going to be able to see the contents within that partition, as it's defined in the drive's partition table. RRS -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On 2007/09/27 20:56 (GMT-0700) Randall R Schulz apparently typed:
Felix Miata wrote:
The desired sectors are beyond the last full cylinder on disk. Not being within any filesystem, ordinary file viewers wouldn't be able to find them even if part of a file.
That is nonsensical. If the data in question is "part of a file" then by definition it's within a file system.
Yup. Been an intense day. Time to wrap.
As dmraid data, I didn't expect them to be within any file anyway. Formatting is a non-issue.
You asked for a "hex dump." That's data formatting.
To me hex dump just means looking at a sector's contents, typically hex gobbledegook unless formatted for human consumption.
Nonetheless, when using a raw device, such as /dev/hda, you are not subject to the boundaries of a file system or of the partioning of the device, only of its total capacity.
That's why I was looking via dd. Anyway, I finally got enough hang of the dmraid command to get what I wanted. 'dmraid -r /dev/sda' told me the size that hpt37x considers the device to be, and the location of the dmraid data - 10th sector of the first disk track. 'dmraid -D -r /dev/sda' created three files, one of which was a copy of disk sector 10. 'dmraid -E -r /dev/sda' filled sector 10 with nulls. RAID gone. Time for sleep. Thanks for replies RRS. -- "It yet remains a problem to be solved in human affairs, whether any free government can be permanent, where the public worship of God, and the support of religion, constitute no part of the policy or duty of the state in any assignable shape." Chief Justice Joseph Story Team OS/2 ** Reg. Linux User #211409 Felix Miata *** http://mrmazda.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Randall R Schulz wrote:
Dd is just a fancy copy program. It does not format the data it transfers.
Actually, it does: ] DD(1) User Commands DD(1) ] ] ] NAME ] dd - convert and copy a file ^^^^^^^ ;-) -- Cheers, Carlos E. R. (from RC1) -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Friday 28 September 2007 03:08, Carlos E. R. wrote:
Randall R Schulz wrote:
Dd is just a fancy copy program. It does not format the data it transfers.
Actually, it does:
] DD(1) User Commands DD(1) ] ] ] NAME ] dd - convert and copy a file
^^^^^^^
Sort of, but it cannot do octal, decimal or hex conversion nor can it perform these non-existent conversions on multibyte items such as 16- or 32-bit quantities. The only two-byte operation it has is byte swapping. To wit: conv=CONVS convert the file as per the comma separated symbol list ... ascii from EBCDIC to ASCII ebcdic from ASCII to EBCDIC ibm from ASCII to alternate EBCDIC block pad newline-terminated records with spaces to cbs-size unblock replace trailing spaces in cbs-size records with newline lcase change upper case to lower case nocreat do not create the output file excl fail if the output file already exists notrunc do not truncate the output file ucase change lower case to upper case swab swap every pair of input bytes noerror continue after read errors sync pad every input block with NULs to ibs-size; when used with block or unblock, pad with spaces rather than NULs fdatasync physically write output file data before finishing fsync likewise, but also write metadata
;-)
-- Cheers, Carlos E. R.
Randall Schulz -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (3)
-
Carlos E. R.
-
Felix Miata
-
Randall R Schulz