string -- boot, configuration, and other system strings pseudo-device driver


The kernel tables driver is a character special pseudo-device providing access to various strings (such as console messages) and system tables (such as all processes). The tables are described in tab(HW). This manual page only describes the string devices shown in the following table:

Name in Minor number Access fixed size or
/dev/string (decimal) mtune(F) variable
boot 1 Read/write 512
pkg 2 Read-only 512
cfg 3 Read-only MAX_CFGSIZE
prf 4 Read-only PUTBUFSZ

 |Name in        |Minor number  |Access      |fixed size or     |
 |/dev/string    |(decimal)     |            |mtune(F) variable |
 |boot           |1             |Read/write  |512               |
 |pkg            |2             |Read-only   |512               |
 |cfg            |3             |Read-only   |MAX_CFGSIZE       |
 |prf            |4             |Read-only   |PUTBUFSZ          |
The bootstring /dev/string/boot is the name of the kernel booted and the arguments passed to that kernel by boot(HW). It is built from a combination of user input and /etc/default/boot.

The package string /dev/string/pkg lists what the btld(F) packages linked into the kernel at boot-time.

The configuration string /dev/string/cfg lists all initialized devices. It is built by concatenating all the output of printcfg(D3oddi) functions of configured drivers.

The putbuf buffer that can be viewed with the crash(ADM) utility contains the most recent messages printed by the kernel. This buffer is written to the /dev/string/prf file.

Reading the strings is non-blocking and non-destructive. Only the bootstring may be written to.

Only the following subset of the tab ioctl(S) commands are supported:

The current size of the string.

The maximum possible size of the string. Device drivers read the bootstring using the getbsflag(D3oddi), getbsvalue(D3oddi), and getbsword(D3oddi) functions.


The following codes may be returned in errno after an error:

The minor device number is not defined; an attempt was made to write to a string starting at a position beyond its maximum size or to read bytes starting at a position beyond the current end of the string.

An attempt was made to open a read-only device for writing; a tab ioctl command not supported by this string was attempted.

The string is corrupted or not present in this configuration of the system.

An unknown ioctl command was attempted.

A read or write specified an invalid buffer address or size.

The write would block and O_NONBLOCK is set for the file descriptor.

The write was interrupted by a signal.

The following error message may be displayed on the console. See messages(M) for general information about kernel error messages, including a list of generic device driver errors.

CONFIG: string: Configuration buffer full (MAX_CFGSIZE = n
exceeded) on dev major/minor
No more characters could be written to one of the bootstring, package string, or configuration string buffers.


It is not possible to shrink the size of a string.

The previous version of the string device differed in the following respects:


defines the ioctl commands listed in the ``Description''

directory containing the string device special files

directory containing the special files described in the tab(HW) manual page

internal tab data structures and configuration definitions

See also

boot(HW), btld(F), cmn_err(D3oddi), fcntl(S), getbsflag(D3oddi), getbsvalue(D3oddi), getbsword(D3oddi), ioctl(S), open(S), printcfg(D3oddi), read(S), signal(S), tab(HW), write(S)

Information about device driver interfaces and tools for driver development are available at the Consolidated Hardware Development (HDK) Web Page

© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003