<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: using dd command to zero out disks in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211515#M168604</link>
    <description>thanks for the answers.  is there a way to sting several disks all togther?  can i create an input file as my of=?  i have over 100 disks i need to wipe.....&lt;BR /&gt;&lt;BR /&gt;thanks&lt;BR /&gt;</description>
    <pubDate>Sun, 07 Mar 2004 10:42:34 GMT</pubDate>
    <dc:creator>Mark Harshman_1</dc:creator>
    <dc:date>2004-03-07T10:42:34Z</dc:date>
    <item>
      <title>using dd command to zero out disks</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211512#M168601</link>
      <description>i want to zero out a number of disks on a device i am de-commissioning.  FOr audit reasons..we are suppose to "zero" out the data.  I was thinking of using the "dd" command...but am not sure of the a good syntax?  i could use some assistance here...thanks in advance.</description>
      <pubDate>Sun, 07 Mar 2004 09:19:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211512#M168601</guid>
      <dc:creator>Mark Harshman_1</dc:creator>
      <dc:date>2004-03-07T09:19:55Z</dc:date>
    </item>
    <item>
      <title>Re: using dd command to zero out disks</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211513#M168602</link>
      <description>dd if=/dev/null of=/dev/dsk/c0t0d0</description>
      <pubDate>Sun, 07 Mar 2004 09:43:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211513#M168602</guid>
      <dc:creator>Donny Jekels</dc:creator>
      <dc:date>2004-03-07T09:43:15Z</dc:date>
    </item>
    <item>
      <title>Re: using dd command to zero out disks</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211514#M168603</link>
      <description>&lt;BR /&gt;/dev/null will not do. &lt;BR /&gt;It returns 'eof' rightaway and your disk blocks will nto be overwritten.&lt;BR /&gt;&lt;BR /&gt;Use &lt;BR /&gt;&lt;BR /&gt;if=/dev/zero bs=1024k&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;[use search in the forum for more detailed discussion on device scrubbing, /dev/random, torches (the only real way to destroy data :-) and so on.]&lt;BR /&gt;&lt;BR /&gt;hth,&lt;BR /&gt;Hein.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Sun, 07 Mar 2004 10:08:59 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211514#M168603</guid>
      <dc:creator>Hein van den Heuvel</dc:creator>
      <dc:date>2004-03-07T10:08:59Z</dc:date>
    </item>
    <item>
      <title>Re: using dd command to zero out disks</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211515#M168604</link>
      <description>thanks for the answers.  is there a way to sting several disks all togther?  can i create an input file as my of=?  i have over 100 disks i need to wipe.....&lt;BR /&gt;&lt;BR /&gt;thanks&lt;BR /&gt;</description>
      <pubDate>Sun, 07 Mar 2004 10:42:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211515#M168604</guid>
      <dc:creator>Mark Harshman_1</dc:creator>
      <dc:date>2004-03-07T10:42:34Z</dc:date>
    </item>
    <item>
      <title>Re: using dd command to zero out disks</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211516#M168605</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;you can write the disk devices in a file and let a loop run over it.&lt;BR /&gt;&lt;BR /&gt;dskfile:&lt;BR /&gt;/dev/dsk/c0t0d0&lt;BR /&gt;/dev/dsk/c0t1d0&lt;BR /&gt;...&lt;BR /&gt;&lt;BR /&gt;while read DISK&lt;BR /&gt;do&lt;BR /&gt;dd if=/dev/zero of=${DISK}&lt;BR /&gt;done &amp;lt; dskfile&lt;BR /&gt;&lt;BR /&gt;Michael&lt;BR /&gt;</description>
      <pubDate>Sun, 07 Mar 2004 10:48:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211516#M168605</guid>
      <dc:creator>Michael Schulte zur Sur</dc:creator>
      <dc:date>2004-03-07T10:48:16Z</dc:date>
    </item>
    <item>
      <title>Re: using dd command to zero out disks</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211517#M168606</link>
      <description>With a hunderd disk, you want to write more than one at a time. Say 10 or so. So just toss the commands in script with &amp;amp; at the end of the line and/or grouped&lt;BR /&gt;(dd... ;  dd... ;dd...)&amp;amp;&lt;BR /&gt;Or just paste a bunch in a window.&lt;BR /&gt;&lt;BR /&gt;I'll include and attach here a perl script that is pretty close to your needs and which can run a selectable number of streams in parallel taking note of the stat time and results. For now it READS, to allow testing.&lt;BR /&gt;Once satisfied replace if with of and null with zero. No I did not write this just for you :-). I had something very similar handy.&lt;BR /&gt;Input param is a list of (raw) device names&lt;BR /&gt;&lt;BR /&gt;hth,&lt;BR /&gt;Hein.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#!/bin/perl&lt;BR /&gt;$file = shift (@ARGV);&lt;BR /&gt;$max_streams = shift (@ARGV);&lt;BR /&gt;&lt;BR /&gt;die "Must provide file" unless $file;&lt;BR /&gt;$max = ($max_streams)? int ($max_streams) : 10;&lt;BR /&gt;&lt;BR /&gt;open (FILE, $file) || die "Error open $file";&lt;BR /&gt;while (&lt;FILE&gt;) {&lt;BR /&gt;        if ($par++ &amp;gt;= $max) {&lt;BR /&gt;          $pid = wait();&lt;BR /&gt;          $par--;&lt;BR /&gt;          $s = 1;&lt;BR /&gt;          $s++ while (($stream[$s] != $pid) &amp;amp;&amp;amp; ($s &amp;lt;= $max) );&lt;BR /&gt;          die "Lost child process ?" if ($s &amp;gt; $max);&lt;BR /&gt;          } else {&lt;BR /&gt;          $s = $par;&lt;BR /&gt;          }&lt;BR /&gt;        $pid = fork();&lt;BR /&gt;        if ($pid) {&lt;BR /&gt;          $stream[$s] = $pid;&lt;BR /&gt;          } else {&lt;BR /&gt;          ($sec,$min,$hour) = localtime(time);&lt;BR /&gt;          $date = sprintf("%02d:%02d:%02d ",$hour,$min,$sec);&lt;BR /&gt;          open (LOG, "&amp;gt;&amp;gt;${file}_${s}.log" );&lt;BR /&gt;          print LOG $date, $_;&lt;BR /&gt;          close(LOG);&lt;BR /&gt;          chop ($_);&lt;BR /&gt;          exec ("dd of=/dev/null bs=128k count=100 if=$_ 2&amp;gt;&amp;gt; ${file}_${s}.log ")&lt;BR /&gt;          }&lt;BR /&gt;        }&lt;BR /&gt;close (FILE);&lt;BR /&gt;&lt;BR /&gt;wait() while (--$par &amp;gt; 0);&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/FILE&gt;</description>
      <pubDate>Sun, 07 Mar 2004 11:43:19 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211517#M168606</guid>
      <dc:creator>Hein van den Heuvel</dc:creator>
      <dc:date>2004-03-07T11:43:19Z</dc:date>
    </item>
    <item>
      <title>Re: using dd command to zero out disks</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211518#M168607</link>
      <description>Have you ever heard about the command "mediainit". This is the best way to erase data on you disk.&lt;BR /&gt;&lt;BR /&gt;Regards&lt;BR /&gt;   Roland</description>
      <pubDate>Mon, 08 Mar 2004 08:11:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/using-dd-command-to-zero-out-disks/m-p/3211518#M168607</guid>
      <dc:creator>RolandH</dc:creator>
      <dc:date>2004-03-08T08:11:24Z</dc:date>
    </item>
  </channel>
</rss>

