Hi All, I don''t know whether it''s the right place or not to discuss my doubts. I opened a device ( in raw mode) and I filled the entire space (from 1 block to last block) with some random data. While writing data, I am seeing the following warning messages in dmesg buffer. Jan 30 08:32:36 masthan scsi: [ID 107833 kern.warning] WARNING: /scsi_vhci/ssd at g600508b400102e640000b000081c0000 (ssd175): Jan 30 08:32:36 masthan Corrupt label; wrong magic number Any idea on this ? I thought my application is corrupting device structure (device structure has disk label, partition table..etc). In linux, the first block of the device has device structure. Do you know the blocks which has device structure in solaris ? Your help appreciated. Thanks & Regards Masthan --------------------------------- Get your own web address. Have a HUGE year through Yahoo! Small Business. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.opensolaris.org/pipermail/zfs-discuss/attachments/20070130/28663818/attachment.html>
dudekula mastan wrote:> I don''t know whether it''s the right place or not to discuss my doubts. > > I opened a device ( in raw mode) and I filled the entire space (from 1 > block to last block) with some random data. While writing data, I am > seeing the following warning messages in dmesg buffer. > > Jan 30 08:32:36 masthan scsi: [ID 107833 kern.warning] WARNING: > /scsi_vhci/ssd at g600508b400102e640000b000081c0000 (ssd175): > Jan 30 08:32:36 masthan Corrupt label; wrong magic number > Any idea on this ? > > I thought my application is corrupting device structure (device > structure has disk label, partition table..etc). > > In linux, the first block of the device has device structure. Do you > know the blocks which has device structure in solaris ?For Solaris labeled disks, block 0 contains the vtoc. If you overwrite block 0 with junk, then this is the error message you should see. -- richard
On Tue, Jan 30, 2007 at 09:24:26AM -0800, Richard Elling wrote:> > For Solaris labeled disks, block 0 contains the vtoc. If you overwrite > block 0 with junk, then this is the error message you should see. >Also note that for EFI labelled disks, Solaris will create a ''bare'' dev link that corresponds to the whole disk, label included. So if you write to /dev/rdsk/c0t0d0s0 on an EFI labelled disk, you won''t corrupt the label. But if you write to /dev/rdsk/c0t0d0, then you will be overwriting the label portion. Note that ZFS never writes to the first 8k of any device in case you are using disks with a Solaris VTOC. - Eric -- Eric Schrock, Solaris Kernel Development http://blogs.sun.com/eschrock