- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: dd not working
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 08:28 AM
10-24-2008 08:28 AM
dd not working
I am trying to format few of my disks. Below is command and its output:
-------------------
# dd if=/dev/zero of=/dev/rdsk/c27t0d5 bs=128k
I/O error
8193+0 records in
8192+1 records out
# echo $?
2
-------------------------
# dd if=/dev/null of=/dev/rdsk/c27t0d5 bs=128k
0+0 records in
0+0 records out
# echo $?
0
-------------------------
# diskinfo /dev/rdsk/c27t0d5
SCSI describe of /dev/rdsk/c27t0d5:
vendor: HP
product id: HSV100
type: direct access
size: 1048576 Kbytes
bytes per sector: 512
--------------------------
And this is happening with all the disks I want to format.
I am using "bs" as the multiple of 'bytes per sector'.
My concern is has the 1st command did the formatting ??
Thanks in adv..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 08:56 AM
10-24-2008 08:56 AM
Re: dd not working
You would expect to write 8192 times at a size of 128*1024 bytes. That equals the 1048576 Kbytes of disk you have.
The 8192+1 means a last partial record was written.
Using '/dev/null' as input writes nothing as you saw, so this test is meaningless. You wrote zeros once accross your entire disk in your first attempt.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 09:00 AM
10-24-2008 09:00 AM
Re: dd not working
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 09:08 AM
10-24-2008 09:08 AM
Re: dd not working
When you specify "if=/dev/zero" you are copying data from a source that contains an infinite number of zero bytes. Your disk, however, is finite... so the copy operation must stop at some point.
Because the destination has completely filled up and the source still has data left (it is endless!), dd regards this as an error. In this situation, this error is completely expected and normal.
Your first dd command ended after writing 8192 * 128k bytes = 1048576 Kbytes, exactly the size of your disk. So you've completely overwritten your disk with zero bytes.
Your second dd command is trying to copy from /dev/null, the black hole that swallows everything and lets nothing out. Any attempt to read it will return only an indication "you've reached the end, there is nothing more". So there is nothing to copy. Your second dd command does not accomplish anything at all.
MK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 09:38 AM
10-24-2008 09:38 AM
Re: dd not working
Actually someone asked me to format the disks.
So I thought this would be the way to do this.
-Does formatting/erasing really have some meaning?
-Is there any relevant way also?(mediainit)....some threads says "mediainit does more harm than help"
-RK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 09:40 AM
10-24-2008 09:40 AM
Re: dd not working
Do a vgexport first!
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 09:46 AM
10-24-2008 09:46 AM
Re: dd not working
> Actually someone asked me to format the disks. So I thought this would be the way to do this.
This is usually loosely said as "format" but it really means just overwrite the disk with zeros or sometimes random bytes (with '/dev/urandom').
Be advised that if someone has the tools and the desire to read your data, writing over a disk even 10-15 times isn't going to stop reading "layers" down. If your objective is to prevent anyone from finding anything on your disk, a bath of acid plus a metal shredder work better.
That said, however, you effectively erased your disk insofar as your normal Unix tools won't find anything but zeros on it.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 09:51 AM
10-24-2008 09:51 AM
Re: dd not working
IMHO the EVA will use the free space for other data during leveling if you delete your vdisks.
If you find a way to restore the data anyway, please tell me how ...
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 10:29 AM
10-24-2008 10:29 AM
Re: dd not working
> Torsten: Shredder the EVA?
I actually had no idea *what* kind of disk or disk array the device sat in. My responses where directed solely to the question of 'dd'; the erasure of data; and what *can* be retrieved from physical media if you have the tools.
No, I think shredding the whole thing is overkill other than as an academic question.
;-)
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-24-2008 11:23 AM
10-24-2008 11:23 AM
Re: dd not working
I got solution here....vgexport and my "dd" query is also clear