view usr/src/man/man1m/putdgrp.1m @ 13659:57451298f940

1469 ttyc/ttyd should be an allowed console device Reviewed by: Milan Jurik <milan.jurik@xylab.cz> Reviewed by: Alexander Eremin <alexander.r.eremin@gmail.com> Approved by: Richard Lowe <richlowe@richlowe.net>
author Gary Mills <gary_mills@fastmail.fm>
date Thu, 05 Apr 2012 08:47:21 -0500
parents 5b2854ecc12d
children
line wrap: on
line source

'\" te
.\"  Copyright 1989 AT&T  Copyright (c) 1997 Sun Microsystems, Inc.  All Rights Reserved.
.\" 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.
.\" 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.
.\" 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]
.TH PUTDGRP 1M "Jul 5, 1990"
.SH NAME
putdgrp \- edits device group table
.SH SYNOPSIS
.LP
.nf
\fBputdgrp\fR [\fB-d\fR] \fIdgroup\fR [\fIdevice\fR]...
.fi

.SH DESCRIPTION
.sp
.LP
\fBputdgrp\fR modifies the device group table. It performs two kinds of
modification. It can modify the table  by creating a new device group or
removing a device group. It can also change group definitions by  adding or
removing a device from the group definition.
.sp
.LP
When the command is invoked with only a \fIdgroup\fR specification, the command
adds the specified group name to the device group table if it does not already
exist. If the \fB-d\fR option is also used with only the \fIdgroup\fR
specification, the command deletes the group from the table.
.sp
.LP
When the command is invoked with both a \fIdgroup\fR and a \fIdevice\fR
specification, it adds the given device name(s) to the group definition. When
invoked with both arguments and the \fB-d\fR option, the command deletes the
device name(s) from the group definition.
.sp
.LP
When the command is invoked with both a \fIdgroup\fR and a \fIdevice\fR
specification and the device group does not exist, it creates the group and
adds the specified devices to that new group.
.SH OPTIONS
.sp
.LP
The following options are supported:
.sp
.ne 2
.na
\fB\fB-d\fR\fR
.ad
.RS 6n
Delete the group or, if used with \fIdevice\fR, delete the device  from a group
definition.
.RE

.SH OPERANDS
.sp
.LP
The following operands are supported:
.sp
.ne 2
.na
\fB\fIdgroup\fR\fR
.ad
.RS 10n
Specify a device group name.
.RE

.sp
.ne 2
.na
\fB\fIdevice\fR\fR
.ad
.RS 10n
Specify the pathname or alias of the device that is to be added to, or deleted
from, the device group.
.RE

.SH EXIT STATUS
.sp
.LP
The following exit values are returned:
.sp
.ne 2
.na
\fB\fB0\fR\fR
.ad
.RS 5n
Successful completion.
.RE

.sp
.ne 2
.na
\fB\fB1\fR\fR
.ad
.RS 5n
Command syntax was incorrect, an invalid option was used,  or an internal error
occurred.
.RE

.sp
.ne 2
.na
\fB\fB2\fR\fR
.ad
.RS 5n
Device group table could not be opened for reading or a new device group table
could not be created.
.RE

.sp
.ne 2
.na
\fB\fB3\fR\fR
.ad
.RS 5n
If executed with the  \fB-d\fR option, indicates that an entry in the device
group table for the device group  \fIdgroup\fR does not exist and so cannot be
deleted. Otherwise, indicates that the  device group \fIdgroup\fR already
exists and cannot be added.
.RE

.sp
.ne 2
.na
\fB\fB4\fR\fR
.ad
.RS 5n
If executed with the  \fB-d\fR option, indicates that the device group
\fIdgroup\fR does not have as members one or more of the specified devices.
Otherwise, indicates that the device group  \fIdgroup\fR already has one or
more of the specified devices as members.
.RE

.SH EXAMPLES
.LP
\fBExample 1 \fRAdding a new device group.
.sp
.LP
The following example adds a new device group:

.sp
.in +2
.nf
example#  \fBputdgrp floppies\fR
.fi
.in -2
.sp

.LP
\fBExample 2 \fRAdding a device to a device group.
.sp
.LP
The following example adds a device to a device group:

.sp
.in +2
.nf
example#  \fBputdgrp floppies diskette2\fR
.fi
.in -2
.sp

.LP
\fBExample 3 \fRDeleting a device group.
.sp
.LP
The following example deletes a device group:

.sp
.in +2
.nf
example#  \fBputdgrp \fR\fB-d\fR\fB floppies\fR
.fi
.in -2
.sp

.LP
\fBExample 4 \fRDeleting a device from a device group.
.sp
.LP
The following example deletes a device from a device group:

.sp
.in +2
.nf
example#  \fBputdgrp \fR\fB-d\fR\fB floppies diskette2\fR
.fi
.in -2
.sp

.SH FILES
.sp
.ne 2
.na
\fB\fB/etc/dgroup.tab\fR\fR
.ad
.RS 19n

.RE

.SH SEE ALSO
.sp
.LP
\fBlistdgrp\fR(1M), \fBputdev\fR(1M), \fBattributes\fR(5)