2 .\" Copyright 1997 AT&T Copyright (c) 1997 Sun Microsystems, Inc. All Rights Reserved.
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH PUTDEV 8 "Apr 3, 1997"
8 putdev \- edits device table
12 \fBputdev\fR \fB-a\fR \fIalias\fR [\fIattribute\fR=\fIvalue\fR [...]]
17 \fBputdev\fR \fB-m\fR \fIdevice\fR \fIattribute\fR=\fIvalue\fR [\fIattribute\fR = \fIvalue\fR [...]]
22 \fBputdev\fR \fB-d\fR \fIdevice\fR [\fIattribute\fR [...]]
28 \fBputdev\fR adds a new device to the device table, modifies an existing device
29 description or removes a device entry from the table. The first synopsis is
30 used to add a device. The second synopsis is used to modify existing entries by
31 adding or changing attributes. If a specified attribute is not defined, this
32 option adds that attribute to the device definition. If a specified attribute
33 is already defined, it modifies the attribute definition. The third synopsis is
34 used to delete either an entire device entry or, if the attribute argument is
35 used, to delete an attribute assignment for a device.
39 The following options are supported:
46 Add a device to the device table using the specified attributes. The device
47 must be referenced by its \fBalias\fR.
56 Remove a device from the device table, when executed without the
57 \fIattributes\fR argument. Used with the \fIattribute\fR argument, it deletes
58 the given attribute specification for \fIdevice\fR from the table.
67 Modify a device entry in the device table. If an entry already exists, it adds
68 any specified attributes that are not defined. It also modifies any attributes
69 which already have a value with the value specified by this command.
75 The following operands are supported:
82 Designates the alias of the device to be added.
91 Designates a device attribute to be added, modified, or deleted. Can be any of
92 the device attributes described under \fBDEVICE\fR \fBATTRIBUTES\fR except
93 \fBalias\fR. This prevents an accidental modification or deletion of a device's
103 Designates the pathname or alias of the device whose attribute is to be added,
104 modified, or removed.
113 Designates the value to be assigned to a device's attribute.
116 .SH DEVICE ATTRIBUTES
119 The following list shows the standard device attributes, used by applications
120 such as \fBufsdump\fR(8) and \fBufsrestore\fR(8), which can be defined for a
121 device. You are not limited to this list, you can define any attribute you
129 The unique name by which a device is known. No two devices in the database may
130 share the same alias name. The name is limited in length to 14 characters and
131 should contain only alphanumeric characters and the following special
132 characters if they are escaped with a backslash: underscore ( _ ), dollar sign
133 ($), hyphen (\(mi), and period (.).
142 The pathname to the block special device node associated with the device, if
143 any. The associated major/minor combination should be unique within the
144 database and should match that associated with the \fBcdevice\fR field, if any.
145 (It is the administrator's responsibility to ensure that these
146 \fBmajor/minor\fR numbers are unique in the database.)
155 The capacity of the device or of the typical volume, if removable.
164 The pathname to the character special device node associated with the device,
165 if any. The associated major/minor combination should be unique within the
166 database and should match that associated with the \fBbdevice\fR field, if any.
167 (It is the administrator's responsibility to ensure that these
168 \fBmajor/minor\fR numbers are unique in the database.)
177 Used by the command specified in the \fBmkfscmd\fR attribute.
186 A description of any instance of a volume associated with this device (such as
193 \fB\fBdpartlist\fR\fR
196 The list of disk partitions associated with this device. Used only if
197 \fBtype=disk\fR. The list should contain device aliases, each of which must
198 have \fBtype=dpart\fR.
204 \fB\fBdparttype\fR\fR
207 The type of disk partition represented by this device. Used only if
208 \fBtype=dpart\fR. It should be either \fBfs\fR (for file system) or \fBdp\fR
209 (for data partition).
218 The command string that, when executed, erases the device.
227 The command string that, when executed, formats the device.
236 The file system name on the file system administered on this partition, as
237 supplied to the \fB/usr/sbin/labelit\fR command. This attribute is specified
238 only if \fBtype=dpart\fR and \fBdparttype=fs\fR.
247 Used by the command specified in the \fBmkfscmd\fR attribute.
256 The command string that, when executed, places a file system on a previously
266 The default mount point to use for the device. Used only if the device is
267 mountable. For disk partitions where \fBtype=dpart\fR and \fBdparttype=fs\fR,
268 this attribute should specify the location where the partition is normally
278 The number of blocks in the file system administered on this partition. Used
279 only if \fBtype=dpart\fR and \fBdparttype=fs\fR.
288 The number of inodes in the file system administered on this partition. Used
289 only if \fBtype=dpart\fR and \fBdparttype=fs\fR.
298 The name of the character special device node that allows access to the serial
299 device without rewinding when the device is closed.
308 Defines the pathname to an i-node describing the device (used for non-block or
309 character device pathnames, such as directories).
318 A token that represents inherent qualities of the device. Standard types
319 include: 9-track, ctape, disk, directory, diskette, dpart, and qtape.
328 The volume name on the file system administered on this partition, as supplied
329 to the \fB/usr/sbin/labelit\fR command. Used only if \fBtype=dpart\fR and
339 A text string used to describe any instance of a volume associated with this
340 device. This attribute should not be defined for devices which are not
347 The following exit values are returned:
354 Successful completion.
363 Command syntax was incorrect, an invalid option was used, or an internal error
373 The device table could not be opened for reading, or a new device table could
383 If executed with the \fB-a\fR option, indicates that an entry in the device
384 table with the alias \fBalias\fR already exits. If executed with the \fB-m\fR
385 or \fB-d\fR options, indicates that no entry exists for device \fIdevice\fR.
394 Indicates that \fB-d\fR was requested and one or more of the specified
395 attributes were not defined for the device.
402 \fB\fB/etc/device.tab\fR\fR
411 \fBdevattr\fR(8), \fBputdgrp\fR(8), \fBufsdump\fR(8), \fBufsrestore\fR(8),