<?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: disk problem in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602716#M648079</link>
    <description>Hello,&lt;BR /&gt;I already did a strings lvmtab and the disk on which I am doing a mediainit is not in the list.&lt;BR /&gt;I have tried moving the files using cp -r but,&lt;BR /&gt;I get read errors and the system just hangs.&lt;BR /&gt;At present,i have restored the old data and i have brought up the application.&lt;BR /&gt;The task now is doing a low level formatting of the disks and checking whether it can be used.i.e.using mediainit.&lt;BR /&gt;1.How can i use this with the above mentioned error?&lt;BR /&gt;2.How can I find the corrupt blocks in the hard disk?....so that I can use a pvcreate -b &lt;BLOCK number=""&gt; to wipe it out.&lt;BR /&gt;  is there any utility which can give me the corrupt blocks?&lt;BR /&gt;&lt;BR /&gt;3.Can I remove the hard disk attach it to a sun system and do a low level format?&lt;BR /&gt;&lt;BR /&gt;Your answers please.&lt;BR /&gt;&lt;/BLOCK&gt;</description>
    <pubDate>Sun, 28 Oct 2001 03:44:28 GMT</pubDate>
    <dc:creator>T G Manikandan</dc:creator>
    <dc:date>2001-10-28T03:44:28Z</dc:date>
    <item>
      <title>disk problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602712#M648075</link>
      <description>Hello,&lt;BR /&gt;One of my disks is giving read errors.&lt;BR /&gt;I have got another disk.&lt;BR /&gt;Can I do a &lt;BR /&gt;dd if=first disk of=second disk &lt;BR /&gt;to recover the data.&lt;BR /&gt;How can I use the mediainit command&lt;BR /&gt;when I give &lt;BR /&gt;mediainit -v /dev/rdsk/...&lt;BR /&gt;it gives&lt;BR /&gt;&lt;BR /&gt;mediainit: initialization process starting&lt;BR /&gt;mediainit: locking SCSI device&lt;BR /&gt;mediainit: scsi_mi: Target lock failed&lt;BR /&gt;mediainit: scsi_mi: LUN lock failed&lt;BR /&gt;scsi_mi: Unable to set EXCLUSIVE mode: Device busy&lt;BR /&gt;&lt;BR /&gt;please give your comments&lt;BR /&gt;</description>
      <pubDate>Sat, 27 Oct 2001 05:24:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602712#M648075</guid>
      <dc:creator>T G Manikandan</dc:creator>
      <dc:date>2001-10-27T05:24:56Z</dc:date>
    </item>
    <item>
      <title>Re: disk problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602713#M648076</link>
      <description>The problem with doing a dd from one disk to the other is that once dd hits the bad block, it won't be able to continue.  You might be better off doing a cp -R from one disk to the other, i.e. create a new VG with the new disk, recreate all the LVs from the old disk, mount the new filesystem and start copying.&lt;BR /&gt;&lt;BR /&gt;You can also try adding the new disk to the existing VG and then doing a pvmove to move all the extents to the new disk, one LV at a time.&lt;BR /&gt;&lt;BR /&gt;Finally ,why are doing a mediainit...this does a low level format of the disk and you will lose all your data on the disk.  Although you may want to use this command on the original disk after moving the data.  It will mark all the bad blocks on the disk and you might be able to re-use the disk.&lt;BR /&gt;&lt;BR /&gt;-Santosh</description>
      <pubDate>Sat, 27 Oct 2001 08:37:48 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602713#M648076</guid>
      <dc:creator>Santosh Nair_1</dc:creator>
      <dc:date>2001-10-27T08:37:48Z</dc:date>
    </item>
    <item>
      <title>Re: disk problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602714#M648077</link>
      <description>Santhosh,&lt;BR /&gt;First thanks.&lt;BR /&gt;I will explain the problem I am facing.&lt;BR /&gt;I have two disks that have become bad i.e.they have bad blocks.Inn this one is a corrupt disk with data in it and one is a free disk with corrupt blocks.&lt;BR /&gt;What I thought was to do a mediainit on one which is free and do a dd to transfer the data from the corrupt disk with data.&lt;BR /&gt;From your answer,I found that,dd cannot help me completing the task.Santhosh,&lt;BR /&gt;I do not have a proper backup.&lt;BR /&gt;Is there no other  way to retrieve data from the corrupt hard disk.&lt;BR /&gt;Can you explain me the way to move the PE contents.&lt;BR /&gt;So,I try doing a mediainit on the dataless bad hard disk?&lt;BR /&gt;I am getting the error as mentioned above.&lt;BR /&gt;Can anyone help me reg. this?&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;</description>
      <pubDate>Sat, 27 Oct 2001 11:20:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602714#M648077</guid>
      <dc:creator>T G Manikandan</dc:creator>
      <dc:date>2001-10-27T11:20:57Z</dc:date>
    </item>
    <item>
      <title>Re: disk problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602715#M648078</link>
      <description>From the errors that you're getting on the media init, it sounds like the disk is already in use.  Is it part of a VG already?  You can verify by doing a strings on /etc/lvmtab and grepping for the disk device, i.e.&lt;BR /&gt;&lt;BR /&gt;strings /etc/lvmtab|grep /dev/dsk/c?t?d?&lt;BR /&gt;&lt;BR /&gt;this should return nothing...otherwise the disk belongs to a VG.&lt;BR /&gt;&lt;BR /&gt;As for moving the data...like I said, you should be able to do a cp -R of all the files in the filesystem...once you hit the I/O error, just skip that file(s) and go on.  If you're lucky, none of the files will actually be on the bad block.&lt;BR /&gt;&lt;BR /&gt;As for the pvmove command, first you'd have to add the other disk to the same VG, then just do a:&lt;BR /&gt;&lt;BR /&gt;pvmove -n /dev/VGNAME/LVOL /dev/dsk/&lt;SRC dsk=""&gt; /dev/dsk/&lt;DEST dsk=""&gt;&lt;BR /&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;&lt;BR /&gt;-Santos&lt;/DEST&gt;&lt;/SRC&gt;</description>
      <pubDate>Sat, 27 Oct 2001 19:01:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602715#M648078</guid>
      <dc:creator>Santosh Nair_1</dc:creator>
      <dc:date>2001-10-27T19:01:27Z</dc:date>
    </item>
    <item>
      <title>Re: disk problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602716#M648079</link>
      <description>Hello,&lt;BR /&gt;I already did a strings lvmtab and the disk on which I am doing a mediainit is not in the list.&lt;BR /&gt;I have tried moving the files using cp -r but,&lt;BR /&gt;I get read errors and the system just hangs.&lt;BR /&gt;At present,i have restored the old data and i have brought up the application.&lt;BR /&gt;The task now is doing a low level formatting of the disks and checking whether it can be used.i.e.using mediainit.&lt;BR /&gt;1.How can i use this with the above mentioned error?&lt;BR /&gt;2.How can I find the corrupt blocks in the hard disk?....so that I can use a pvcreate -b &lt;BLOCK number=""&gt; to wipe it out.&lt;BR /&gt;  is there any utility which can give me the corrupt blocks?&lt;BR /&gt;&lt;BR /&gt;3.Can I remove the hard disk attach it to a sun system and do a low level format?&lt;BR /&gt;&lt;BR /&gt;Your answers please.&lt;BR /&gt;&lt;/BLOCK&gt;</description>
      <pubDate>Sun, 28 Oct 2001 03:44:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602716#M648079</guid>
      <dc:creator>T G Manikandan</dc:creator>
      <dc:date>2001-10-28T03:44:28Z</dc:date>
    </item>
    <item>
      <title>Re: disk problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602717#M648080</link>
      <description>Knowing which blocks on the disk are correct will not help at all. pvcreate erases all useful data on the disk and the bad block list simply tells the LVM software to not use those blocks when new files are created. It cannot remove bad blocks.  Those blocks are not readable and thus, the data is not readable, whether it is a file or a directory.&lt;BR /&gt;&lt;BR /&gt;If you are getting disk errors when you try to read the disk, copying it to another disk won't help very much.  As you've seen, trying to copy all the files will stop when you encounter the errors.&lt;BR /&gt;&lt;BR /&gt;About the only thing you can do is to make a complete list of every file, then use this list to perform the copy until it fails.&lt;BR /&gt;&lt;BR /&gt;Now take the list of files and trim all of the filenames that were correctly copied and remove them from the list plus the one that had an error, and start the copy again.  Repeat until all the files have been copied. You'll then have to deal with the lost files (which is why backups are perfromed regularly).</description>
      <pubDate>Mon, 29 Oct 2001 02:03:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/disk-problem/m-p/2602717#M648080</guid>
      <dc:creator>Bill Hassell</dc:creator>
      <dc:date>2001-10-29T02:03:09Z</dc:date>
    </item>
  </channel>
</rss>

