Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

diskinfo(1m) [hpux man page]

diskinfo(1M)															      diskinfo(1M)

NAME
diskinfo - describe characteristics of a disk device SYNOPSIS
character_devicefile DESCRIPTION
The command determines whether the character special file named by character_devicefile is associated with a SCSI or floppy disk drive. If so, summarizes the disk's characteristics. The command displays information about the following characteristics of disk drives: Vendor name Manufacturer of the drive (SCSI only) Product ID Product identification number or ASCII name Type Floppy or SCSI classification for the device Disk Size of disk specified in bytes Sector Specified as bytes per sector Both the size of disk and bytes per sector represent formatted media. Options The command recognizes the following options: Return the size of the disk in 1024-byte sectors. Display a verbose summary of all of the information available from the device. For floppy drives, this option has no effect. SCSI disk devices return the following: Vendor and product ID Device type Size (in bytes and in logical blocks) Bytes per sector Revision level SCSI conformance level data DIAGNOSTICS
Most of the diagnostic messages from are self-explanatory. However, one diagnostic message deserves further clarification. If the command fails to access the lunpath corresponding to a given special file, it displays the following diagnostics data, which contains device iden- tification and capability information: device type 127 (unknown); device is inaccessible iso ecma ansi rmb dtq resv rdf WARNINGS
As of release 10.20 of HP-UX, certain IDE devices, CD-ROMs in particular, will respond to inquiries as if they were SCSI devices. There- fore, the text "SCSI describe" in the output of the command does not definitively mean that the disk is in fact a SCSI drive (especially in the case of CD-ROMs). Use to check which type of INTERFACE node, SCSI or IDE, the device's hardware path lies beneath, in order to defini- tively determine a drive's interface. DEPENDENCIES
General The command supports floppy and HP SCSI disk devices. SCSI Devices The SCSI specification provides for a wide variety of device-dependent formats. For non-HP devices, may be unable to interpret all of the data returned by the device. Refer to the drive operating manual accompanying the unit for more information. AUTHOR
was developed by HP. SEE ALSO
ioscan(1M), lsdev(1M), disktab(4), disk(7). diskinfo(1M)

Check Out this Related Man Page

creatediskbyname(3x)													      creatediskbyname(3x)

Name
       creatediskbyname - get the disk description associated with a file name

Syntax
       #include <disktab.h>

       struct disktab *
       creatediskbyname(name)
       char *name;

Description
       The subroutine takes the name of the character device special file representing a disk device (for example, and returns a structure pointer
       describing its geometry information and the default disk partition tables.  It obtains this information by  polling  the  controlling  disk
       device driver.  The subroutine returns information only for MSCP and SCSI disks.

       The file has the following form:
       #define DISKTAB	      "/etc/disktab"

       struct  disktab {
	     char   *d_name;	      /* drive name */
	     char   *d_type;	      /* drive type */
	     int    d_secsize;	      /* sector size in bytes */
	     int    d_ntracks;	      /* # tracks/cylinder */
	     int    d_nsectors;       /* # sectors/track */
	     int    d_ncylinders;     /* # cylinders */
	     int    d_rpm;	      /* revolutions/minute */
	     struct partition {
		     int     p_size;   /* #sectors in partition */
		     short   p_bsize;  /* block size in bytes */
		     short   p_fsize;  /* frag size in bytes */
	       } d_partitions[8];
       };

       struct  disktab *getdiskbyname();
       struct  disktab *creatediskbyname();

Diagnostics
       Successful completion of the subroutine returns a pointer to a valid disktab structure.	Failure of this subroutine returns a null pointer.
       The subroutine fails if it cannot obtain the necessary information from the device driver or disktab file.

       A check is done to ensure that the disktab file exists and is readable.	This check ensures that the subroutine is not being called because
       the disktab file was accidentally removed.  If there is no disktab file, the subroutine fails.

       The subroutine also fails if it cannot determine disk geometry attributes by polling the driver.  This can occur if the disk is not an MSCP
       or SCSI disk.  In some cases where the disk consists of removable media and the media is not loaded, the driver will be unable to determine
       disk attributes.

Restrictions
       The subroutine returns information only for MSCP and SCSI disks.

See Also
       getdiskbyname(3x), ra(4), rz(4), disktab(5)

															      creatediskbyname(3x)
Man Page