Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ getdiskbyname(3) — UTek W2.3

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

disktab(5)



GETDISKBYNAME(3)        COMMAND REFERENCE        GETDISKBYNAME(3)



NAME
     getdiskbyname - get disk description by its name

SYNOPSIS
     #include <disktab.h>

     struct disktab *
     getdiskbyname(name)
     char *name;

DESCRIPTION
     Getdiskbyname takes a disk name (for example, rm03) and
     returns a structure describing its geometry information and
     the standard disk partition tables. All information is
     obtained from the disktab(5) file.

     <disktab.h> has the following form:



     /*   @(#)disktab.h  4.2 (Berkeley) 3/6/83    */

     /*
      * Disk description table, see disktab(5)
      *
      * Modifications from 4.2bsd
      * Copyright (c) 1984, Tektronix Inc.
      * All Rights Reserved
      */

     #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();

CAVEATS
     This information should be obtained from the system for
     locally available disks (in particular, the disk partition



Printed 10/17/86                                                1





GETDISKBYNAME(3)        COMMAND REFERENCE        GETDISKBYNAME(3)



     tables).

SEE ALSO
     disktab(5).



















































Printed 10/17/86                                                2





































































%%index%%
na:72,84;
sy:156,521;
de:677,1467;
ca:2144,175;2463,15;
se:2478,132;
%%index%%000000000102

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026