Tru64 UNIX System Administration Part Number: AA-PS2RF-TE April 1999 Product Version: Tru64 UNIX Version 4.0F or higher This guide describes the tasks you perform in order to maintain a Compaq Tru64 UNIX (formerly DIGITAL UNIX) operating system running on an Alpha server or workstation. You use UNIX commands, scripts, and the SysMan graphical user interfaces to perform the system administration tasks described in this manual.
© Digital Equipment Corporation 1994,1995,1996,1999 All rights reserved. COMPAQ, the Compaq logo, and the Digital logo are registered in the U.S. Patent and Trademark Office.
Contents About This Guide 1 Overview of Tru64 UNIX System Administration 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 1.10 1.11 1.12 1.13 1.13.1 1.13.2 1.13.3 1.13.4 1.13.5 1.13.6 2 The Tru64 UNIX System Administrator . .. . .. . .. . .. . . .. . .. . .. . .. . Starting Up and Shutting Down the System . .. . .. . . .. . .. . .. . .. . Customizing the System Environment . . . .. . .. . .. . .. . . .. . .. . .. . .. . Configuring the Kernel . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .
2.2.2.1 2.2.2.1.1 2.2.2.1.2 2.2.2.1.3 2.2.3 3 2–7 2–7 2–8 2–8 2–8 Starting Up and Shutting Down the System 3.1 3.2 3.2.1 3.2.2 3.2.3 3.2.4 3.3 3.3.1 3.3.2 3.4 3.5 3.5.1 3.5.2 3.5.2.1 3.5.2.2 3.5.2.3 3.6 3.6.1 3.6.2 3.7 3.8 3.9 3.10 3.10.1 3.10.2 3.10.3 3.10.4 3.11 4 Using the Console Port . . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . Turning Off Console Log Messages . . .. . . .. . .. . .. . .. . Shutting Down the Remote System . .. . . .. . .. . .. . .. . Ending a Remote Session .. .
4.1.1.2 Specifying wait Run Levels .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 4.1.1.3 Specifying bootwait Run Levels . .. . .. . .. . .. . . .. . .. . .. . .. . 4.1.1.4 Specifying Console Run Levels . . .. . .. . .. . .. . . .. . .. . .. . .. . 4.1.1.5 Specifying Terminals and Terminal Run Levels . .. . .. . 4.1.1.6 Specifying Process Run Levels . . . .. . .. . .. . .. . . .. . .. . .. . .. . 4.1.1.7 Securing a Terminal Line . . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 4.1.
4.8 4.8.1 4.8.2 4.8.3 Customizing Power Management . . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . Display Monitors and DPMS . . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . Using the dxpower Utility’s Graphical User Interface . .. . Implementing Power Management from the Command Line . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 4.8.3.1 Changing Power Management Values .. . .. . . .. . .. . .. . .. . 4.8.3.
5.5.1 System Configuration Files . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 5.5.2 Extensions to the Target Configuration File .. . . .. . .. . .. . .. . 5.5.3 The param.c File . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 5.6 Configuration File Entries . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 5.6.1 Global Keywords . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 5.6.1.
5.6.6 5.6.7 5.6.7.1 5.6.7.2 5.6.7.3 5.6.7.4 5.6.7.5 5.6.7.6 5.6.7.7 5.6.7.8 5.6.7.9 5.6.7.10 6 5–55 5–56 5–56 5–56 5–56 5–57 5–57 5–58 5–58 5–59 5–59 5–59 Administering Devices with Dynamic Device Recognition 6.1 6.1.1 6.1.2 6.1.3 6.2 6.3 6.4 6.4.1 6.4.2 7 The makeoptions Keywords . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . The pseudo-device Keywords .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . Mandatory Definitions . . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . ..
7.5 7.6 7.7 7.7.1 7.7.2 7.7.3 7.7.3.1 7.7.3.2 7.7.4 7.8 7.9 7.10 8 7–20 7–20 7–21 7–21 7–23 7–24 7–25 7–25 7–26 7–27 7–29 7–31 Administering the Logical Storage Manager 8.1 8.2 8.2.1 8.2.2 8.2.3 8.2.4 8.2.5 8.2.6 8.3 8.4 8.4.1 8.4.2 8.4.3 8.5 8.6 8.6.1 8.6.2 8.6.3 8.6.4 8.6.5 8.6.6 9 Tuning File Systems . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . Maintaining Disks . .. . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. .
9.1.3 9.1.4 9.1.4.1 9.1.4.2 9.1.4.3 9.2 9.2.1 9.2.1.1 9.2.1.2 9.2.1.3 9.2.1.4 9.2.1.5 9.3 9.3.1 9.3.2 9.3.3 9.3.4 9.3.4.1 9.3.4.2 9.4 9.4.1 9.4.2 9.4.3 9.4.4 9.4.5 9.5 9.5.1 9.5.2 9.5.3 The Administrative Tools . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . UIDs and GIDs .. . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . Enabling or Disabling Extended UID and GID Support . .. . .. . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. .
10.5.1.2 Printer Type . . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 10.5.1.3 Printer Synonyms . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 10.5.1.4 Device Special File . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 10.5.1.5 Printer Accounting . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 10.5.1.6 Spooler Directory . . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 10.5.
11.2.1 Restrictions on Building a Standalone System Kernel on Tape .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 11.2.2 Using the btcreate Utility .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 11.2.2.1 Gathering Information . . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 11.2.2.2 Creating the SAS Kernel . . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 11.2.2.3 Disk Space Requirements . . .. . .. . . .. .
12.4.5 The acctcon1 Command .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 12.4.6 The acctcon2 Command .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 12.4.7 The prctmp Shell Script . . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 12.4.8 The lastlogin Shell Script .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 12.4.9 The last Command . . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 12.
13.2.3.1 The syslogd Daemon . . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 13.2.3.2 The binlogd Daemon . . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 13.2.4 Configuring the Kernel Binary Event Logger . . . .. . .. . .. . .. . 13.3 Recovering Event Logs After a System Crash .. . .. . . .. . .. . .. . .. . 13.4 Maintaining Log Files . . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . 13.5 Enhanced Core File Naming . . .. . .. . .. . .. . .
B.5 C B–9 Support of the CI and HSC Hardware C.1 C.2 C.3 C.4 C.5 D Device and Bus Maintenance Commands . . .. . .. . .. . . .. . .. . .. . .. . Hardware Setup, Restrictions, and Revision Levels .. . .. . .. . .. . Software Installation and Restrictions . . . .. . .. . .. . .. . . .. . .. . .. . .. . Configuration File Entries . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . Booting an HSC Controller or HSC Disk .. . .. . .. . .. . . .. . .. . .. . .. .
E.2.6 Inserting a PCMCIA Modem Card . . . .. . .. . .. . .. . . .. . .. . .. . .. . E.2.7 Removing a PCMCIA Modem Card . . .. . .. . .. . .. . . .. . .. . .. . .. . E.3 CalComp Graphics Tablet . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . E.3.1 Configuring the CalComp DrawingBoard III Tablet . .. . .. . E.3.2 Notes and Restrictions . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . E.4 AlphaServer GS140 Logical Partitions . . . .. . .. . .. . .. . . .. . .. . .
E.4.10 E.4.11 F Logical Partitioning Error Messages .. . .. . .. . .. . . .. . .. . .. . .. . Understanding Console Firmware Error or Informational Messages .. . . .. . .. . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . E–32 E–33 Using the System Exercise Tools F.1 F.1.1 F.1.2 F.1.3 F.1.4 F.1.5 F.1.6 F.1.7 F.1.8 System Exercisers . .. . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . Running System Exercisers . .. . .. . .. . . .. . ..
10–3 10–4 10–5 10–6 10–7 10–8 10–9 12–1 12–2 12–3 12–4 12–5 12–6 12–7 13–1 13–2 13–3 A–1 D–1 E–1 F–1 xviii Contents lpc Command Arguments . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . The printcap File Symbols . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . The printcap File Symbols, continued . . . .. . .. . .. . .. . . .. . .. . .. . .. . Flag Bits . . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. . .. . . .. . .. . .. . .. . . .. . .. . .. . .. .
About This Guide This manual describes the tasks you perform in order to administer the Compaq Tru64 UNIX (formerly DIGITAL UNIX) operating system running on a workstation or server. Audience This guide is intended for system administrators. Administrators should have knowledge of the operating system concepts and commands, and the hardware and software configuration.
• Bootable Tape. Since the 4.0B release, this topic has been updated with information on usage restrictions. Note that an updated version of NetWorker SingleServer Save and Restore is included with this release. See Chapter 11. • Telnet (TCP/IP) printing was added to the chapter on printing. The lprsetup program has been updated to support TruCluster software and Compaq Advanced Print Software (CAPS). Many new printer configuration files were added to support new printers. See Chapter 10.
• Support for the DVDFS file system has been implemented. Refer to new information in fstab(4), mount(8), and dvdfs(4). The maxtimo NFS parameter was added to the mount(8) reference page. • Support for the Fibre Channel interconnection is implemented and a technology overview is documented on the supplementary bookshelf of the documentation CD-ROM. A reference pages for the Emulex driver, emx(7) and emx_data.c(4) are new for this release.
Unchanged Information With the exception of minor documentation problem fixes, the information in the following chapters and appendixes have not changed since the last version of the manual: • Chapter 3, Starting Up and Shutting Down the System. • Chapter 12, Administering the System Accounting Services • Appendix B, SCSI/CAM Utility Program • Appendix C, Support of the CI and HSC Hardware Organizational Changes Chapter 1 has been expanded and several chapters have been renamed.
Chapter 11 Explains how to administer the archiving services of the operating system in order to backup and restore mass storage devices. Chapter 12 Explains how to administer the resource accounting services of the operating system. Chapter 13 Explains how to administer the error logging services of the operating system. Appendix A Contains information about device mnemonics. Appendix B Contains information about the SCSI/CAM Utility Program.
Audience Icon Color Code Device driver writers D Orange Reference page users R Green Some books in the documentation set help meet the needs of several audiences. For example, the information in some system books is also used by programmers. Keep this in mind when searching for information on specific topics. The Documentation Overview provides information on all of the books in the Tru64 UNIX documentation set.
The Tru64 UNIX Publications group cannot respond to system problems or technical support inquiries. Please address technical questions to your local system vendor or to the appropriate Compaq technical support office. Information provided with the software media explains how to send problem reports to Compaq. Conventions This guide uses the following conventions: % $ A percent sign represents the C shell system prompt. A dollar sign represents the system prompt for the Bourne, Korn, and POSIX shells.
that follows the slash. In examples, this key combination is enclosed in a box (for example, Ctrl/C ). Return xxvi About This Guide In an example, a key name enclosed in a box indicates that you press that key.
1 Overview of Tru64 UNIX System Administration This chapter surveys many of the tasks that are performed by Tru64 UNIX system administrators and points to the places in this manual and in other sources that describe these tasks. 1.1 The Tru64 UNIX System Administrator As administrator of a Tru64 UNIX operating system, you work in the following environment: • The hardware and software The hardware environment is a client Alpha workstation in a local area network being served by an Alpha server.
not you can use this interface for your administrative tasks. See Section 2.1 for more information. This manual does not include information about planning an operating system environment. For information about planning operating system environments, see your local Compaq representative. Information about administering network-related tasks is documented in the Tru64 UNIX Network Administration manual.
• Set your system to a different locale. The Tru64 UNIX operating system includes National Language Support (NLS) for multiple environments.
The administrative tasks are: • Compiling the DDR database • Converting the cam_data.c file to entries in the DDR database You use the ddr_config utility to accomplish both tasks. In addition, this chapter contains instructions for maintaining other terminals and mass storage devices on your system. The tasks involved include the following: • Making a new kernel (for disk and tape devices only) • Modifying the proper system files • Making devices known to your system 1.
1.9 Administering the Print Services Use the information in Chapter 10 to perform the following printer management tasks: • Add and remove printers and change the configuration of an existing printer • Show the status of a printer and control the printer; for example, delete print requests and enable and disable printers • Enable printer accounting 1.
• Make sure that the accounting files are a manageable size 1.12 Administering Events and Errors Chapter 13 contains information on system events and errors, describing system events, logging, and the components you employ to react to these events.
1.13.4 Using the uerf Error Logger The uerf error logging utility has been scheduled for retirement. Its use is described here for backward compatibility purposes. 1.13.5 Administering Specific Hardware Devices Appendix E Explains how to install specific hardware devices available on some processors. 1.13.6 Using System Exercisers Appendix F Describes tools you use to test system components when you see error messages that relate to a component (or if you observe unexpected behavior).
2 System Administration Tools and Methods This chapter explains the various tool options and administration methods available to you. Choices may be limited by the hardware, or by a particular task that you are performing. For example, you cannot use the graphical tools if you only have a character-cell terminal, or if the system is at the single-user prompt in standalone mode. Under these circumstances, you are limited to the command-line and to scripts that have character-cell interfaces.
2.1 CDE Graphical User Interface CDE is the preferred operating system interface and the SysMan graphical user interface becomes the preferred system administration tool on systems that can display the CDE. A command line interface to these tools is included for users of systems that have only character-cell displays or for users who prefer to use a command line interface to the CDE in a terminal window.
– – System Information with dxsysinfo Monitoring and Tuning Applications While a system is running, you can use these applications to monitor and tune its resources: – – Kernel Tuner with dxkerneltuner – Process Tuner with dxproctuner Display Window Help Application You can use the dxdw application to access the CDE commands from the graphical user interface. 2.1.
• BIND Configuration • NFS Configuration • Mail Configuration • Account Manager The following applications have a question and answer interface invoked using the command-line argument -ui menu. The application prompts you interactively. • Network Configuration • BIND Configuration • NFS Configuration • Printer Configuration The menu interface for Mail Configuration is called mailsetup. 2.2 Remote System Administration You can manage remote systems through a modem connection.
should use the ECU to complete any environment configuration before setting up and using a modem as a console device. 2.2.1 Setting Up a Console Port The following sections provide an overview of the steps required to set up a serial line console port and set up the remote modem for dial-in. It is assumed that your local (dial-out) modem is already installed and configured for use. 2.2.1.1 Connecting the Modem to COMM1 The CONSOLE environment variable on the remote system should be set to serial.
Where n = 0, 1, or 2 The syntax for modifying the timer via the sysconfig command is as follows: # sysconfig -r ace dcd_timer=n Where n = 0, 1, or 2 Note that by modifying the value with the sysconfig command, the setting is lost when the system is rebooted. To preserve the setting across reboots, edit the /etc/sysconfigtab file. 2.2.1.
terminal or X-terminal window or you can use a PC-based terminal emulator. For example, use the tip command as follows: # tip [telephone number] # tip cons Where telephone_number is the telephone number of the remote system, including any prefixes for outside lines and long-distance codes. The second line is an example of an entry in the /etc/remote file, which you can use to specify details of remote systems and tip settings.
See the syslog(1) reference page. 2.2.2.1.2 Shutting Down the Remote System When you shut down the remote system, the modem connection will be dropped. To avoid this, use the following command before you shut down the system: # stty -hupcl See the stty(1) reference page for more information. When the shutdown is complete, you will still have access to the console prompt. 2.2.2.1.
• The connection is dropped when the remote system is shut down via the shutdown command. The stty attribute hupcl is at the default setting.
3 Starting Up and Shutting Down the System This chapter describes procedures for starting up and shutting down the operating system and includes a discussion of: • Boot operation • Different startup states and the corresponding boot preparation • Run levels • Resolving problems that occur during the boot operation Refer to the Installation Guide for information about installing the system and performing the initial boot operation.
on an automatic boot. With an automatic boot, the system begins the initialization process and continues until completion or failure. Manual intervention may be required if the automatic boot fails for some reason, for example, if the fsck command fails. In a manual boot, the system controls the initial operation, turns control of the procedure over to you, then reinstates control to complete the operation. When you boot the system to single-user mode, you are relying on a manual boot.
loading, and so on. At the conclusion of the main initialization tasks (process 0), init (process 1) starts an additional set of tasks that includes reading the /etc/inittab file, acting on instructions found there, and executing the relevant run command scripts.
If you are preparing to reboot your system from a powered-down state, follow these steps: 1. Confirm that the hardware and all peripheral devices are connected. Refer to the operator’s guide for your hardware for information and instructions for interpreting diagnostic output. 2. Power up the hardware and peripheral devices. Remember to power up all devices that you powered down earlier.
2. • If you have tasks you need to accomplish and you want the system to restrict access to all users but root, plan to boot to single-user mode. • If you do not require single-user access and you want the system to initialize full functionality, plan to boot to one of the multiuser modes: multiuser without networking or multiuser with networking. Enter the boot command that corresponds to the desired startup mode. Refer to Section 3.3 for the commands and procedures required to boot your system. 3.2.
4. 5. • In the unlikely event that the diagnostic test indicates hardware failure, contact your Compaq field representative. Because hardware damage is a serious problem, do not continue or try to bypass the defective hardware. • If you have enabled your system to boot automatically, press the halt button to display the console prompt. Refer to the hardware operator’s guide for the location of the halt button on your system.
Table 3–1: Console Environment Variables Variable Action boot_reset When set to on, resets the hardware on boot boot_osflags A combination of flags used to control the boot loader and kernel bootdef_dev Identifies the boot device boot_file Identifies the kernel to boot (on DEC 4000 and DEC 7000 processors) cpu_enable Selectively enables particular processors from the console To prepare the hardware: 1.
Table 3–2: Options to the boot_osflags Variable (cont.) Option Action d Use full crash dumps. (By default, partial dumps are used.) i Prompt for the kernel and special arguments. (By default, no questions are asked.) The options are concatenated into the boot_osflags variable to achieve the desired effect.
For example, to boot the system off of disk dka0, enter: >>> set bootdef_dev dka000 To boot the system from the first disk on the PMAZB or PMAZC option card in TURBOchannel slot 1, enter the following command. Note that the double quotes ( ") are necessary for the console to understand where it is booting from. >>> set bootdef_dev "1/dka000" d. You have the option of booting from an alternate kernel.
3.3.2 Overriding Boot Commands The previous section described how to set the boot commands. This section describes how to override those commands. • Overriding bootdef_dev To override the bootdef_dev variable, supply the desired boot device as an argument to the boot command.
the init process starts, it reads the inittab file and executes the relevant run command scripts. The scripts, in turn, define which processes are to run (and which processes are to be killed if the system is changing from one level to another) at a specific run level. Refer to the init(8) and inittab(4) reference pages and to Chapter 4 for information about reading and modifying the inittab file. 3.
on these entries before it continues with the normal processing of the inittab file. The init process next scans the file for other entries with processes that are allowed to run at the new run level, and then acts on these entries. 3.5.2 Changing Run Levels from Multiuser Mode When the system is running at one of the two multiuser run levels, you can use the init command to change run levels.
To return to multiuser mode from single-user mode, use Ctrl/d or enter exit at the prompt. This causes the init command as process 1 to prompt you for the run level. In response to the prompt, enter 2 to return to multiuser mode without networking daemons activated, or enter 3 to return to multiuser mode with networking daemons activated. Alternatively, you can reboot the system by using one of the following commands: # /usr/sbin/shutdown -r now # /sbin/reboot 3.5.2.
additional I/O capabilities will be required to more efficiently utilize these extra computes. 3.6.1 Adding CPUs to an Existing System At boot time, the system determines the number of CPUs available. Adding computing power to your multiprocessing systems is as simple as installing the processor board and rebooting the system.
. Serves as a delimiter ss Designates the seconds as a 2-digit integer (this field is optional) To set the date to 09:34:00 AM Jan 7, 2000 using the mmddHHMM[[cc]yy][.ss] format: # date # date # date 010709342000 0107093400.00 010709342000.00 _______________________ Note _______________________ If you are changing the year, the system disk must be updated with the new year information. In single-user mode, enter the mount −u / command after you enter a date containing a new year.
– A disk or file system is corrupt If a disk or file system is corrupt, run the fsck command on the file system. The fsck command checks and repairs UNIX File Systems (UFS). If fsck finds something wrong, it prompts you for an action to take. Use extreme care under these circumstances so that you do not inadvertently overwrite or remove any files. Refer to the fsck(8) reference page for more information. If you have an Advanced File System (AdvFS), disk corruption is very unlikely.
In each of these and similar situations a variety of options are available to you. Regardless of how you decide to resolve the situation, your first step is to initiate a controlled shutdown of the system. There are practical and reasonable ways to shut down your system from single-user mode or multiuser mode. A system that has panicked or crashed presents you with a different set of circumstances than a system that has shut down in an orderly fashion. However, this chapter discusses orderly shutdowns only.
# shutdown +10 Maintenance shutdown The system begins to notify users of the impending shutdown. Next, it disables logins, stops accounting and error logging, stops all remaining processes, logs the shutdown in the log file, and sends the init program a signal that causes the system to transition to single-user mode. When the system’s shutdown completion message appears, the shutdown is complete. You can access the system through the console to perform the desired administrative tasks.
In this case, the system begins to notify users of the impending shutdown, disables logins, and proceeds with the standard shutdown activities. When it completes these activities, shutdown automatically starts the reboot operation, which involves running fsck for a consistency check on all mounted file systems. If problems are not encountered, the system reboots to multiuser mode.
# sync # sync # halt In response to the halt command, the program logs the shutdown in the log file, kills all running processes, executes the sync system call and waits for all information to be written to disk, then halts the systems. Note that entering the sync command at least twice ensures that all data in memory is safely written to disk. Refer to the halt(8) reference page for a description of the command and its flags.
4 Customizing the System Environment This chapter describes how you can customize your system environment in the following areas: • System initialization files, which you use to initialize and control the system’s run levels • National language directories, which you use to supply support for language-specific and country-specific programs • Internationalization features, which you tailor to support programmers and users developing and running programs for international audiences • System time zone d
system environment. To understand and utilize available functionality, you should familiarize yourself with the init program and the specific files and commands associated with the program. Refer to the init(8) reference page for a description of the program and its behavior. Before you make any changes to the system initialization files, you should examine the default setup, evaluate the needs of your system, and make a copy of the entire set of default files.
/sbin/rcn The run command script that corresponds to a particular run level. There are three /sbin/rcn scripts available: /sbin/rc0, /sbin/rc2, and /sbin/rc3. Section 4.1.2.2, Section 4.1.2.3, and Section 4.1.2.4 describe the contents and use of these scripts. /etc/rc.config A file that contains run-time configuration variables. Scripts in the /sbin/init.d directory use these variables to configure various subsystems (for example, NFS or NTP).
/usr/sys/conf/NAME The text file that defines the components that the system builds into your configuration. The NAME variable usually specifies the system name. Chapter 5 describes this file. /usr/sys/conf/NAME .list The optional configuration file that stores information about the layered product subsystems and is used to automatically configure static subsystems. The NAME variable usually specifies the system name. Chapter 5 describes this file. /usr/sys/conf/param.
The inittab file is composed of an unlimited number of lines, each with four fields; each field is separated by a colon. The fields and syntax for entries in the inittab file are as follows: Identifier: Runlevel: Action: Command Identifier This 14-character field uniquely identifies an object entry. Runlevel This 20-character field defines the run levels in which the object entry is to be processed. The Runlevel variable corresponds to a configuration of processes in a system.
respawn If the process does not exist or dies, init starts it. If the process currently exists, init does nothing and continues scanning the inittab file. wait When init enters a run level that matches the run level of the entry, it starts the process and waits for its termination. As long as init continues in this run level, it does not act on subsequent reads of the entry in the inittab file. bootwait When init first executes and reads the inittab file, it processes this line entry.
run level for initdefault is set to 3, which is the multiuser with network services mode: is:3:initdefault: 4.1.1.2 Specifying wait Run Levels The init program looks in the inittab file for the wait entries. In the previous inittab file example, the following line contains a wait entry: fs:23:wait:/sbin/bcheckrc < /dev/console > /dev/console 2>&1 In this case, the init program invokes the /sbin/bcheckrc script for the fs entry. Processes associated with this entry execute at run levels 2 and 3.
3, and 4. The respawn keyword tells init to re-create the getty process if the active process terminates. If the process is active, init does not respawn the process; if it terminates, the process is re-created. _______________________ Note _______________________ In general, you should not modify the system console entry in the inittab file unless you want to limit the system console’s access to different run levels.
4.1.1.6 Specifying Process Run Levels Specific entries in the inittab file define the run command scripts that are to be executed when the system enters or changes to a particular run level.
cron enlogin gateway inet kmod lat loader lpd nfs nfsmount nis paging recpasswd rmtmpfiles route rwho settime sia snmpd startlmf xdm xntpd 4.1.2.2 The rc0.d Directory and rc0 Run Command Script The /sbin/rc0 script contains run commands that enable a smooth shutdown and bring the system to either a halt state or single-user mode.
See the rc0(8) reference page for additional information. 4.1.2.3 The rc2.d Directory and rc2 Run Command Script The /sbin/rc2 script contains run commands that enable initialization of the system to a nonnetworked multiuser state, run level 2. As described previously, the inittab file contains entries that the init program reads and acts on when the system is booting or changing its state to run level 2.
Refer to the rc2(8) reference page for more information. 4.1.2.4 The rc3.d Directory and rc3 Run Command Script The /sbin/rc3 script contains run commands that enable initialization of the system to a networked multiuser state, run level 3. As described previously, the inittab file contains entries that the init program reads and acts on when the system is booting or changing its state to run level 3.
the letter "K" run only when the system is changing run levels from a higher to a lower level. Commands that begin with the letter "S" run in all cases. Usually, only commands that begin with the letter "S" are placed in the rc3.d directory. By default, run level 3 is the highest run level. The numbering of commands in the /sbin/rc3.d directory is important since the numbers are sorted and the commands are run in ascending order. Refer to the rc3(8) reference page for more information. 4.1.
To use the crontab command, you must be the user that matches the file name you want to act upon. For example, if you are user adm and you run the crontab command, the action is performed on the /var/spool/cron/crontabs/adm file. To submit commands to the cron daemon to be run under adm authority: 1. Become user adm. 2. Enter the crontab command with the −l option to copy the /usr/spool/cron/crontabs/adm file to a temporary file in your home directory. % crontab −l > temp_adm 3.
Table 4–1 lists the locales moved to the /usr/lib/nls/loc directory when you install the optional Single-Byte European Locales subset. Additional locales are installed by language variant subsets with special licensing requirements. Table 4–1: Locale Support Files Language/Territory Locale Filename Danish-Denmark da_DK.ISO8859-1 Dutch-Netherlands nl_NL.ISO8859-1 Dutch_Belgium nl_BE.ISO8859-1 English_U.K en_GB.ISO8859-1 English_U.S.A. en_US.ISO8859-1 Finnish-Finland fi_FI.
in Table 4–1. These tables and variants are provided only to ensure system compatibility for old programs and should not be used by new applications. 4.2.1 Setting a Locale The default system-wide locale for internationalization is the C locale. The default system-wide locale is the one that the setlocale function uses when a user does not set the internationalization environment variables, such as LANG, LC_COLLATE, and so on.
Note that setting the LANG environment variable on the command line sets the locale for the current process only. In most cases, assigning a value to the LANG environment variable is the only thing you need to do to set the locale.
Table 4–2: Locale Environment Variables (cont.) Environment Variable Description LC_TIME Specifies the date and time format. LC_MESSAGES Specifies the language in which system messages will appear. In addition, specifies the strings that indicate ‘‘yes’’ and ‘‘no’’ in yes/no prompts. As with the LANG environment variable, you can assign all of the category variables locale names. For example, suppose that your company’s main language is Spanish.
then use the grep command for something in foo. The grep command will use Spanish rules on the German data in the file. 4.2.4 Setting Environment Variables for Message Catalogs and Locales To define the location of message catalogs, set the NLSPATH environment variable. The default path is as follows: NLSPATH=/usr/lib/nls/msg/%L/%N: In this example, %L specifies the current locale name, and %N specifies the value of name of the message catalog.
4.4 Customizing Your Time Zone Information about configuring your system’s time zone is in Chapter 5. This section describes how to administer local and worldwide time zone information on your system. Time zone information is stored in files in the /etc/zoneinfo directory. The /etc/zoneinfo/localtime file is linked to a file in the /etc/zoneinfo directory and specifies the local time zone.
The dst variable is not specified, daylight savings time time does not apply. You can specify any uppercase and lowercase letters. A leading colon (:), comma (,), hyphen (-), plus sign(+), and ASCII NUL are not allowed. offset Specifies the value to be added to the local time to arrive at GMT.
syntax: hh [ :mm [ :ss ]] The default is 02:00:00. The following example of the TZ environment variable specification specifies: • EST (eastern standard time) specifies the standard time, which is 5 hours behind GMT. • EDT (eastern daylight time) specifies the daylight savings time, which is 4 hours behind GMT. • EDT starts on the first Sunday in April and ends on the last Sunday in October; the change to and from daylight savings time occurs at 2:00, which is the default time. EST5EDT4,M4.1.0,M10.5.
4.5 Customizing System Security The system security tasks of the administrator range from the protection of physical components of the system and its environment to the implementation of an organization’s security policies. Two manuals in the Tru64 UNIX documentation set describe security-related tasks. Refer to the following documents for information about administering local system security: • The Technical Overview briefly describes the security components of the Tru64 UNIX operating system.
The MPH process is automatic, requiring no human intervention and no training. The installation time is approximately 10 minutes. This software will not impact or degrade your system’s performance. MPH runs as a background task, using very negligible CPU resources and is invisible to the user. The disk space required for the collected data and the application is approximately 300 blocks per system. This could be slightly higher in the case of a high number of errors.
be kept for high-speed playback or compression into charts, showing resource usage trends. The Performance Monitor is an optional subset in the Tru64 UNIX software kit. For information about establishing and using the Performance Monitor, see the Performance Monitor User’s Guide. 4.6.3 Using Performance Manager Performance Manager is a real-time performance monitor that allows users to detect and correct performance problems.
4.6.4 Using Graphical Tools Several graphical tools are provided for fast checking of one or more aspects of system performance. These are X-based utilities that will display under any X-compliant windowing interface. Under the Common Desktop Environment, (CDE) the interfaces are organized under the Tool Drawer icon, on the CDE front panel.
4.7 Administering CPU Resources Using the Class Scheduler The Class Scheduler provides you with a method of controlling the execution of tasks or applications by restricting the length of time that they can access the processor (CPU). For example, daemons such as the print spooler can be given less access time. The CPU will then have more time available to perform other tasks.
The following reference pages contain detailed information on using the Class Scheduler commands and options: • class_scheduling(4) • class_admin(8) • runclass(1) • classcntl(2) Enter the following command to obtain on-line help for class_admin: # /usr/sbin/class_admin help 4.7.1 Class Scheduler Overview To use the class scheduler, you must first create a database file and populate the file with one or more classes.
• Execute class scheduling commands from within scripts using the command line version of class_admin. 4.7.2 Utilities Related to Class Scheduling The following utilities are also available for use when monitoring and tuning processes: • The nice and renice commands • The iostat and vmstat commands • The Process Tuner (dxproctuner) graphical interface, available from the CDE MonitoringTuning folder in the Application Manager System_Admin.
A database must be configured before you can enable class scheduling with the enable command. If a database does not exist when you enter the class_admin command, the command will invoke an interactive session and prompt you to configure a database. If the class_admin command is invoked by a script, a database is configured automatically, using the system defaults. The following example shows an interactive configuration session using class_admin.
In the example, a default class was created and all current processes were assigned to that class. Class scheduling will be enforced even when the CPU is idle and class usage will be reset every five seconds. To review the current configuration, use the following command: class> show Configuration: -Processes not explicitly defined in the database are class scheduled. -If the processor has some idle time, class scheduled processes are not allowed to exceed their cpu percentage.
4.7.5.1 Creating a Class To create a class, either use the command mode or enter an interactive session as follows: # class_admin class> create high_users 50 The command mode version is entered as follows: # class_admin create batch_jobs 10 batch_jobs created at 10% cpu usage changes saved The first command creates a class named high_users and assigns a CPU usage restriction of 50 percent. The second command creates a class named batch_jobs and assigns a CPU usage restriction of 10 percent.
Individual processes can be added using process identifiers obtained from system files or by using a command such as ps. With the ps command, you can determine the values of PID, PGID and SESS for processes. Using the following command, you can display the PID for every process running on the system: # /sbin/ps aj USER PID PPID PGID wal 5176 5162 5176 root 12603 5176 12603 SESS JOBC S 2908 1 S 2908 1 R TTY ttyp1 + ttyp1 TIME COMMAND 0:01.30 -sh (csh) 0:00.
# class_admin disable Class scheduling disabled. 4.7.5.4 Adding Members to a Class To add a process to a class, you use the add command as shown in the following interactive mode example: class> add batch_jobs uid 234 457 235 Note that you must use one of the unique identifiers previously specified and you cannot add the same identifier to a class more than once.
load new database anyway (destroys changes)? (yes/no) [yes]:yes database database_performance loaded In this example the presence of unsaved modifications to the current database was detected, and the user was prompted to save the changes. • View statistics of actual CPU use against current priority settings. For example: class> stats Class scheduler status: enabled class name high_users batch_jobs target percentage 50% 10% actual percentage 40.0% 2.0% 4.7.
as processors and peripherals, that employ power management capabilities. With these utilities, you enable power management modes and specify the amount of time to wait before shutting off each component in order to save power. 4.8.1 Display Monitors and DPMS Consult the hardware documentation for any display monitor (screen) that is attached to your system before implementing power management.
If you are not using CDE, you can start the dxpower utility from the command line as follows: # /usr/bin/X11/dxpower When the dxpower utility runs, a power management window is displayed on your screen. The window provides check boxes that you use to select modes of operation, and scales you use to specify dwell times. For more information about how to use the dxpower utility, start the application and then click on the Help button in the lower right-hand corner of the window. 4.8.
problem with the drive. Consider adjusting the idle time for the drive. To change the power management values that take effect every time you restart the kernel, you create a file in stanza file format. See stanza(4) for more information. The stanza-formatted file can contain the following power management attributes: • default_pwrmgr_state The global power management state. Specify 1 to enable or 0 to disable this attribute. • cpu_slowdown The current state of CPU slowdown.
cpu_slowdown=1 disk_dwell_time=20 disk_spindown=1 graphics_powerdown=1 graphics_standby_dwell=5 graphics_suspend_dwell=10 graphics_off_dwell=15 For the disk_dwell_time, graphics_standby_dwell, graphics_suspend_dwell, and graphics_off_dwell attributes, the specified values indicate the number of minutes to wait before powering down the idle hardware.
5 Configuring the Kernel The Tru64 UNIX kernel is a memory-resident executable image that handles all the system services −− hardware interrupts, memory management, interprocess communication, process scheduling −− and makes all other work on the operating system possible. In addition to the code that supports these core services, the kernel contains a number of subsystems. A subsystem is a kernel module that extends the kernel beyond the core kernel services.
5.1 System Configuration at Installation Time When you install Tru64 UNIX, the installation program initially copies a kernel image to the root partition of your system disk. This kernel image, known as the generic kernel, supports all processors and hardware options that are available for use with the current version of the operating system. In this way, the installation program ensures that you can boot your system regardless of its configuration.
You must reconfigure your kernel, either dynamically or statically, when one of these situations occurs. The method you use to reconfigure your kernel depends upon the support provided by the subsystem or subsystem attributes. 5.2.1 Dynamic Subsystems and Attributes Some kernel subsystems are dynamically loadable, meaning that you can add the subsystem to or remove the subsystem from the kernel without rebuilding the kernel.
– rt − Realtime subsystem – snmpinfo − snmpinfo subsystem – streams − STREAMS subsystem – tty − Terminal subsystem – ufs − UNIX File System – vfs − System V File System – vm − Virtual memory subsystem – xpr − XPR kernel tracing subsystem If you decide to configure attributes of these subsystems, use the procedures described in Section 5.3.8.
Unlike the command line methods of administering attributes, dxkerneltuner provides immediate information on what subsystems are loaded, and which attributes can be dynamically or only statically modified. You can also see the current and permissible values for any modifiable attribute. When you invoke dxkerneltuner, a window is displayed listing all the currently-loaded subsystems. For example: envmon lan_common kds vga gpc_input ws pci . . .
You will be prompted to enter a file name for the saved file, or choose an existing file to load. The following shows a sample of part of a saved file: # File created from tuning app kds: kds_print_flag=0 gpc_input: kbd_scancode=3 Num_Units_Installed=1 gpc_developer_debug=0 pci: PCI_Developer_Debug=0 ace: dcd_timer=2 isa: ISA_Developer_Debug=0 . . . . As with any kernel configuration tasks, there is a risk that modifying attributes can leave your system in an unusable state.
You can load and unload subsystems on a local system or a remote system. For information about adding and removing subsystems on remote systems, see Section 5.3.7 If you are writing a loadable device driver or other loadable subsystem, refer to the Writing Device Drivers: Tutorial manual and the Programmer’s Guide. The Writing Device Drivers: Tutorial manual describes the tasks performed by the system when you install a loadable device driver.
io: loaded and configured vm: loaded and configured vfs: loaded and configured ufs: loaded and configured ipc: loaded and configured tty: loaded and configured xpr: loaded and configured rt: loaded and configured net: loaded and configured dli: loaded and configured lat: loaded and configured bufcall: loaded and configured strstd: loaded and configured streams: loaded and configured kinfo: loaded and configured timod: loaded and configured tirdwr: loaded and configured xtiso: loaded and configured dlb: load
5.3.4 Unloading a Subsystem To unconfigure (and possibly unload) a subsystem, use the /sbin/sysconfig -u command, as shown: # /sbin/sysconfig -u decnet If you frequently configure and unconfigure device drivers you might notice that the device special files associated with a particular device driver differ from time to time. This behavior is normal. When you configure a device driver using the /sbin/sysconfig command, the system creates device special files.
5.3.6 Managing Subsystem Attributes Occasionally, to improve the performance of a subsystem or of the system as a whole, you might modify the value of subsystem attributes. You use the /sbin/sysconfig command to determine the names and values of subsystem attributes. You can also use the command to modify the value of a small number of attributes in the currently running kernel.
rt-preempt-opt = 0 cpu_enable_mask = 18446744073709551615 cpu-enable-mask = 18446744073709551615 msgbuf_size = 4096 message-buffer-size = 4096 dump-sp-threshold = 4096 lite-system = 0 The /sbin/sysconfig −q command lists all subsystem attributes and their values. Some attributes are configurable with the /sbin/sysconfig −r command. For information about which attributes are configurable, see System Configuration and Tuning. 5.3.6.
For example, to modify the dump-sp-threshold attribute for the generic subsystem, issue a command like the following: # /sbin/sysconfig -r generic dump-sp-threshold=20480 To modify the value of more than one attribute at a time, include a list on the /sbin/sysconfig command line.
5.3.8 Managing the Subsystem Attributes Database Information about dynamically configurable subsystem attributes is stored in the /etc/sysconfigtab database. You use this database to record the values you want to be assigned to subsystem attributes each time the system is rebooted or a subsystem is configured. No attributes are set automatically in this database.
multiple entries in the file which override each other, and the behaviour of such entries can be confusing and difficult to diagnose. Entries that appear towards the end of the file may not override similar entries that appear at the beginning. However, if you edit the /etc/sysconfigtab database, you must run the /sbin/sysconfigdb −s command after you write and quit the file so that the in-memory copy of the database is updated. 5.3.8.
generic: lockmode = 4 dump-sp-threshold = 6000 Suppose that you create a file named merge_attrs for updating this entry, which contains the following information: generic: lockmode = 0 lockmaxcycles = 4294967295 To merge the information in the merge_attrs file into the /etc/sysconfigtab database, issue the following command: # /sbin/sysconfigdb -m -f merge_attrs generic After the command finishes, the entry for the generic subsystem in the database appears as follows: generic: lockmode = 0 lockmaxcycles
lockmaxcycles = 4294967295 To update the attributes, you issue the sysconfigdb command, as follows: # /sbin/sysconfigdb -u -f update_attrs generic After the command finishes, the entry for the generic subsystem in the database appears as follows: generic: lockmode = 0 lockmaxcycles = 4294967295 5.3.8.5 Removing Attribute Definitions from the Database To remove the definitions of selected attributes from the /etc/sysconfigtab database, enter the /sbin/sysconfigdb −r command.
remove_attrs file, you omit the subsystem name from the command line, as shown: # /sbin/sysconfigdb -r -f remove_attrs 5.3.8.6 Deleting Subsystem Entries from the Database To delete the definition of a subsystem from the /etc/sysconfigtab database enter the /sbin/sysconfigdb −d command. For example, to delete the generic subsystem entry in the database, issue the following command: # /sbin/sysconfigdb -d generic The generic subsystem receives its default values the next time it is configured. 5.
choosing the kernel option from a menu displayed during processing. You then shutdown and reboot your system. To determine which kernel options you can configure in this way, issue the /usr/sbin/kopt command. The command displays a list of kernel options and prompts you for kernel options selections. To exit from the /usr/sbin/kopt command without choosing options, press the Return key. For information about running the /usr/sbin/doconfig program to add kernel options using a menu, see Section 5.4.2.
kernel once you have edited the target configuration file. The procedure assumes that you do not know the appropriate keyword to add. In some cases, you might be able to determine the appropriate keyword by looking at documentation supplied with the hardware or with a new version of Tru64 UNIX. Another source of this information is an existing configuration file on another system that already has the device connected to it.
After all kernel subsets are installed, issue the following command: # doconfig -c GENERIC The −c flag specifies that you want to build a kernel using an existing configuration file, in this case the GENERIC configuration file. For more information about building a kernel from an existing configuration file, see Section 5.4.3. After the generic kernel is running and recognizes the new device, continue with step 5. When the build ends, condider using the strip command to reduce the size of the kernel.
support the new device, without losing any changes you made to that file in the past. _____________________ Note _____________________ If you add or remove communications devices from your configuration file, you must edit the /etc/inittab file and the /etc/securettys file to match your new configuration; that is, to match the /dev/ttynn special device files. For more information, see inittab(4) and securettys(4). 9.
# mount -u / 3. If necessary, mount the file system where the /vmunix.save file is stored. For example, if you copied the /vmunix file to the /usr file system, issue the following command: # mount /usr 4. Restore the saved copy. For example, if you saved your running kernel in the /vmunix.save file, issue the following command: # mv /vmunix.save /vmunix 5.
configuration file name. For example, on a system named mysys, the default configuration file is named MYSYS. If the configuration file name you specify does not currently exist, the /usr/sbin/doconfig program builds one with that name. Continue this process by selecting the kernel options in step 10. 5. If the configuration file name you specify exists, answer the following prompt to indicate that you want to overwrite it: A configuration file with the name MYSYS already exists.
If you choose to edit the configuration file, the /usr/sbin/doconfig program invokes the editor specified by the EDITOR environment variable. For information about the configuration file, see Section 5.5 After you finish editing the configuration file, the /usr/sbin/doconfig program builds a new kernel. 8. When the kernel configuration and build process completes without errors, move the new vmunix file to /vmunix. On a system named MYSYS, issue the following command: # mv /usr/sys/MYSYS/vmunix /vmunix 9.
command. The −c flag allows you to name an existing configuration file, which the /usr/sbin/doconfig program uses to build the kernel. To build a new kernel using an existing configuration file, follow these steps: 1. Log in as root or become the superuser and set your default directory to the /usr/sys/conf directory. 2. Save a copy of the existing /vmunix file. If possible, save the file in the root (/) directory, as follows: # cp /vmunix /vmunix.
If the new /vmunix file fails to boot, boot using the kernel you saved at the beginning of the procedure. To use the saved kernel, follow these steps: 1. Check all local file systems by using the fsck −p command as follows: # fsck -p 2. Write-enable the root file system using the mount −u command as follows: # mount -u / 3. If necessary, mount the file system where the /vmunix.save file is stored.
Figure 5–1: Configuration Files Directory Hierarchy /usr /sys /conf /opt param.c files BINARY GENERIC MYSYS .products.list MYSYS.list ESB100 stanza.loadable files config.file cb.o stanza.static cb_data.c cb.c cbreg.h cb_mod ZK−0828U−R As shown in Figure 5–1, the /usr/sys/conf directory contains files that define the kernel configuration for the generic and target kernels. These files represent the configuration of the static portion of the kernel.
described by a file named /usr/sys/conf/MYSYS. Each system has a target configuration file built for it by the sizer program during system installation.
When you install a static subsystem, its SCP normally edits the /usr/sys/conf/.product.list file and adds an entry for the subsystem. After the SCP completes, you run the /usr/sbin/doconfig program to configure the new subsystem into the kernel. The /usr/sbin/doconfig program creates the NAME.list file. The NAME variable is the same as the target configuration file, and by convention, is your system name in capital letters. For example, the NAME.list file for a system named MYSYS is MYSYS.list.
The order of the line entries in the NAME.list file reflects the order in which the entries are processed. The /usr/sbin/doconfig program creates the NAME.list file by copying the .product.list file, if it exists. Note that when using the /usr/sbin/doconfig -c command, /usr/sbin/doconfig uses the existing NAME.list file. If the .product.list file changes (for example, a new kernel layered product was installed) and the −c flag is used, either delete the NAME.
Table 5–1: Tunable param.c File Entries Parameter Default Value Configuration File Equivalent autonice 0 Set to 1 if AUTONICE defined bufcache 3 bufcache bufhsz 512 None hz 100 CLOCKS_PER_SEC None, defined in
Table 5–1: Tunable param.c File Entries (cont.
_______________________ Note _______________________ The configuration files supplied with Tru64 UNIX, the GENERIC file and the target configuration file for your system that is generated by the sizer program at installation time, override the default values for certain options. For example, the default value for the maxdsiz option is 32 MB; however, the configuration files supplied with Tru64 UNIX increase maxdsiz to 1 gigabyte.
Table 5–2: Configuration File Entries (cont.
Table 5–2: Configuration File Entries (cont.
Table 5–2: Configuration File Entries (cont.
Table 5–2: Configuration File Entries (cont.
Table 5–2: Configuration File Entries (cont.
5.6.1.1 Kernel Identification The ident keyword identifies the kernel that you are building. In general, you identify the kernel according to the machine it runs on; by convention, the kernel name is in uppercase letters. For example, the identification for a kernel that runs on a machine named MYSYS would have the following /usr/sys/conf/MYSYS configuration file entry: ident MYSYS 5.6.1.2 Time Zone The Tru64 UNIX kernel does not store time zone information.
the sys_v_mode keyword is set to 0 (zero), System V functionality is not enabled; this is the default. If the sys_v_mode keyword is set to 1, System V functionality is enabled. This system keyword directly affects the open( ), creat( ), and mkdir( ) system calls. The following tables describe how the sys_v_mode keyword affects behavior during file creation, directory creation, and file creation using the open( ) system call.
File Creation Mode S_ISGID bit New File Group ID Equals Effective Group ID of Process or Support Group Member New File S_ISGID bit Clear Yes Clear Clear No Clear Set Yes Set Set No Clear If the keyword is not set as in the previous table, the S_ISGID bit is always cleared, as per the base operating system and the POSIX interface. 5.6.1.
shmmni Number of shared memory identifiers shmseg Maximum number of attached shared memory segments per process 5.6.1.6 Expected Number of Simultaneous Users The maxusers keyword defines the number of simultaneous users that your system can support without straining system resources. The number should not be taken literally; from a performance standpoint, the number should always be greater than the expected number of real users.
• maxcallouts • nclist • nquota • nvnode • ndquot • task_max 5.6.1.7 Maximum Number of clists The nclist keyword is based on the maxusers keyword and defines the number of clists available on the system. Each clist is a buffer for terminal I/O. The nclist keyword overrides the default value for nclist in the param.c file. The default value should be sufficient for most configurations. Exceptions include third-party asynchronous boards and layered products that perform terminal emulation. 5.6.1.
message is displayed if the system reaches the threadmax limit while creating a new process: fork/procdup: thread_create failed. Code: 6 5.6.1.11 Maximum Number of Processes The task_max keyword is based on the maxusers keyword and sets a limit on the number of processes that can be running on the system. Normally, you should modify the maxusers keyword, rather than the task_max keyword. Initially, task_max is set to the following: 1+ (20 + (8 * maxusers)) This value is not absolute.
5.6.1.13 Maximum Number of Callouts The maxcallouts keyword is based on the maxusers keyword and defines the maximum number of callouts on the system. It is used to size the kernel’s callout table. The default number of callouts is determined automatically based on the value of the maxusers keyword and other system parameters. Use of the default maxcallouts definition is strongly recommended.
5.6.1.15 Machine Architecture The machine keyword defines the architecture of the machine on which the kernel will run. For example: machine alpha 5.6.1.16 Machine Type The cpu keyword defines the specific architectural machine type on which the kernel will run. For example: cpu "DEC3000_400" 5.6.1.17 System SCS Identifier The scs_sysid keyword identifies each device on the CI to the SCS subsystem. The devices supported on the CI are RA class devices. The argument must be a unique value.
segmentation Enables or disables shared page tables. The default is 1 (enabled). swapbuffers Specifies the maximum number of swap buffers that are available for swap I/O. The default is 128. ubcbuffers Specifies the minimum number of buffers that the unified buffer cache can contain. The default is 256. vpagemax Specifies the maximum vpage for user map, or the maximum number of individually protected pages. The default is 16384.
/dev/rz1b dump1 ufs sw 0 2 Note that the kernel will unconditionally write the crash dump to rz1b, thus destroying any data on that partition. In most cases, crash dumps should be written to one of the swap partitions. For more information about controlling how the system writes crash dumps, see Kernel Debugging. When you specify the dumps keyword, you also need to specify the location of the root file system with the root on keyword.
Definition Time Invoked at_start After the config command has parsed the configuration file syntax but before processing any input at_exit Immediately before the config command exits, regardless of its exit status at_success Before the at_exit process, if specified, and only if the config command exits with a success exit status before_h Before the config command creates any *.h files after_h After the config command creates any *.h files before_c Before the config command creates any *.
5.6.5.1 Symmetrical Multiprocessing You do not have to add special configuration options for symmetrical multiprocessing (SMP). The system determines at boot time whether it has multiple CPUs and configures itself accordingly. The default for multiprocessor systems is to configure SMP. For information on how to override this default, see System Configuration and Tuning.
cfe: Error: conf.c, line 925: Too many initial values for ’bdevsw’ If you receive a message similar to this one, edit the the configuration file and define the options keywords MAX_BDEVSW and MAX_CDEVSW. For example, the following line sets the MAX_BDEVSW keyword to 64: options MAX_BDEVSW=64 Refer to Table 5–2 for information about the default values for these keywords. 5.6.5.4 File System Configuration The operating system views file systems as kernel subsystems.
Option Definition Required Use PROC_FS No /proc file system (used by DECladebug) QUOTA Yes Disk quotas SYSV_COFF Yes Format of load files: System V COFF executables SYSV_ELF Yes System V SYSV_FS No System V File System UFS Yes UNIX File System UNIX_LOCKS Noa Locking version (parallel) aYes if a realtime kernel. 5.6.5.
Options Keyword Required Use MACH_SCTIMES Yes Dummy system calls for timing ULT_BIN_COMPAT Yes Enables ULTRIX binary compatibility 5.6.5.7 Remote Kernel Debugging The KDEBUG keyword controls your ability to use the dbx -remote command. If your kernel is built with KDEBUG, you can debug the running kernel using dbx -remote. Note that ikdebug is the integrated interactive mode of the kdebug kernel debugger.
Options Keywords Required Use STAT_TIME Yes Use statistical timing VAGUE_STATS Yes Vague counts (parallel) 5.6.5.11 Network and Communications Protocols and Dependencies The following configuration file entries define the code dependencies for network and communications functionality.
Selection of the DLPI option configures the Datalink Bridge Driver (DLB), which implements a partial subset of the DLPI specification. See the Network Programmer’s Guide for more information. The PPP option is dependent upon the INET option. The number of PPP lines is configurable using the nppp parameter in the /etc/sysconfigtab file. The default value for nppp is 1. The SL option is dependent upon the INET option.
5.6.7 The pseudo-device Keywords The configuration file contains several keywords that are categorized under the broad pseudo-device keyword. These include terminal services, the Logical Storage Manager (LSM), and additional network protocol families and services definitions. The configuration file must contain definitions that correspond to the network protocols and services upon which file systems and communications services depend.
The previous entry must be present in the configuration file for Prestoserve to operate properly. Certain Prestoserve hardware implementations require an additional entry in the system configuration file. For information on the Prestoserve hardware and its supporting software, see the Guide to Prestoserve. 5.6.7.4 Terminal Service The pty configuration file entry specifies the number of available pseudo-ttys (used for incoming network logins and for windows).
encapsulation is provided in the document Logical Storage Manager. LSM provides a virtual disk that enables you to store and replicate data without physical boundaries. LSM is composed of physical devices and logical entities to offer you a mechanism for transparently and dynamically storing and retrieving files and file systems across devices and in multiple copies.
5.6.7.8 Packetfilter To configure the kernel packetfilter device, include the following line in the configuration file: "options PACKETFILTER" 5.6.7.9 Network Loopback Device If your configuration requires the software loopback interface definition, the following entry must be present in the configuration file: pseudo-device loop 5.6.7.
6 Administering Devices with Dynamic Device Recognition This chapter describes the Dynamic Device Recognition (DDR) database, which you use to administer devices in the SCSI/CAM I/O subsystem. It explains how you use the ddr_config utility to manage the DDR database on your system. This chapter introduces DDR, then describes how you use the ddr_config utility to: • Add SCSI devices to the DDR database • Convert a customized cam_data.
The information DDR provides about SCSI devices is needed by SCSI drivers. You can supply this information using DDR when you add new SCSI devices to the system, or you can use the /sys/data/cam_data.c data file and static configuration methods. The information provided by DDR and the cam_data.c file have the same objectives.
6.2 Changing the DDR Database When you make a change to the operating parameters or characteristics of a SCSI device, you must describe the changes in the /etc/ddr.dbase file. You must compile the changes by using the ddr_config -c command.
The command uses as input the system configuration file that you used to build your running kernel. The procedure runs in multiuser mode and requires no input after it has been started. You should redirect output to a file in order to save the summary information. Compile errors are reported to standard error and the command terminates when the error is reported. Warnings are reported to standard error and do not terminate the command. 3.
of pseudoterminals you want to add. The following examples show that 400 pseudoterminals have been added. The pseudodevice entry for STREAMS-based pseudoterminals is as follows: pseudo-device rpty 655 The pseudodevice entry for clist- based pseudoterminals is as follows: pseudo-device pty 655 For more information on the configuration file and its its pseudodevice keywords, refer to Chapter 5. 3. Rebuild and boot the new kernel. Use the information on rebuilding and booting the new kernel in Section 5.4.
pty1 pseudoterminals have corresponding device special files named /dev/ttyq0 through /dev/ttyqf. If you add pseudoterminals to your system, the pty# variable must be higher than pty1 because the installation software sets pty0 and pty1. For example, to create device special files for a third set of pseudoterminals, enter: # ./MAKEDEV pty2 The MAKEDEV command lists the device special files it has created.
6.4.2 Adding Disk and Tape Drives When you add new tape or disk drives to your system, you must physically connect the devices and then make the devices known to the system. There are two methods, one for static drivers and another for loadable drivers. _______________________ Note _______________________ You will need the documentation that came with your system’s hardware. This includes such documentation as the owner’s guide, the disk drive guide, and the options guide.
7 Administering the UNIX File System This chapter introduces file systems, disk partitions, and swap space, and explains how to perform the following system administration tasks related to the UNIX File System (UFS): • Adding swap space • Managing file system directories and files • Configuring file system types and locks • Creating file systems • Mounting and unmounting file systems • Tuning and checking file systems • Managing disk space and troubleshooting disks • Repartitioning disks •
Administration of the NFS is documented in the Network Administration manual. The Technical Overview points you to sources of information about these file systems: • Memory File System (MFS) • /proc File System (PROCFS) • File-on-File Mounting File System (FFM) • File Descriptor File System (FDFS) 7.1.1 Disk Partitions A disk consists of storage units called sectors. Each sector is usually 512 bytes. A sector is addressed by the logical block number (LBN).
Figure 7–1: RZ73 Default Disk Partitions disk sectors 0 a 131072 b 393216 c disk partitions d 1564781 e 2736346 3907911 f h g 1212416 ZK−0837U−R The disk label is located in block 0 (zero) in one of the first sectors of the disk. The disk label provides detailed information about the geometry of the disk and the partitions into which the disk is divided. The system disk driver and the boot program use the disk label information to recognize the drive, the disk partitions, and the file systems.
label with the disklabel command. Refer to Section 7.8 and to the disklabel(8) reference page for more information. 7.1.2 Adding Swap Space The Tru64 UNIX operating system uses a combination of physical memory and disk space to create virtual memory, which can be much larger than the physical memory. Virtual memory can support more processes than the physical memory alone.
clusters of pages, the operating system selects a low priority process and reclaims all the physical pages that it is using. It does this by writing all of its modified virtual pages to swap space. This operation is called a swapout. Swapouts typically occur on systems that are memory constrained. 7.1.2.1 How Swap Space Is Allocated Swap space is initially allocated during system installation.
physical memory. If this total amount is greater than the size of physical memory, the swap space must be large enough to hold the modified virtual pages that do not fit into your physical memory. If your system’s workload is complex and you are unable to estimate the appropriate amount of swap space by using this method, you should first use the default amount of swap space and adjust the swap space as needed. You should always monitor your system’s use of swap space.
A UFS file system has four major parts: • Boot block The first block of every file system (block 0) is reserved for a boot, or initialization, program.
– File owner The inode contains the user and group identification numbers that are associated with the owner of the file. – Protection information Protection information specifies read, write, and execute access for the file owner, members of the group associated with the file, and others. The protection information also includes other mode information specified by the chmod command. – Link count A directory entry (link) consists of a name and the inumber (inode number) that represents the file.
Figure 7–2: Partial Tru64 UNIX Directory Hierarchy / dev etc init.d rc0.d .smdb. sbin rc2.d bin usr lost + found rc3.d subsys ccs examples opt var spool adm opt include lib tmp vmunix subsys lbin sbin subsys share sys BINARY X11 mach machine net netinet nfs protocols rpc servers streams sys tli shlib conf udp include ufs ZK−0851U−R Table 7–1 describes the contents and purposes of the directories shown in Figure 7–2.
Table 7–1: Contents of the Tru64 UNIX Directories (cont.) Directory Description Commands essential to boot the system. These commands do not depend on shared libraries or the loader and can have other versions in /usr/bin or /usr/sbin. sbin/ init.d System initialization files. rc0.d The rc files executed for system-state 0 (single-user state). rc2.d The rc files executed for system-state 2 (nonnetworked multiuser state). rc3.d The rc files executed for system-state 3 (networked multiuser state).
Table 7–1: Contents of the Tru64 UNIX Directories (cont.) Directory Description rpc C include files for remote procedure calls. servers C include files for servers. streams C include files for Streams. sys System C include files (kernel data structures). tli C include files for Transport Layer Interface. udp C include files for User Datagram Protocol. ufs C include files for UFS. lib Libraries, data files, and symbolic links to library files located elsewhere; included for compatibility.
system, you specify a location (the mount point under the system root directory) to which the file system will attach. The root directory of a mounted file system is also its mount point. Only one system root directory can exist because the system uses the root directory as its source for system initialization files. Consequently, file systems are mounted under the system root directory. 7.1.
named pipe, or a UNIX domain socket). The driver handles all read and write operations and follows the required protocols for the device. _______________________ Note _______________________ Support for rz SCSI device names will be retired in a future release. Any code that derives knowledge about a device from the ASCII name or minor number may be impacted.
For static drivers, use the MAKEDEV command or the mknod command to create device special files. The kmknod command creates device special files for third-party kernel layered products. Refer to the MAKEDEV(8), mknod(8), and kmknod(8) reference pages for more information. For loadable drivers, the sysconfig command creates the device special files by using the information specified in the driver’s stanza entry in the /etc/sysconfigtab database file. 7.1.
7.2 Creating File Systems The newfs command formats a disk partition and creates a usable UNIX file system. For information on creating an AdvFS, refer to AdvFS Administration. Using the information in the disk label or the default values specified in the /etc/disktab file, the newfs command builds a file system on the specified disk partition. You can also use newfs command options to specify the disk geometry.
/usr/sbin/fsck [ options ...] [ file_system ...] If you do not specify a file system, all the file systems in the /etc/fstab file are checked. If you specify a file system, you should always use the raw device. Refer to the fsck(8) reference page for information about command options. See Section 7.10 for information about how this command interacts with overlapping partitions.
_______________________ Note _______________________ To change a file system’s mount status, use the mount command with the −u option. This is useful if you try to reboot and the /etc/fstab file is unavailable. If you try to reboot and the /etc/fstab file is corrupted, use a command similar to the following: # mount -u /dev/rz0a / The /dev/rz0a device is the root file system. The operating system uses the UFS for the root file system.
Each line contains an entry and the information is separated either by tabs or spaces. An /etc/fstab file entry has the following information: 1 2 3 4 5 Specifies the block special device or remote file system to be mounted. For UFS, the special file name is the block special file name, not the character special file name. Specifies the mount point for the file system or remote directory (for example, /usr/man) or swapn for a swap partition.
6 Used by the fsck command to determine the order in which the UNIX file system is checked at boot time. For the root file system, specify 1; for other file systems that you want to check, specify 2. If you do not specify a value or if you specify 0 (zero), the file system is not checked. File systems that use the same disk drive are checked sequentially. File systems on different drives are checked simultaneously to utilize the available parallelism. 7.4.
# mount -t nfs -o rw acton:/usr/homer /homer Refer to the mount(8) reference page for more information on general options and options specific to a file system type. See Section 7.10 for information about how this command interacts with overlapping partitions. 7.4.2 Using the umount Command Use the umount command to unmount a file system. You must unmount a file system if you want to check it with the fsck command or if you want to change its partitions with the disklabel command.
With the radisk program, you can perform the following tasks on a DSA disk device: • Clear a forced error indicator • Set or clear the exclusive access attribute • Replace a bad block • Scan the disk for bad blocks Refer to the radisk(8) reference page for more information.
With no arguments or options, the df command displays the amount of free disk space on all of the mounted file systems. For each file system, the df command reports the file system’s configured size in 512-byte blocks, unless you specify the −k option, which reports the size in kilobyte blocks. The command displays the total amount of space, the amount presently used, the amount presently available (free), the percentage used, and the directory on which the file system is mounted.
7.7.2 Checking Disk Use If you determine that a file system has insufficient space available, check how its space is being used. You can do this with the du command or the quot command. The du command pinpoints disk space allocation by directory. With this information you can decide who is using the most space and who should free up disk space. The du command has the following syntax: /usr/bin/du [- aklrsx ] [ directory ... filename ...
_______________________ Note _______________________ As an alternative to the du command, you can use the ls −s command to obtain the size and usage of files. Do not use the ls −l command to obtain usage information; ls −l displays only file sizes. You can use the quot command to list the number of blocks in the named file system currently owned by each user. You must be root user to use the quot command.
7.7.3.1 Hard and Soft Quota Limits File systems can have both soft and hard quota limits. When a hard limit is reached, no more disk space allocations or file creations that would exceed the limit are allowed. The soft limit may be reached for a period of time (called the grace period).
4. Use the edquota command to activate the quota editor and create a quota entry for each user. For each user or group you specify, edquota creates a temporary ASCII file that you edit with the vi editor. Edit the file to include entries for each file system with quotas enforced, the soft and hard limits for blocks and inodes (or files), and the grace period. If you specify more than one user name or group name in the edquota command line, the edits will affect each user or group.
7.8 Partitioning Disks This section provides the information you need to change the partition scheme of your disks. In general, you allocate disk space during the initial installation or when adding disks to your configuration. Usually, you do not have to alter partitions; however, there are cases when it is necessary to change the partitions on your disks to accommodate changes and to improve system performance.
Specify the device with its directory name (/dev) followed by the raw device name, drive number, and partition a or c. You can also specify the disk unit and number, such as rz1.
5. Calculate the new partition parameters. You can increase or decrease the size of a partition. You can also cause partitions to overlap. 6. Edit the disk label by using the disklabel command with the −e option to change the partition parameters, as follows: disklabel -e [-r] disk An editor, either the vi editor or that specified by the EDITOR environment variable, is invoked so you can edit the disk label, which is in the format displayed with the disklabel −r command.
Identify the device special files for the source and target disks (dev/disk/dskNx). Use dsfmgr or hwmgr to identify and check disk characteristics. 2. Before exiting diskconfig, note the physical location (bust, target, and lun) of the source and target disks. 3. The /etc/sysconfigtab file lists the swap partitions that you will need to recreate on the target disk. Use the swapon command to check the swap partitions. 4.
tracks/cylinder: 14 sectors/cylinder: 798 cylinders: 2570 rpm: 3600 interleave: 1 trackskew: 0 cylinderskew: 0 headswitch: 0 track-to-track seek: 0 drivedata: 0 8 partitions: # size offset a: 131072 0 b: 262144 131072 c: 2050860 0 d: 552548 393216 e: 552548 945764 f: 552548 1498312 g: 819200 393216 h: 838444 1212416 # milliseconds # milliseconds fstype unused unused unused unused unused unused unused unused [fsize bsize cpg] 1024 8192 # (Cyl. 0 1024 8192 # (Cyl. 164*1024 8192 # (Cyl. 0 1024 8192 # (Cyl.
If the partition is not available, these commands return an error message and ask if you want to continue, as shown in the following example: # newfs /dev/rrz8c WARNING: disklabel reports that rz8c currently is being used as "4.2BSD" data. Do you want to continue with the operation and possibly destroy existing data? (y/n) [n] Applications, as well as operating system commands, can modify the fstype of the disk label, to indicate that a partition is in use.
8 Administering the Logical Storage Manager The Logical Storage Manager (LSM) software provides disk management capabilities that increase data availability and improve disk I/O performance. System administrators use LSM to perform disk management functions dynamically without disrupting users or applications accessing data on those disks. LSM replaces the Logical Volume Manager (LVM) on Digital UNIX systems. Refer to the Logical Storage Manager manual for information about how to migrate from LVM to LSM.
Table 8–1: LSM Features and Benefits (cont.) Feature Benefit Protects against data loss Protects against data loss due to hardware malfunction by creating a mirror (duplicate) image of important file systems and databases. Increases disk performance Improves disk I/O performance through the use of striping, which is the interleaving of data within the volume across several physical disks. This chapter provides an overview of LSM concepts and some commonly used commands.
Figure 8–1: LSM Disk Storage Management vol01 Database vol02 File System vol03 Application Block− and Character− Device Interface ZK−1011U−R On a system that does not have LSM installed, I/O activity from the UNIX system kernel is passed through disk device drivers that control the flow of data to and from disks. When LSM is installed, the I/O passes from the kernel to the LSM volume device driver, then to the disk device drivers.
structure of LSM objects to organize and optimize disk usage and guard against media failures. The structure is built with the objects in the following logical order: 1. Subdisks 2. Plexes (mirrors) 3. Volumes Each object has a dependent relationship on the next-higher element, with subdisks being the lowest-level objects in the structure and volumes the highest level.
Table 8–2: LSM Objects (cont.) Object Description Disk A collection of nonvolatile, read/write data blocks that are indexed and can be quickly and randomly accessed. LSM supports standard disk devices including SCSI and DSA disks. Each disk LSM uses is given two identifiers: a disk access name and an administrative name. Disk Group A collection of disks that share the same LSM configuration database. The rootdg disk group is a special disk group that always exists.
Figure 8–2: LSM Objects and Their Relationships Volume subdisk subdisk subdisk subdisk subdisk Disk 1 subdisk subdisk Plex 1 Plex 2 Disk 2 Disk 3 Disk 4 ZK−0948U−AI 8.2.2 LSM Disks You must add physical disks to the LSM environment as LSM disks before you can use them to create LSM volumes. Refer to Section 8.6.3 and the voldiskadd(8) reference page for information about adding physical disks to LSM.
Figure 8–3 illustrates the three types of LSM disks: simple, sliced, and nopriv. You can add all of these types of disks into an LSM disk group. Figure 8–3: Types of LSM Disks p ri v a t e r e g i o n p u b li c r e g i o n rz7g p u b li c r e g i o n p ri v ate r e g i o n LSM Simple Disk LSM Sliced Disk rz16c p u b li c r e g i o n rz3g rz7h LSM nopriv Disk ZK−1010U−AI In Figure 8–3: • Simple disks have both public and private regions in the same partition (rz3g).
dd l n nnn p The elements in the disk access name are described in the following table: Element Description dd A two-character device mnemonic that shows the disk type. Use ra for DSA disks and rz for SCSI disks. [l] The SCSI logical unit number (LUN), in the range from a to h, to correspond to LUNs 0 through 7. This argument is optional and used for SCSI Redundant Arrays of Independent Disks (RAID) devices. n[nnn] The disk unit number ranging from 1 to 4 digits.
the size of the LSM configuration database for each disk group as well as reduce the amount of overhead incurred in configuration changes. • If a system will be unavailable for a prolonged amount of time due to a hardware failure, you can move the physical disks in a disk group to another system. This is possible because each disk group has a self-describing LSM configuration database. All systems with LSM installed have the rootdg disk group. By default, operations are directed to this disk group.
8.2.6 Moving and Replacing LSM Disks in a Disk Group When a disk is added to a disk group it is given a disk media name, such as disk02. This name relates directly to the physical disk. LSM uses this naming convention (described in Section 8.2.3) because it makes the disk independent of the manner in which the volume is mapped onto physical disks. If a physical disk is moved to a different target address or to a different controller, the name disk02 continues to refer to it.
Table 8–3: LSM Administration Interfaces Interface Type Description Visual Graphical Administrator (dxlsm) Uses windows, icons, and menus to manage LSM volumes. The dxlsm graphical interface requires a workstation. The interface interprets the mouse-based icon operations into LSM commands. The Visual Administrator (dxlsm) interface requires the LSM software license. Support Operations (voldiskadm) Provides a menu of disk operations.
8.4.2 Bottom-Up Commands The bottom-up approach to storage management allows you to control the placement and definition of subdisks, plexes, and volumes. Bottom-up commands allow a great deal of precision control over how LSM creates and connects objects together. You should have a detailed knowledge of the LSM architecture before using these commands. Bottom-up commands include volmake to create LSM objects, and volume, volplex, and volsd to manipulate volume, plex, and subdisk objects.
Table 8–4: LSM Configuration Options Configuration Description Concatenated volumes You concatenate multiple LSM disks together to form a big volume. You can use a concatenated volume to store a large file or file systems that span more than one disk. Disk concatenation frees you from being limited by the actual physical sizes of individual disks so that you can combine the storage potential of several devices.
Table 8–4: LSM Configuration Options (cont.) Configuration Description Mirrored and striped volumes Use mirrored and striped volumes when speed and availability are important. LSM supports mirroring of striped plexes. This configuration offers the improved I/O performance of striping while also providing data availability. The different striped plexes in a mirrored volume do not have to be symmetrical.
# /sbin/vol-startup 8.6.2 Setting up LSM If you are setting up LSM for the first time, you can use the volsetup utility to initialize LSM and create the LSM configuration database for the first time. Then, use the voldiskadd utility to add more disks into LSM. This is the simplest method to set up an LSM configuration. The volsetup utility automatically modifies disk labels, initializes disks for LSM, creates the default disk group, rootdg, and configures disks into the rootdg disk group.
The volsetup utility creates the /etc/vol/volboot file. This file is used to locate copies of the rootdg disk group configuration when the system starts up. _______________________ Note _______________________ Do not delete or manually update the /etc/vol/volboot file; it is critical for starting LSM. 8.6.
• To use nonreserved disks to create a 1024 Kb volume in the dg1 disk group, enter the following command: # volassist -g dg1 make vol02 1024k • To create a volume on a specified disk in the rootdg disk group, enter the following command: # volassist -g rootdg make vol03 200000s rz7 • To use nonreserved disks to create a 200,000 sector volume in the rootdg disk group and exclude the rz9 disk, enter the following command: # volassist -g rootdg make vol03 200000s !rz9 • To create a 20 MB striped volume
# volassist shrinkby vol01 1024k _____________________ Caution _____________________ The following restrictions apply to grown LSM volumes: • A volume containing one or more striped plexes cannot grow in size. • Neither UFS nor AdvFS file systems can take advantage of the extra space in a grown LSM volume. • Shrinking an LSM volume with either a UFS or AdvFS file system causes loss of data.
9 Administering User Accounts and Groups Adding, modifying, and removing individual user accounts and groups of users is a routine but important activity that a system administrator frequently performs.
9.1.1 The Password File The passwd file for a standalone system identifies each user (including root) on your system. Each passwd file entry is a single line that contains seven fields. The fields are separated by colons and the last field ends with a new-line character. The syntax of each entry and the meaning of each field is as follows: username:password:user_id:group_id:user_info:\ login_directory:login_shell username The name for the user account.
login_directory The absolute pathname of the directory where the user account is located immediately after login. The login program assigns this pathname to the HOME environment variable. Users can change the value of the HOME variable, but if a user changes the value, then the home directory and the login directory are two different directories. Create the login directory after adding a user account to the passwd file. Typically the user’s name is used as the name of the login directory.
groupname The name of the group defined by this entry. The groupname consists of from one to eight alphanumeric characters and must be unique. password Place an asterisk (*) in this field. Entries for this field are currently ignored. group_id The group identification number (GID) for this group. This is an integer between 0 and 32767. Reserve the GID 0 for the system. The GID must be unique. user The user account belonging to this group as defined in the passwd file.
and enhanced security. The commands are documented in the following reference pages: useradd(8), usermod(8), userdel(8), groupadd(8), groupmod(8), and groupdel(8). • The adduser and addgroup utilities, documented in adduser(8) and addgroup(8). These utilities provide simple, interactive scripts you can use to add new user accounts and groups. These utilities can be used only on systems that do not use NIS.
2. Use the sysconfig command to set the following attribute to the proc subsystem of the /etc/sysconfigtab file: # enable_extended_uids=n Where the value of n is 1 to enable and 0 to disable Alternatively, you can use the dxkerneltuner graphical user interface to set this attribute. Refer to the dxkerneltuner(8) reference page, or see Section 5.2.1.2 for an example of its use. Extended UID and GID support is now enabled or disabled as required. 9.1.4.
only after all member systems have installed (or upgraded to) Version 1.5 of the appropriate TruCluster software product. To enable extended UID or GID support, set the enable_extended_uids parameter on every system as directed in this appendix and reboot every system. Do not use extended UIDs and GIDs on any member system until you have rebooted the last member system. Once you have enabled extended UID and GID support in a cluster, you must not disable it.
The vdump/vrestore Utilities and UFS File Systems If a UFS file system that contains quota files or other sparse files is backed up using the vdump utility and restored using the vrestore utility, the quota files or other sparse files will be restored as follows: • The first page of a file on disk will be restored as a fully populated page; that is, empty nonallocated disk blocks will be zero filled. • Any additional pages on disk will be restored sparse.
equivalent to dxaccounts. Refer to the adduser(8) reference page for more information. adduser enables you to script repetitive account management tasks and to create a number of new accounts simultaneously. • Using the dxaccounts graphical user interface. Refer to the online help for information on using this interface. • While adduser and dxaccountsare the preferred tools for adding a user account, you can also do it manually by editing system files. This task is documented in the following section.
To edit the passwd file: 1. Log in as root. 2. Enter the vipw command to add the required line entry to the passwd file: # vipw root:TZVtfX5VbS3KY:0:1:System PRIVILEGED Account,,,:/:/bin/sh daemon:*:1:daemon uucp:*:2:uucp . . . marcy:*:201:20:Marcy Swanson,dev,x1234:/usr/users/marcy:/bin/sh The previous example shows that user marcy has a UID of 201 and a GID of 20. The login directory is /usr/users/marcy and the Bourne shell (/bin/sh) is defined as the login shell.
Any statically linked application would be affected if it directly or indirectly calls any of the libc ndbm routines documented in the ndbm(3) reference page and then accesses the password database. To remedy this situation, you must re-link the application. If the mkpasswd -s option is avoided, you will not see this compatibility problem.
9.2.1.3 Providing the Default Shell Scripts Users can customize their working environment by modifying their startup files. When a user logs in to the system, the login shell looks for startup files in the login directory. If the shell finds a startup file, it reads the file and executes the commands. Table 9–1 displays each shell and the corresponding startup files. Table 9–1: Shells and Their Startup Files Shell System Startup File Login Startup Files /bin/csh /etc/csh.login .cshrc, .
Each password must have at least five characters, but not more than eight, and can include digits, symbols, and the characters of your alphabet. The password cannot be all lowercase characters. The passwd command encrypts the specified password and inserts it in the password field of the passwd file.
# grpck users:*:15:diaz,kalle,marcy,chris,farkle farkle - Logname not found in password file mem:*:3: Null login name 2 +: Too many/few fields 3 1 2 3 1 Refer to Section 9.2.1.1 for information on adding a user account to the passwd file. Ignore this message. Ignore this message. These characters are necessary for running NIS. Refer to the grpck(8) reference page for more information. The pwck command checks for any inconsistencies in the passwd file.
There may be times when a user forgets his or her password. If this happens, change the user’s password as described in Section 9.2.1.4 and tell the user the new password. 9.3.2 Changing the user_info Field The user_info field in the passwd file contains the name, room number, office phone, and home phone of the user.
The system responds with the following information. At the prompt, enter the new shell user marcy will be using. For example: Old shell: /bin/sh New shell: /bin/csh The next time user marcy logs in, she will be using the /bin/csh shell. 9.3.4 Setting File System Quotas If you configured your system with file system quotas (also called disk quotas), you can set a quota for the number of inodes or disk blocks allowed for each user account or group on your system.
9.3.4.2 Setting File System Quotas for User Accounts To set a disk quota for a user, you can create a quota prototype or you can use an existing quota prototype and replicate it for the user. A quota prototype is an equivalence of an existing user’s quotas to a prototype file, which is then used to generate identical user quotas for other users. Use the edquota command to create prototypes. If you do not have a quota prototype, create one by following these steps: 1.
9.4.1 Removing a User Account with the removeuser Utility The removeuser utility automates the process of removing a user account. This utility performs the following tasks: 1. Removes the user’s entry from the /etc/passwd file and any references to the user’s account from the /etc/group file 2. Searches several administrative directories and files for occurrences of the user and informs you if they exist 3.
9.4.3 Removing a User’s Files and Directories Before removing files or directories from the user’s account, follow these steps: 1. Make sure that the associated files and directories are not being used by other users on your system. 2. Back up the user’s login directory to diskette or tape. Refer to Chapter 11 for more information. To remove a user’s files and directories: 1.
To modify a group file entry: 1. Log in as root and change to the /etc directory. 2. Use the cp command to copy the group file to a temporary file. # cp group group.sav 3. Open the group file and remove the user’s name from each line entry in which it is listed. The screen displays a file similar to the following, which shows that user marcy is not a member of the users group: system:*:0:root,diaz daemon:*:1:daemon uucp:*:2:uucp . . . users:*:15:diaz,chris . . . 4. Close the file. 9.4.
9.5 Adding and Removing Groups This section describes how to: • Add a group with the addgroup utility • Add a group manually • Remove a group _______________________ Note _______________________ There are limits on length of command lines that may affect commands such as addgroup. The /usr/include/limits.h file limits LINE_MAX to 2048 characters. You must split command line entries into into multiple lines limited to 255 characters, or incorrect data may be added to the /etc/group file. 9.5.
To add a new group, add a line entry to the group file: 1. Log in as root and change to the /etc directory. 2. Use the cp command to copy the group file to a temporary file. For example, enter: # cp group group.sav 3. Open the group file and add the required line entry. Be sure to include all four fields in this entry.
10 Administering the Print Services This chapter describes how you set up and administer the files and programs that make up the Tru64 UNIX print services. You can set up and administer the print services immediately after a new installation or upgrade to a new version of the operating system, or you can wait until later. For example, you can wait until you have installed a printer and have gathered the information about its characteristics that you need to set it up.
• If you do not have a CDE Desktop graphics interface, or if you wish to continue to use current methods of print service administration, you can use the lprsetup utility to administer print services. The lprsetup utility will be retired in a future release of the operating system. • You can perform these tasks manually by creating and modifying the required files with a text editor. 10.2.
• The lpr command to send files to the printer • The lprm command to remove print jobs from the queue • The lpq command to check a print queue • The lpstat command to check a print queue (similar to lpq) Refer to the lprsetup(8), lpc(1), lpr(1), lprm(1), lpq(1), and lpstat(1) reference pages for more information about these commands.
lprsetup program updates the information in the /etc/printcap file using the information you supply. If your system is part of a network, you may need to consult your local network administrator about the correct procedure for adding a printer.
If this is the first printer connected to your system or a new printer added to an existing print system, create names that do not conflict with existing printer names. Ask your network administrator for the names of the remote printers on the network. 10.5.1.2 Printer Type The printer type corresponds to the product name of the printer, such as the LN03 laser printer. If you are using the lprsetup program, printers are listed by type and only those supported by Compaq are listed.
Table 10–1: Supported Printer Types (cont.) Printer Name Abbreviation HP LaserJet Model 4M hp4m any remote printer remote default printer unknown You can set up other printers by using ’unknown’ and then responding to the prompts, using values similar to those for supported printers. Responding with ’remote’ allows you to designate a remote system for printing.
Each synonym (including the printer number) identifies the printer to the print system. For example, if you chose the synonym ’draft’ for a printer, the following command prints files on this printer: $ lpr -Pdraft files 10.5.1.4 Device Special File The device special file provides access to the port on the computer to which the printer is connected. The device special file is used if the printer is directly connected to a local serial or parallel port.
system. Use the pac program to summarize information stored in the printer accounting files. This file must be owned by user daemon and group daemon, which it will be if you use the lprsetup program to specify the printer accounting file. The af parameter is not applicable for remote printer entries because the accounting policy for remote printers is employed at their (remote) systems. Accounting is accomplished through programs called print filters.
10.5.1.8 Connection Type The ct parameter specifies the type of connection to the printer. You can connect a printer directly to your computer from a port or terminal line. You can access networked printers that are connected to a LAT (Local Area Transport) terminal server or to a remote host.
You must have superuser privileges to run the lprsetup program.
Table 10–4 and to the printcap(4) reference page for information on the supported symbols. The following example shows how to use the lprsetup command to set up an LN03R printer to be used by the local system: # /usr/sbin/lprsetup Compaq Tru64 UNIX Printer Setup Program Command < add modify delete exit view quit help >: add Adding printer entry, type ’?’ for help.
xs Si fo Ss ic Ul nc Xf ps Da Dl It Lf Lu Ml Nu Or Ot Ps Sd Enter symbol name: q Printer #0 ---------Symbol type value ------ ---- ----af STR /usr/adm/lpacct br INT 9600 ct STR dev fc INT 0177777 fs INT 03 if STR /usr/lbin/ln03rof lf STR /usr/adm/lperr lp STR /dev/tty01 mc INT 20 mx INT 0 of STR /usr/lbin/ln03rof pl INT 66 pw INT 80 rw BOOL on sd STR /usr/spool/lpd xc INT 0177777 xf STR /usr/lbin/xf xs INT 044000 Are these the final values for printer 0 ? [y] y Next, the lprsetup script prom
:fs#03:\ :if=/usr/lbin/ln03rof:\ :lf=/usr/adm/lperr:\ :lp=/dev/tty01:\ :mc#20:\ :mx#0:\ :of=/usr/lbin/ln03rof:\ :pl#66:\ :pw#80:\ :rw:\ :sd=/usr/spool/lpd:\ :xc#0177777:\ :xf=/usr/lbin/xf:\ :xs#044000: Command < add modify delete exit view quit help >: exit Refer to the lprsetup(8) reference page for more information on using the program. 10.5.2.
If your printer will be connected to a remote LAT terminal server, ensure that the LAT subsets are installed as described in the Installation Guide. To see if the LAT subsets are installed, enter: # setld -i | grep OSFLAT See the Network Administration guide for information on how to enable remote LAT terminal server printing. 10.5.4 Testing Printers Test your printer by using the lpr command to print a few pages of text.
• Modifying characteristics of existing printers • Removing printers from the system • Enabling printer accounting • Controlling printer operations by using the lpc command Note that if you manually remove printers from the /etc/printcap file, you also have to remove spooling, accounting, and error directories and files. 10.6.1 Adding Printers Once you have one printer set up, you can add other printers at any time.
If you change the name of the spooling directory, the accounting file, or the error log file, lprsetup asks you to verify that the information is correct before it deletes the original information. To manually modify a printer’s configuration, edit the /etc/printcap file and modify the entry that pertains to the printer. Refer to Section 10.7.3 and to the printcap(4) reference page for information about the /etc/printcap file symbols. 10.6.
_______________________ Note _______________________ The /var/adm/printer directory should be owned by user adm and belong to group adm. The printer accounting files should have protection mode 644, be owned by user adm, and belong to group system. Refer to Chapter 12 for more information on using printer accounting. 10.6.5 Controlling Local Print Jobs and Queues Use the lpc command to manage the print jobs and queues associated with the local printers on your system.
Table 10–3: lpc Command Arguments lpc Argument Description help [argument] Prints a one-line description of the specified lpc command argument. If an argument variable is not specified, the list of arguments is displayed. ? [argument] Same as the help argument. abort Terminates an active lpd daemon and then disables printing. This prevents the lpr or lp command from starting a new lpd daemon.
Table 10–3: lpc Command Arguments (cont.) lpc Argument Description stop Stops a spooling daemon after the current job is complete and disables printing. topq printer Puts print jobs in the queue in the specified order. You can specify the print jobs by also specifying a request_ID variable or a username variable. up Enables all printing and starts a new printer daemon. Cancels the down argument.
• Uses specific print filters for print requests. Print filters translate an input format into a printer-specific output format. • After a system reboot, prints any files that were not printed when the system stopped operating. When you use the lpr command, the lpd daemon is activated, and the daemon copies the file to the printer’s spooling queue or directory. Requests are printed in the order in which they enter the queue.
10.7.2.1 Spooling Directory Files A spooling directory contains a status file and a lock file that are created by the lpd daemon when a file is queued for printing. The lock file contains control information about the current print process. For example, it can inform the lpd daemon that the printer is printing a job. The lock file prevents the lpd daemon from invoking another job on the printer while a file is printing.
mode must be set to 775. The directory’s group and ownership must be set to the name daemon. For example: # cd /var/spool/lpd # mkdir lp1 # chmod 775 lp1 # chgrp daemon lp1 # chown daemon lp1 # ls -l lp1 drwxr-xr-x 2 daemon daemon 24 Jan 12 1994 lp1 10.7.3 The /etc/printcap File The lpd daemon uses the /etc/printcap printer database file to print requests. Each entry in the file describes a printer. Printer characteristics are specified by two-letter abbreviations called symbols.
The callouts in the /etc/printcap entry show the following possible symbol syntaxes: 1 Specifies a symbol with alphabetic characters. 2 Specifies a symbol that represents a Boolean expression. 3 Specifies a symbol with a numeric value. 4 Specifies an entry for a remote printer. The lp, rm, rp, and sd symbols are required for remote printers for which you are a client. The first line of a printer entry contains the fields that specify the printer primary reference name and printer name synonyms.
Table 10–4: The printcap File Symbols Symbol Type Default Description af alphabetic NULL Name of accounting file br numeric none If lp is a tty, set the baud rate (ioctl call) cf alphabetic NULL The cifplot data output filter ct alphabetic NULL Connection typea df alphabetic NULL The TeX data filter (DVI format) dn alphabetic /usr/lbin/lpd Specifies a nonstandard daemon pathname du numeric none Specifies a nonstandard daemon UID fc numeric 0 If lp is a tty, clear flag bits (
Table 10–5: The printcap File Symbols, continued Symbol Type Default Description os alphabetic NULL Service name supported on some terminal servers pl numeric 66 Page length (in lines) pp alphabetic NULL The print command filter replacement ps alphabetic non_PS Indicates that the printer is PostScript pw numeric 132 Page width (in characters) px numeric 0 Page width in pixels (horizontal) py numeric 0 Page length in pixels (vertical) rf alphabetic NULL The FORTRAN-style te
Table 10–5: The printcap File Symbols, continued (cont.) Symbol Type Default Description xc numeric 0 If lp is a tty, clear local mode bits (tty) xs numeric 0 If lp is a tty, set local mode bits aIf the printer is a remote printer, a remote connection is used. You must use the rm symbol to specify the name of the machine to which the printer is attached. You must also specify the printer reference name with the rp symbol, as well as the lp and sd symbols 10.7.
customizations in backups. Using a file name prefix for new or modified PCF files will prevent potential file name conflicts. For example, copy file names before customizing as follows: #cp ln17.pcf my_ln17.pcf The print filter is located in /usr/lbin and the PCF printer specific files are in /usr/lbin/pcf. The file template.pcf provides documentation on the PCF file format. 10.7.
Table 10–6: Flag Bits Flag Octal Value Description OPOST 0000001 Enable output processing ONLCR 0000002 Map NL to CR-NL OLCUC 0000004 Map lower case to upper case OCRNL 0000010 Map CR to NL ONOCR 0000020 No CR output at column 0 ONLRET 0000040 NL performs CR function OFILL 0000100 Use fill characters for delay OFDEL 0000200 Fill is DEL, else NUL NLDLY 0001400 Newline delay NL0 0000000 NL1 0000400 NL2 0001000 NL3 0001400 TABDLY 0006000 TAB0 0000000 TAB1 0002000 TAB
Table 10–6: Flag Bits (cont.) Flag Octal Value BS1 0100000 OXTABS 1000000 Description Expand tabs to spaces Refer to the tty(7) reference page for detailed information on flag bits. 10.7.6 Mode Bits Mode bits specify details about the capability of a particular terminal and usually do not affect printer operation. Mode bits are cleared with the xc symbol and set with the xs symbol. Some printers use all of the mode bits, so you must either set them or clear them.
Table 10–7: Mode Bits (cont.) Mode Octal Value Description IEXTEN 0002000 Enable FLUSHO and LNEXT XCASE 0040000 Canonical upper/lower presentation 10.7.7 Remote Printer Characteristics If a printer will be used by users on remote machines, /etc/printcap files on the local machine attached to the printer and on the remote machines that will use the printer must contain some network configuration information.
pl#55 pw#70 You should not specify a width of more than 80 characters for a letter-quality printer that uses 8 1/2-inch by 11-inch paper. If you specify a width that is greater than 80 characters on a printer, the page prints in landscape mode. For high-resolution laser-type printers, the line length and page width parameters are py and px, which specify the number of pixels along the yand x-coordinate planes of the printer output image area.
• Use the lpc command to check on the status of the printer. If queues are stalled, try resetting the queues (refer to Section 10.6.5). • Ensure that the appropriate spooling or device files have been created and that ownership and access are correct (refer to Section 10.7.2). 10.8.2 Printer Error Logging The lpd daemon logs printer errors to the error log file. Specifying an error log file is optional. If you used lprsetup to install the printer, the program provides the default value /usr/adm/lperr.
10.9.1 Setting Up TCP/IP Printing The following steps describe how to set up TCP/IP printing on a local host. 1. Set up the printer. Assign a TCP/IP address and node name to each printer with a network card. Also, determine the TCP/IP socket number on which the printer will listen for connection requests. You will need the socket number in Step 2b when you edit the /etc/services file. Table 10–8 lists the socket numbers for three printers made by Compaq and one made by Hewlett Packard.
settings that are relevant to the serial port driver. These are ignored by the network socket driver. b. Configure the services database. You must register a service name and tcp port number (socket number) in the /etc/services database file. Enter the socket number that you determined when you configured the printer in step 1 and associate it with a service name of your choice.
In addition, printing non-PostScript files with some PostScript and non-PostScript filters may yield unexpected results. Table 10–9 lists the filters with which you could experience these problems.
11 Administering the Archiving Services One of the more common tasks of a system administrator is helping users recover lost or corrupted files. To perform that task effectively, you must set up procedures for backing up files at frequent and regular intervals.
• The btcreate and btextract utilities You can use these utilities to create and restore standalone, bootable tapes of the operating system and file systems. These capabilities are briefly surveyed in the following sections. Then, the archiving tasks are described. 11.1 NetWorker SingleServer Save and Restore NetWorker SingleServer Save and Restore is a graphical interface that enables you to back up and recover local files on a single machine to a local tape or loader.
between the members by defining NetWorker as a highly available application. By installing the NetWorker Server on each cluster member and configuring cluster members as NetWorker servers, NetWorker will automatically fail over as directed by the ASE manager.
Cross-platform bootable tapes are not supported. Using a bootable tape on a platform other than the one on which it was created is not supported. For example, you cannot create a tape on a 4100 system and boot from it on a 1000A system. 11.2.2 Using the btcreate Utility To build a bootable SAS kernel on UFS or AdvFS file systems only, you must use the btcreate utility. This section provides an overview of the information you must have to create the SAS kernel on tape.
• An addlist_file, which lists the files or directories you want to include on the miniroot file system. • An fslist_file, which specifies the file systems to back up. • A /usr/lib/sabt/sbin/custom_install.sh script, if you want to customize the restored system image. The file must be written in the Bourne shell language (sh1) as it is the only shell provided on the miniroot file system. The btcreate utility copies the custom_install.
# newfs /dev/rz1d 2. Change the current working directory to the /usr/sys directory: # cd /usr/sys 3. Make a SYSTEM.BOOTABLE directory under the /usr/sys directory, where SYSTEM is the system name FLAWLESS: # mkdir FLAWLESS.BOOTABLE 4. Mount the new partition on the SYSTEM.BOOTABLE directory: # mount /dev/rz1d /usr/sys/FLAWLESS.BOOTABLE The mounted device should have at least 75,000 512-blocks available 5. Create another new partition: # newfs /dev/rz1b 6.
partition information gathered during the btcreate session; all existing information is overwritten. Performing an ADVANCED restore, you can specify which disk partition to use, but the customized system can only be duplicated on a machine of the same hardware platform type.
A QIC tape created with the btcreate utility may fail with the following error when booted: failed to send Read to mka... / Be sure that the tape is write protected before booting. If you are creating a bootable tape with a UFS file system that extends to multiple tapes, the /sbin/dump command displays a message indicating that the tape must be changed. If the tape is not changed promptly, warning messages repeat periodically until the tape is changed. When you change the tape, the warning messages stop.
• TZ86, 5-1/4-inch cartridge 11.3 Backing Up Data It is important that all the files on your system, data files as well as system files, be protected from loss. Therefore, you should back up your entire system, including the system software. Most system files are static; that is, once they are installed they do not often change. Therefore, they do not need to be backed up as frequently as data files, which are dynamic, meaning they change constantly. Incremental backups are also possible.
user activity changes a file after the inode data is recorded, but before the file is backed up, the backup may be corrupted. To shut down the system, unmount a file system, and check the integrity of a file system: 1. Shut down the system. For example, to shut down the system in 5 minutes and give users periodic warning messages, enter: # /usr/sbin/shutdown +5 ’System going down to perform backups’ 2.
To integrate incremental backups into your file backup schedule, you need to balance the time and tape space required for backup against the amount of time it could take you to restore the system in the event of a system failure. For example, you could schedule backup levels following the 10-day sequence: 0 1 2 3 4 5 6 7 8 9 On the first day you save an entire file system (level 0). On the second day you save changes since the first backup and so on until the eleventh day when you restart the sequence.
The dump(8) reference page describes the command options that you use to specify the characteristics of the tape device, such as block size, tape storage density, and tape length. The following list describes the most commonly used options to the dump command: −integer Specifies the dump level as an integer (0-9). A dump level of 0 causes a full dump of the specified file system. All other dump levels cause an incremental backup.
For example, if you want to perform a level 0 dump of the root, /usr, and /projects file system partitions, follow these steps: 1. To back up the root file system, load a tape into your tape drive and enter: # dump -0u / After completing the backup, remove the tape from your tape drive. 2. To back up the /usr file system, load a new tape into your tape drive and enter: # dump -0u /usr After completing the backup, remove the tape from your tape drive. 3.
On Tuesday, perform a level 1 dump: # dump -1u /usr The level 1 dump backs up all the files that changed since Monday.
# rdump -0uf machine2:/dev/rmt0h /projects The dump(8) reference page describes the options to the rdump command. 11.3.5 Using Backup Scripts You can automate the backup process by using shell scripts. The cron daemon can execute these shell scripts late in the evening when there is less chance of the dump commands making errors due to a changing system.
command. Because the dump command saves a single file system at a time, you must execute the restore command for each file system you wish to restore. The restore command has the following command syntax: restore options The options parameter indicates the flags and arguments that you use to specify the characteristics of the tape device and special restore options. Refer to the restore(8) reference page for more information about these options.
-t ./.rhosts ./staff command will list the file and the directory. If you do not specify names, the restore command returns a complete listing of the backed up files on the tape. −x names The x (extract) flag restores from the tape the files and directories specified by the names argument. The names argument contains a list of files and directories to be restored from the tape. Specify names as ./filename . For example, the restore -x ./.rhosts ./staff command will restore the .rhosts file and the .
restore -Yrf dump_file If the disk does not have a label, write the label by using the disklabel command before you create the new file system. Use the following command syntax to determine if the disk has a label: disklabel -r disk Writing a label with customized partition table settings may affect the entire disk. Use the following command syntax to write the default disk partition table: disklabel -rw disk disk_type The disk parameter specifies the disk that includes the device mnemonic and unit number.
By asking when the file was lost and when it was last modified, you can use your backup log to determine which tape contains the most recent version of the wanted file. Use the −t option with the restore command to determine whether a file is on the selected tape. Use the following syntax: restore -t ./ filename The −t option creates a list of files and directories on the tape that matches the ./filename argument.
# restore -xs 3 ./working/old.file 11.4.3 Restoring Files Interactively To ease the task of restoring multiple files, use the −i option to the restore command. This option starts an interactive restore session. The interactive mode has commands similar to shell commands.
answer yes when you are restoring the entire root directory. setmodes Sets owner, access modes, and file creation times for all directories that have been added to the files-to-read list; no files are recovered from the tape. Use this command to clean up files after a restore command has been prematurely aborted. verbose Toggles verbose mode. In verbose mode, each file name is printed to the standard output. By default, verbose mode is set to off.
5. You are prompted for the logical volume you want to mount; usually you respond to this prompt with 1. You have not read any tapes yet. Unless you know which volume your file(s) are on you can start with the last volume and work towards the first. Specify next volume #: 1 You are then asked whether the extract affects the access modes of the dot (.). For this example, reply with n. set owner/mode for ’.’? [yn] n 6. Once the files are extracted, quit the interactive session.
The options for the rrestore command are the same as for the restore command. See Section 11.4 for a description of the options. To restore the ./working/file1 file onto the local directory on machine1 from a backup tape mounted on machine2 where the backup device /dev/rmt0h is attached, enter the following command from machine1. The name machine1 must be in the /.rhosts file of machine2 to allow access from machine1 to machine2. # rrestore -xf machine2:/dev/rmt0h .
4. Create the special files for the root file system device and dump file device. • If you are restoring dump files from a local system, change to the /dev directory and use the MAKEDEV command with the following command syntax: MAKEDEV mnemonic The mnemonic parameter refers to a device mnemonic. See Appendix A for a list of the supported device mnemonics. For example, to create the special files for an RZ57 disk, unit number 0, and a TLZ06 tape, unit number 5, enter: # cd /dev # .
for the system localsystem, with an Internet address of 120.105.5.1, connected by an Ethernet interface to the remote system remotesystem, with an Internet address of 120.105.5.2: # # # # cd /etc echo "127.0.0.1 localhost" >> hosts echo "120.105.5.2 remotesystem" >> hosts ifconfig ln0 120.105.5.1 netmask 0xfffffc00 Some older systems broadcast all 0s instead of all 1s. In this situation, you must also specify the broadcast address. 5. Change to the root directory. # cd / 6.
The raw_device parameter specifies the full raw device pathname of the disk device on your system. For example, to create a new file system on an RZ57, unit 0, enter: # newfs /dev/rrz0a 8. Mount the file system by using the following command syntax: mount block_device [ /mnt] The block_device parameter specifies the full block device pathname of the disk device. For example, to mount the file system created in the previous step, enter: # mount /dev/rz0a /mnt 9.
# cd / # umount /mnt 11. Restore the /usr file system. • If the /usr file system is on the same device as root, the process is similar to steps 7 through 10. To restore the /usr file system on the g partition of the same device as the root file system from the same tape device, enter the following sequence of commands. If you are using AdvFS, this step will not work. Use the procedure in step 11a. # # # # # # newfs /dev/rrz0g mount /dev/rz0g /mnt cd /mnt restore -Yrf /dev/rmt0h cd / umount /mnt a.
13. Boot the system as described for your processor and distribution media in the Installation Guide. 11.4.5.1 Local Restoration Example The following text-based example shows a portion of the restoration procedure for the root and /usr file systems to an RZ57, unit 0, from a TLZ06, unit 5. The backslashes in this example indicate line continuation and are not in the actual display. . . .
# newfs /dev/rrz0g Warning: 105 sector(s) in last cylinder unallocated /dev/rrz0g: 614400 sectors in 577 cylinders of 15 tracks, 71 \ sectors 314.6MB in 37 cyl groups (16 c/g, 8.
21.0MB in 3 cyl groups (16 c/g, 8.72MB/g, 2048 i/g) super-block backups (for fsck -b #) at: 32, 17152, 34272, # mount /dev/rz0a /mnt # cd /mnt # rsh remotesystem "dd if=/dev/rmt0h bs=10k" | restore -Yrf 1743+0 records in 1743+0 records out # cd / # umount /mnt # newfs /dev/rrz0g Warning: 105 sector(s) in last cylinder unallocated /dev/rrz0g: 614400 sectors in 577 cylinders of 15 tracks, 71 314.6MB in 37 cyl groups (16 c/g, 8.
12 Administering the System Accounting Services This chapter describes how to set up and use the system accounting services. The accounting services are shell scripts and commands you use to manipulate an accounting database to obtain a diagnostic history of system resource use and user activity and to create report files.
File Description wtmp The login/logout history file utmp The active connect session file pacct The active process accounting file dtmp The disk usage file The accounting scripts and commands access the records in the accounting database files and reformat them so that you can use the records for purposes such as archiving, diagnostic analysis, or resource billing.
Table 12–1: Accounting Commands and Shell Scripts Name Type Description ac Command Displays connect session records. acctcms Command Formats the binary command usage summary files. acctcom Command Displays process accounting record summaries from the default pacct database file or a specified file. acctcon1 Command Summarizes the records in the wtmp file in ASCII format. acctcon2 Command Summarizes the contents of the files formatted by the acctcon1 command.
Table 12–1: Accounting Commands and Shell Scripts (cont.) Name Type Description nulladm Script Creates files that are owned by the adm user and group and that have 664 permission. pac Command Displays printer accounting records. prctmp Script Displays the /var/adm/acct/nite/ctmp connect session record file. prdaily Script Collects and displays daily accounting records from various files. printpw Command Displays the contents of the /etc/passwd file.
Accounting files can become corrupted or lost. The files that are used to produce daily or monthly reports, such as the /var/adm/wtmp and /var/adm/acct/sum/tacct accounting database files, must have complete integrity. If these files are corrupted or lost, you can recover them from backups. In addition, you can use the fwtmp or the wtmpfix command to correct the /var/adm/wtmp file. Refer to Section 12.4.2 and Section 12.4.1 for more information.
Table 12–2: Database Files in the /var/adm Directory (cont.) Name Type Description Spacctn.mmdd Binary Specifies the pacctn files produced by the runacct shell script for the month and day specified by mm and dd, respectively. usracct Binary Specifies the file used by the sa command to store user process accounting summary records. utmp Binary Specifies the active connect session accounting database file, which is written to if a user calls a process that produces a connect session.
Table 12–3: Daily Files in the /var/adm/acct/nite Directory (cont.) Name Type Description ctacct.mmdd Binary Specifies the connect accounting records in tacct.h format that are obtained from the connect session accounting records for the month and day specified by mm and dd, respectively. This file is temporary and is deleted after the daytacct file records are written for each accounting period. ctmp ASCII Specifies the temporary login/logout record file.
Table 12–3: Daily Files in the /var/adm/acct/nite Directory (cont.) Name Type Description reboots ASCII Contains a list of system reboots during the previous accounting period. statefile Binary Specifies the final runacct shell script execution state. wtmp.mmdd Binary Specifies the fixed daily login/logout accounting database file for the month and day specified by mm and dd, respectively.
Table 12–4: Summary Files in the /var/adm/acct/sum Directory (cont.) Name Type Description tacctmmdd Binary Specifies the total accounting file for the month and day specified by mm and dd, respectively. tacctprev Binary Specifies the previous day’s tacct file. This file is the tacct binary file for the previous accounting period.
3. Edit the /usr/sbin/acct/holidays file to specify prime time, nonprime time, and holidays. 4. To enable automatic accounting, modify the files in the /usr/spool/cron/crontabs directory to invoke accounting shell scripts and commands. Resource accounting is discussed separately from printer accounting because the print driver software uses different servers, daemons, and routines. Setting up printer accounting is described in Chapter 10. 12.2.1 Enabling Accounting in the rc.
12.2.4 Modifying crontab Files To enable automatic accounting, you must use the crontab command to modify the files in the /usr/spool/cron/crontabs directory. The files in the /usr/spool/cron/crontabs directory contain commands that the cron daemon runs at specified times under a specific authority. For example, the commands in the /usr/spool/cron/crontabs/root file are run under root authority, and the commands in the /usr/spool/cron/crontabs/adm file are run under adm authority.
The following example shows part of a /usr/spool/cron/crontabs/adm file that includes accounting commands and shell scripts: 0 2 * * 1-6 /usr/sbin/acct/runacct > /usr/adm/acct/nite/fd2log& 5 * * * * /usr/sbin/acct/ckpacct& 0 4 1 * * /usr/sbin/acct/monacct& 10 3 * * * /usr/sbin/ac -p > /var/adm/timelog& 40 2 * * * /usr/sbin/pac -s& The following example shows part of a /usr/spool/cron/crontabs/root file that includes the dodisk shell script: 0 3 * * 4 /usr/sbin/acct/dodisk > /var/adm/diskdiag& 12.
12.4 Connect Session Accounting When a user logs in or logs out, the login and init commands write the user login and logout history to records in the /var/adm/wtmp binary database file. The /var/adm/utmp binary database file is the active connect session file. All hangups, terminations of the login command, and terminations of the login shell cause the system to write logout records, so the number of logouts is often more than the number of sessions.
Command Description last This command displays login information. lastlogin This shell script updates the /var/adm/acct/sum/loginlog file to show the last date that each user logged in. prctmp This shell script displays the contents of the session-record file (usually /var/adm/acct/nite/ctmp) that the acctcon1 command created.
Table 12–6: The utmp ASCII Conversion Structure Members (cont.) Field Member Description 8 ut_time The starting time (in seconds). 9 ut_host The host name, which must have exactly sizeof(ut_host) characters. 12.4.1 The wtmpfix Command The /usr/sbin/acct/wtmpfix command corrects date and time stamp inconsistencies in files with the utmp.h header file structure and displays the records. The runacct script invokes the wtmpfix command.
During system operation, date changes and reboots occur, and the records are written to the /var/adm/wtmp file. The wtmpfix command adjusts the time stamps in the /var/adm/wtmp file; however, some corrections can evade detection by the wtmpfix command and cause the acctcon command to fail. In this case, you can correct the /var/adm/wtmp file by using the fwtmp command.
12.4.3 The acctwtmp Command The acctwtmp command allows you to write a reason string and the current time and date to a utmp.h structured file, usually the /var/adm/wtmp file. The runacct, startup, and shutacct shell scripts invoke the acctwtmp command to record when the runacct script is invoked and when system accounting is turned on and off.
hoff hermi total 200.43 157.81 1968.02 The total connect time for all users listed is shown in the last line. 12.4.5 The acctcon1 Command The acctcon1 command converts binary session records from a file with the utmp.h header file structure to ASCII format. A single record is produced for each connect session. The runacct shell script uses the acctcon1 command to create the lineuse and reboots files, which are included in the /var/adm/acct/sum/rprtmmdd daily report.
You can compare the last column to the fourth column to determine if a line is bad. The following example produces a sample /var/adm/acct/reboots file. It writes records to a file in ASCII overall-record format, which specifies a starting time, an ending time, the number of restarts, and the number of date changes.
The runacct shell script invokes the lastlogin shell script during its CMS state. You can invoke the lastlogin shell script manually to update the /var/adm/acct/sum/loginlog file, which is included in the /var/adm/acct/sum/rprtmmdd daily report. The lastlogin shell script has the following syntax: /usr/sbin/acct/lastlogin 12.4.9 The last Command The last command displays, in reverse chronological order, all login records in the /var/adm/wtmp file.
The /var/adm/pacct file will grow in size. The ckpacct command checks the size of the /var/adm/pacct file and creates a /var/adm/pacctn file if the pacct file is larger than a specified size.
Table 12–7: The tacct File Format (cont.) Column Heading Description 6 NPRI_MEM Specifies the nonprime time memory kcore minutes, which is the total CPU time (in minutes) multiplied by the mean size of the memory used. 7 PRI_RD/WR Specifies the total number of characters transferred during prime time operation. 8 NPRI_RD/WR Specifies the total number of characters transferred during nonprime time operation.
commands. The following sections describe the process accounting shell scripts and commands. 12.5.1 The accton Command The accton command enables and disables process accounting. The accton command has the following syntax: /usr/sbin/acct/accton [ filename] If you do not specify the filename variable, process accounting is disabled. If you specify the filename variable, process accounting is turned on and the kernel writes process accounting records to the specified file.
ckpacct script invokes the turnacct switch shell script to move the contents of the /var/adm/pacct file to the /var/adm/pacctn file and create a new /var/adm/pacct file. You can set up your cron daemon to invoke the ckpacct script periodically. Refer to Section 12.2.4 for more information. The ckpacct shell script has the following syntax: ckpacct [ blocksize] The blocksize variable specifies the size limit (in disk blocks) for the /var/adm/pacct file. The default size is 500 disk blocks.
If you do not specify any command options, the default output includes the following information in a column heading format: • Time and date that accounting was enabled • Command name • User name • tty name • Process start time • Process end time • Real seconds • CPU seconds • Mean memory size (in kilobytes) Refer to the acctcom(8) reference page for information on the command options.
If you invoke the sa command with no options, the default output consists of six unheaded columns. Certain command options allow you to expand the six columns to include more information. You can specify options to change the format and to output additional information that includes an identifying suffix. Refer to the sa(8) reference page for information on the command options. The following example shows the default format of the output of the sa command: # /usr/sbin/sa 798 277.24re 7 33.42re 14 0.
38 2 26 24 5.89% 0.31% 4.03% 3.72% 1 0.33re 0.01re 0.11re 0.10re 2 0.10% 0.00% 0.03% 0.03% 0.00cpu 0.00cpu 0.00cpu 0.00cpu 3 0.00% 0.00% 0.00% 0.00% 163357avio 132992avio 136832avio 139824avio 0k 0k 0k 0k cp cat chmod chgrp The additional columns show the following information: 1 2 3 Indicates the number of times each command was executed with respect to the total number of times all commands were executed.
than 80 characters, and the entire width of 8.5 x 11-inch paper could be used if the 10-character per inch constant-width font is specified. If part of a record exceeds the column width, it is moved to the next line.
The command output specifies information in a format with seven unheaded columns that specify the following: • User identification number • Login name • Number of CPU seconds the process used during prime time • Number of CPU seconds the process used during nonprime time • Total number of characters transferred • Total number of blocks read from and written to • Mean memory size (in kilobytes) The following is an example of the acctprc1 command and its output: # /usr/sbin/acct/acctprc1 < /usr/
• Name of the user who issued the command • Terminal from which the command was started • Number of seconds of CPU time used • Time the process started The lastcomm command has the following syntax: /usr/bin/lastcomm [ command] [ username] [ tty] The following example displays information about the sed commands executed by root: # lastcomm sed root sed S root sed S root ttyp0 ttyp0 0.01 secs Fri Jan 21 11:34 0.01 secs Fri Jan 21 11:34 12.
AdvFS fileset. If the −o option is not specified, the variable must be the raw or character device special file. For example: # /usr/sbin/acct/dodisk /dev/rrz3c If you do not specify any arguments, disk accounting is performed on the UFS device special files decribed in the /etc/fstab database file. Refer to the fstab(4) reference page for more information.
1 2 4 5 322 521 943 1016 1098 daemon bin adm uucp homer whistler cellini pollock hopper 84 71144 976 3324 2 2 363 92 317 You must specify the raw device special file for filesystem (for example, /dev/rrz3c). A file system must exist on the target device. 12.6.3 The acctdusg Command The acctdusg command performs more thorough disk accounting than the diskusg command. If dodisk is invoked with the −o option, the acctdusg command is used to create the /var/adm/dtmp file.
identification number. The acctdusg command does not display the disk-block count for empty directories. 12.6.4 The acctdisk Command The acctdisk command creates a binary total accounting file. If it is invoked from the dodisk script, the acctdisk command reads the /var/adm/dtmp file that is produced by either the diskusg or acctdusg command. It then writes converted binary records to a temporary file, which is then moved to the /var/adm/acct/nite/dacct file.
# chargefee josh 7 If the previous command is issued, the following record is written to the /var/adm/fee file: 1114 josh 0 0 0 0 0 0 0 0 0 0 0 0 7 0 0 0 12.8 Printer Accounting When you use a printer that has accounting enabled, a record is written to the printer accounting file.
Command Description runacct This shell script creates the daily and summary files in the /var/adm/acct/nite and /var/adm/acct/sum directories. acctmerg This command merges total accounting record files and allows you to combine process connect time, fee, disk usage, and print queue accounting records into files whose format you specify. The output can be in either the default binary format or ASCII format and can include up to 18 columns of accounting information.
/var/adm/acct/nite/lock file exists, the runacct shell script will not run. The runacct shell script executes in the following 13 states, in the order listed, and can be restarted at any of the 13 states: State Description SETUP Sets up some of the accounting files. WTMPFIX Fixes corrupted date and time stamp entries that can cause commands such as the acctcon1 command to fail. CONNECT1 Writes connect session records.
Fri Feb 4 11:02:56 EST 1994 -rw-r--r-- 1 adm adm 0 Jan 31 03:00 /var/adm/acct/nite/dacct -rw-rw-r-- 1 root system 924 Jan 05 10:45 /var/adm/wtmp -rw-rw-r-- 1 adm adm 0 Jan 08 13:46 fee -rw-rw-r-- 1 adm adm 0 Jan 07 02:00 pacct -rw-rw-r-- 1 adm adm 8904 Jan 02 11:02 pacct1 files setups complete wtmp processing complete connect acctg complete process acctg complete for /var/adm/Spacct1.1101 process acctg complete for /var/adm/Spacct2.
In the following example, the runacct shell script is invoked at its MERGE state and uses the accounting database files from January 26: # runacct 0126 MERGE > /var/adm/nite/fd2log& The following example invokes the runacct shell script, which uses the accounting database files from January 26 and specifies the nohup command so that signals, hangups, logouts, and quits are disregarded; any error messages generated during its execution are written to the fd2log file: # nohup runacct 0126 > /var/adm/acct/nit
ERROR: invalid state, check /usr/var/adm/nite/active During processing, the runacct shell script may have detected a corrupted active file. Check the /var/adm/acct/nite/active* and statefile files. 12.9.2 The acctmerg Command The acctmerg command combines process, connect time, fee, disk-usage, and queue total accounting record files with the tacct file format.
2. Enter the prtacct command to display the /var/adm/sum/tacctprev file. If the file is correct, then the problem probably is located in the /var/adm/sum/tacctmmdd file. This example assumes that the /var/adm/sum/tacctmmdd file needs to be fixed. 3. To obtain an ASCII version of the /var/adm/sum/tacctmmdd file, enter: # acctmerg −v < tacct.0617 > tacct_temp 4. Edit the temporary file and correct the records as necessary. 5.
• /var/adm/acct/nite/daycms • /var/adm/acct/nite/cms • /var/adm/acct/sum/loginlog The prdaily shell script has the following syntax: prdaily [-l [ mmdd]] | [-c] Refer to prdaily(8) for more information on command options. 12.9.5 The monacct Shell Script The monacct shell script uses the binary accounting files to create cumulative summary files in the /var/adm/acct/fiscal directory.
13 Administering Events and Errors This chapter provides information on the following topics: • Event logging, which is a way to record informational and error messages that are generated by the system. You use the event logs to solve system problems or verify system operations and you can configure event logging to select events in which you have a particular interest. Understanding and configuring the event-logging facilities is described in Section 13.1 and Section 13.2.
13.1.1 System Event Logging The primary systemwide event-logging facility uses the syslog function to log events in ASCII format. The syslog function uses the syslogd daemon to collect the messages that are logged by the various kernel, command, utility, and application programs. The syslogd daemon logs the messages to a local file or forwards the messages to a remote system, as specified in the /etc/syslog.conf file. When you install your Tru64 UNIX operating system, the /etc/syslog.
For information about administering the DECevent utility, see the following Tru64 UNIX documentation: • DECevent Translation and Reporting Guide • dia(8) A new anlysis utility that supports recent processors only is provided in Tru64 UNIX. Compaq Analyze is designated to be the replacement for uerf in EV6–series processors. See the Compaq Analyze Installation Guide for Compaq Tru64 UNIX which can be found on the Associated Products CD-ROM.
# # syslogd config file # # facilities: kern user mail daemon auth syslog lpr binary # priorities: emerg alert crit err warning notice info debug # # 1 2 3 kern.debug /var/adm/syslog.dated/kern.log user.debug /var/adm/syslog.dated/user.log daemon.debug /var/adm/syslog.dated/daemon.log auth.crit;syslog.debug /var/adm/syslog.dated/syslog.log mail,lpr.debug /var/adm/syslog.dated/misc.log msgbuf.err /var/adm/crash.dated/msgbuf.savecore kern.debug /var/adm/messages kern.debug /dev/console *.
Facility Description kern Messages generated by the kernel. These messages cannot be generated by any user process. user Messages generated by user processes. This is the default facility. mail Messages generated by the mail system. daemon Messages generated by the system daemons. auth Messages generated by the authorization system (for example: login, su, and getty). lpr Messages generated by the line printer spooling system (for example: lpr, lpc, and lpd).
Destination Description Full pathname Appends messages to the specified file. You should direct each facility’s messages to separate files (for example: kern.log, mail.log, or lpr.log). Host name preceded by an at sign (@) Forwards messages to the syslogd daemon on the specified host. List of users separated by commas Writes messages to the specified users if they are logged in. * Writes messages to all the users who are logged in. You can specify in the /etc/syslog.
13.2.1.2 The binlog.conf File If you want the binlogd daemon to use a configuration file other than the default, specify the file name with the binlogd -f config_file command. The following is an example of a /etc/binlog.conf file: # # binlogd configuration file # # format of a line: event_code.priority destination # # where: # event_code - see codes in binlog.
Class Code General * All event classes. dumpfile Specifies the recovery of the kernel binary event log buffer from a crash dump. A severity level cannot be specified.
Class Code Operational Events 350 Diagnostic status messages 351 Repair and maintenance messages You can specify the following severity levels: Severity Level Description * All severity levels severe Unrecoverable events that are usually fatal to system operation high Recoverable events or unrecoverable events that are not fatal to system operation low Informational events You can specify the following destinations: Destination Description Full pathname Specifies the file name to which th
daemons are started. You can also specify options with the command that starts the daemons. Refer to the init(8) reference page for more information. 13.2.3.1 The syslogd Daemon You must ensure that the syslogd daemon is started by the init program. If the syslogd daemon is not started or if you want to specify options with the command that starts the syslogd daemon, you must edit the /sbin/init.d/syslog file and either include or modify the syslogd command line.
specified in the /etc/syslog.conf file. The syslogd daemon then sends the messages to the destinations specified in the file. To stop the syslogd event-logging daemon, use the following command: # kill ‘cat /var/run/syslog.pid‘ You can apply changes that you make to the /etc/syslog.conf configuration file without shutting down the system by using the following command: # kill -HUP ‘cat /var/run/syslog.pid‘ 13.2.3.2 The binlogd Daemon You must ensure that the init program starts the binlogd daemon.
You can apply changes that you make to the /etc/binlog.conf configuration file without shutting down the system by using the following command: # kill -HUP ‘cat /var/run/binlogd.pid‘ 13.2.4 Configuring the Kernel Binary Event Logger You can configure the kernel binary event logger by modifying the default keywords and rebuilding the kernel. You can scale the size of the kernel binary event-log buffer to meet your systems needs.
13.3 Recovering Event Logs After a System Crash You can recover unprocessed messages and binary event-log records from a system crash when you reboot the system. The msgbuf.err entry in the /etc/syslog.conf file specifies the destination of the kernel syslog message buffer msgbuf that is recovered from the dump file. The default /etc/syslog.conf file entry for the kernel syslog message buffer file is as follows: msgbuf.err /var/adm/crash/msgbuf.savecore The dumpfile entry in the /etc/binlog.
You can also use the cron daemon to specify that log files be deleted. The following is an example of a crontab file entry: 5 1 * * * find /var/adm/syslog.dated -type d -mtime +5 -exec rm -rf ’{}’ \; This command line causes all directories under /var/adm/syslog.dated that were modified more than five days ago to be deleted, along with their contents, every day at 1:05. Refer to the crontab(1) reference page for more information. 13.
potentially fill your disk because the files are not overwritten when new core files are created. If you enable this feature, make sure you remove old core files when you have finished examining them.
Crash dump files are required for analysis when a system crashes, or during the development of custom kernels (debugging). You may also have to supply a crash dump file to Technical Support to analyze system problems. To do this, you must understand how crash dump files are created. You must reserve space on disks for the crash dump and crash dump files. The amount of space you reserve depends on your system configuration and the type of crash dump you want the system to perform.
• dbx(1) - Describes the source level debugger. 13.6.2 Files Created and Used During Crash Dumps By default, the savecore command copies crash dump file into /var/adm/crash, although you can redirect crash dumps to any file system that you designate. The following files are created or used during a crash: • /var/adm/crash/vmzcore.n – The crash dump file, named vmcore.
copy of the kernel into files in the default crash directory, /var/adm/crash. (You can modify the location of the crash directory.) The savecore command stores the kernel image in a file named vmunix.n, and by default it stores the (compressed) contents of physical memory in a file named vmzcore.n. The n variable specifies the number of the crash. The number of the crash is recorded in the bounds file in the crash directory.
problem that caused the crash, particularly if the crash was due to a hardware error. The savecore command saves the binary event buffer in the /usr/adm/crash/binlogdumpfile file by default. You can change the location to which savecore writes the binary event buffer by modifying the dumpfile entry in the /etc/binlog.conf file. If you remove the dumpfile entry from the /etc/binlog.conf file, savecore does not save the binary event buffer.
partitions are full. It then writes the remaining crash dump information to end of the primary swap partition, possibly filling that partition. _______________________ Note _______________________ If the aggregate size of all the swap partitions is too small to contain the crash dump, the system creates no crash dump. Each crash dump contains a header, which the system always writes to the end of the primary swap partition.
You can control the default location of the crash directory with the rcmgr command. For example, to save crash dump files in the /usr/adm/crash2 directory by default (at each system startup), issue the following command: # /usr/sbin/rcmgr set SAVECORE_DIR /usr/adm/crash2 If you want the system to return to multiuser mode, regardless of whether it saved a crash dump, issue the following command: # /usr/sbin/rcmgr set SAVECORE_FLAGS M 13.6.
raise the value so that the system writes crash dumps to secondary partitions, issue the following command: # sysconfig -r generic dump_sp_threshold=20480 In this exampe, the dump_sp_threshold attribute, which is in the generic subsystem, is set to 20,480 512-byte blocks (40 MB). In this example, the system attempts to leave the entire primary swap partition completely open for system swapping.
13.6.5 Generating a Crash Dump Manually You can manually create a crash dump file by forcing a dump using the console command, crash, which causes a crash dump file to be created on a system that is not responding (hung). It is assumed that you have planned adequate space for the crash dump file and set any kernel parameters as described in the preceding sections. On most hardware platforms, you force a crash dump by performing the following steps: 1.
To compress a vmcore.n crash dump file, use a utility such as gzip, compress, or dxarchiver. For example, the following command creates a compressed file named vmcore.3.gz % gzip vmcore.3 A vmzcore.n crash dump file uses a special compression method that makes it readable by the current Tru64 UNIX debuggers and crash analysis tools without requiring decompression. A vmzcore.n file is substantially compressed compared to the equivalent vmcore.
This situation occurs because the original vmcore.n file contains UNIX File System (UFS) file holes, which are regions that have no associated data blocks. When a process, such as the gunzip or uncompress command reads from a hole in a file, the file system returns zero-valued data. Thus, memory omitted from the partial dump is added back into the uncompressed vmcore.n file as disk blocks containing all zeros.
The loadable kernel module does not include platform specific code (such as the location of status registers). It is transparent to the kernel module which options are supported by a platform. That is, the kernel module and platform are designed to return valid data if an option is supported, a fixed constant for unsupported options, or null. 13.7.1.1.1 Specifying Loadable Kernel Attributes The loadable kernel module exports the parameters listed in Table 13–1 to the kernel configuration manager (CFG).
The get_info() function obtains dynamic environmental data using the function types described in Table 13–2. Table 13–2: get_info() Function Types Function Type Use of Function GET_SYS_TEMP Reads the system’s internal temperature on platforms that have a KCRCM module configured. GET_FAN_STATUS Reads fan status from error registers. GET_PS_STATUS Reads redundant power supply status from error registers.
For each Server System MIB variable listed in Table 13–3, code is provided in the subagent daemon, which accesses the appropriate parameter from the kernel module through the CFG interface. 13.7.1.2 Monitoring Environmental Thresholds To monitor the system environment, the envmond daemon is used. You can customize the daemon by using the envconfig utility or customize the messages that are broadcast. The following sections discuss the daemon and utility.
• Turn environmental monitoring on or off during the system boot. • Start or stop the envmond daemon after the system boot. • Specify the frequency between queries of the system by the envmond daemon. • Set the highest threshold level that can be encountered before a temperature event is signaled by the envmond daemon. Specify the path of a user defined script that you want the envmond daemon to execute when a high threshold level is encountered.
may prevent the correct transmission of warning messages if a system problem occurs.
A Device Mnemonics This appendix identifies and defines the mnemonics that you use to attach any hardware or software device to your system. You specify the mnemonics with the MAKEDEV command to create the character or block special files that represent each of the devices. You also use the mnemonics to specify device special files for the loadable drivers described in the /etc/sysconfigtab configuration database file.
Table A–1: Device Mnemonics Category Mnemonic Description Generic std Standard devices with all console subsystems drum Kernel drum device kmem Virtual main memory mem Physical memory null A null device trace A trace device tty A tty device local Customer-specific devices Prestoserve nvtc DEC 3000 Model 300, DEC 3000 Model 400, DEC 3000 Model 500, DEC 3000 Model 600, DEC 3000 Model 800 Consoles console System console interface Disks rz* SCSI disks. Refer to the rz(7) and ddr.
B SCSI/CAM Utility Program B.1 Introduction The SCSI/CAM Utility Program, scu, interfaces with the Common Access Method (CAM) I/O subsystem and the peripheral devices attached to Small Computer System Interface (SCSI) busses. This utility implements the SCSI commands necessary for normal maintenance and diagnostics of SCSI peripheral devices and the CAM I/O subsystem. The format of a SCU command is as follows: scu> [-f device-name-path] [ command [ keyword]...
Convention Meaning keyword ( alias ) Use a keyword or the specified alias. address-format Optionally accepts an address format. nexus-information Optionally accepts nexus information. test-parameters Optionally accepts test parameters. D: value or string The value or string shown is the default. R: minimum-maximum Enter a value within the range specified. The address-format parameter is optional.
{ limit n } { records n } The alias bs (block size) is accepted for the size keyword. The test-control parameters control aspects of the test operation. The test-control parameters supported are: { { scu> command [ { errors Error-Limit { { { align Align-Offset } compare { on | off } } }] passes Pass-Limit } pattern Data-Pattern } recovery { on | off } } B.3 General SCU Commands This section describes the general-purpose scu utility commands.
exit You use this command to exit from the program. You can use quit as an alias for exit. You can terminate the program in interactive mode by entering the end-of-file character (usually Ctrl/d). help [topic] This command displays help information on topics. You can use a question mark (?) as an alias. If you issue the help command without specifying a topic, a list of all available topics is displayed.
0x39c39c39... scu> scan media lba 200 limit 25k align ’lp-1’ Scanning 50 blocks on /dev/rrz10c (RX23) with pattern 0x39c39c39... scu> scan media starting 0 bs 32k records 10 Scanning 640 blocks on /dev/rrz10c (RX23) with pattern 0x39c39c39... Scanning blocks [ 0 through 63 ]... Scanning blocks [ 64 through 127 ]... Scanning blocks [ 128 through 191 ]... Scanning blocks [ 192 through 255 ]... Scanning blocks [ 256 through 319 ]... Scanning blocks [ 320 through 383 ]... Scanning blocks [ 384 through 447 ]...
sourceinput-file This command allows you to source input from an external command file. If any errors occur during command parsing or execution, the command file is closed at that point. The default file name extension .scu is appended to the name of the input file if no extension is supplied. If the scu utility cannot find a file with the .scu extension, it attempts to locate the original input file. switch [device-name] This command accesses a new device or a previous device.
prevent This command prevents media removal from the selected device. release {device | simqueue} [nexus-information] This command releases a reserved SCSI device or releases a frozen SIM queue after an error. The device argument specifies a reserved SCSI device to be released. The extent release capability for direct access devices is not implemented. The simqueue argument issues a release SIMQ CCB to thaw a frozen SIM queue.
start This command issues a SCSI Start Unit command to the selected device. This action enables the selected device to allow media access operations. stop This command issues a SCSI Stop Unit command to the selected device. This action disables the selected device from allowing media access operations. tur This command issues a Test Unit Ready command to determine the readiness of a device. If the command detects a failure, it automatically reports the sense data.
• On failure, the failing logical block number (LBN) is reported and verification continues with the block following the failing block. • By default, verification is performed using the current parameters in the Error Recovery mode page. You can disable drive recovery by using the set recovery off command. For example: scu> verify media lba 464388 Verifying 1 blocks on /dev/rrz14c (RZ55), please be patient... Verifying blocks [ 464388 through 464388 ] ...
scu Keyword Page Code Description cdrom 0x0D CD−ROM device page audio-control 0x0E Audio control page device-configuration 0x10 Device configuration page medium-partition-1 0x11 Medium partition page 1 dec-specific 0x25 Digital-specific page readahead-control 0x38 Read-ahead control page Notes on the change pages command: • Only fields that are marked changeable in the changeable mode page are prompted for. • The default page control field is "current" values.
The page-control-field argument specifies the type of mode pages to obtain from the device.
• Refer to the vendor’s SCSI programming manual for information on buffer ID’s and buffer modes supported. The following notes apply to the download command: • If you enter scu using the default device /dev/cam and then set the device to download using the set nexus command, the code associated with checking for mounted file systems will fail. This was done purposely to prevent accidental downloading of disks with mounted file systems.
device to format, the code associated with checking for mounted file systems fails. This failure avoids the possibility of accidentally formatting disks with mounted file systems. read media [ test-parameters] This command performs read operations from the selected device. The command reads the device media and performs a data comparison of the data read. You must include test parameters that specify the media area to be read.
Header and Data Mode with a buffer ID and buffer offset of zero, these are the defaults, but may be overridden. By default, the full memory size returned in the Read Buffer header is written/read/verified, but this too may be overridden by specifying a smaller data limit or size. You can use various parameters to control the test memory operation. Most devices do not require these optional parameters, but newer devices may require different parameters to access the controller data buffer.
Performing Controller Memory Diagnostics... Testing Controller Memory of 61376 bytes (Mode 0, Offset 0) Testing 61376 bytes on /dev/rrz11c (RZ56) using pattern 0x39c39c39... Testing 61376 bytes on /dev/rrz11c (RZ56) using pattern 0x00ff00ff... Testing 61376 bytes on /dev/rrz11c (RZ56) using pattern 0x0f0f0f0f... Testing 61376 bytes on /dev/rrz11c (RZ56) using pattern 0xc6dec6de... Testing 61376 bytes on /dev/rrz11c (RZ56) using pattern 0x6db6db6d...
0x6db6db6d... Writing 1 block on /dev/rrz10c (RX23) with pattern 0x00000000... Writing 1 block on /dev/rrz10c (RX23) with pattern 0xffffffff...
C Support of the CI and HSC Hardware The Computer Interconnect (CI) bus is a high-speed, dual-path bus that connects processors and Hierarchical Storage Controllers (HSCs) in a computer room environment. An HSC is an I/O subsystem that is a self-contained, intelligent mass storage controller that provides access to disks and tapes from multiple host nodes attached to the CI bus.
_______________________ Note _______________________ Two parameters of particular importance are the system ID and the system name. Do not duplicate any system identification or names of nodes on the star coupler. C.2 Software Installation and Restrictions The installation software assists you in identifying and configuring the components of your system. You should be familiar with the basic installation guide for your processor before starting the actual installation.
to that HSC controller are inaccessible. Attempts to access those disks will cause the accessing system to hang until the HSC reboots completely. Refer to your processor hardware documentation for explicit instructions on booting an HSC disk. C.5 Sharing Disk and Tape Units Among Several Hosts Although an HSC can be shared among several hosts, there is no software interlocking mechanism to prevent concurrent write operations to the same partition by multiple Tru64 UNIX systems.
D Using the uerf Event Logger Use the uerf command to produce event reports from the binary log file. You must be superuser to use the uerf command. The uerf command accesses events logged to the binary log file, translates them from binary code to ASCII if necessary, and sends them to the output device you specify. The events include error messages relating to the system hardware and the software kernel, as well as information about system status, startup, and diagnostics.
To report on any other event-log file or if there is no *.* entry, you must use the uerf command with the −f option. Table D–1 describes the uerf command options. Table D–1: Options to the uerf Command Option Description −c class,... Selects events for the specified classes. −D [disk,...] Selects events for the specified mscp and SCSI disk devices. −f filename Specifies the file from which messages are read. −h Displays help information. −H hostname Selects events for the specified host system.
must direct the output to a printer special file as shown in the following example: # /usr/sbin/uerf > /dev/lp You can use some options together. For example, the following command produces a report from the /var/admin/logs.old file for the system guitar: # /usr/sbin/uerf −f /var/admin/logs.
lvm1: configured. setconf: bootdevice_parser translated _’SCSI 0 6 0 0 300 0 FLAMG-IO’ to _’rz3’ ************************ ENTRY 2. **************************** ----- EVENT INFORMATION ----EVENT CLASS OS EVENT TYPE SEQUENCE NUMBER OPERATING SYSTEM OCCURRED/LOGGED ON OCCURRED ON SYSTEM SYSTEM ID 199. 1.
uerf -D [ disk...] If you do not specify a disk variable, events for all disks are reported. If you specify more than one disk variable, separate them with commas. For example: # /usr/sbin/uerf −D rz23,rz24 D.1.3 Selecting Mainframe Events Use the uerf command with the −M option to select events for the specified mainframe event type. The uerf −M command has the following syntax: uerf -M [ mainframe...
You can specify the following op_system variables: Operating System Events Description aef Arithmetic exception faults ast Asynchronous trap exception faults pag Page faults pif Privileged instruction faults pro Protection faults ptf Page table faults raf Reserved address faults rof Reserved operand faults scf System call exception faults seg Segmentation faults If you do not specify an op_system variable, all operating system events are reported.
The filename variable specifies the event-log file to use. You must specify the full pathname for the file, for example: # /usr/sbin/uerf -f /var/adm/binary.old You cannot specify the −n option with the −f option. D.1.8 Generating Reports for Hosts Use the uerf command with the −H option to select events for the specified host system. Use this option if events from remote systems are being forwarded to your local system. The uerf −H command has the following syntax: uerf -H hostname D.1.
Record code ASCII Messages 250 Informational Record code Operational Messages 300 Startup 301 Shutdowns and reboots 302 Panics 350 Diagnostics status If you specify more than one record variable, separate them with commas. You can also separate record variables with a dash (−) to indicate a sequence of record codes.
_______________________ Note _______________________ Sequence numbers restart when you reboot the system. If the event-log file contains events from before and after a reboot, the file may contain duplicate sequence numbers. If the −s option is the only uerf command option specified, all events with the specified sequence numbers are reported. D.2.2 Specifying a Time Range Use the uerf command with the −t option to select events in the specified time range.
D.2.3 Specifying Unit Numbers Use the uerf command with the −u option to select events from the disk or tape device unit number. The uerf −u command has the following syntax: uerf -u number The number variable specifies the tape or disk unit number. You can use this option only with the −D and the −T options. D.2.4 Excluding Reported Events Use the uerf command with the −x option to exclude the specified event source from the report. You can exclude the −c, −D, −M, −O, and −T options from the request.
uerf -o output The output variable can be one of the following: Output Type Description brief Reports event information in a short format. This is the default. full Reports all available information for each event. terse Reports event information and displays register values but does not translate the events to ASCII. Usually, the −o full option produces the most event information. However, panic messages and other ASCII messages do not provide more information with the −o full option.
E Administering Specific Hardware E.1 Introduction This appendix describes the procedures for adding and configuring certain hardware devices or options as follows: • PCMCIA cards • CalComp graphics tablet • Logical partitions on the AlphaServer GS140 E.
• Tru64 UNIX can support two PCMCIA adapters in a system provided that the necessary resources are available. In some systems, availability of interrupt lines will prohibit the use of multiple adapters. If you have sufficient resources and are going to support two adapters, the second adapter should be configured to use the I/O address 3E2. • To use fax functions in a fax/modem PC card, a commercial UNIX fax application software program is required.
available in your system and use the appropriate ISA or EISA instructions in this section. E.2.2.1 Configuring a PCMCIA on an ISA Bus System If your system has an ISA (Industry Standard Architecture) bus, use the following procedure to configure a card: 1. If the system is an ISA bus system, the isacfg utility from the console must be used to configure the PCMCIA adapter. 2. After the PCMCIA adapter board is inserted to an ISA slot in the system, turn on the system. 3.
iobase2: 8000000000000000 membase1: 8000000000000000 iobase3: 8000000000000000 memlen1: 8000000000000000 iobase4: 8000000000000000 membase2: 8000000000000000 iobase5: 8000000000000000 memlen2: 8000000000000000 rombase: 8000000000000000 romlen: 8000000000000000 dmamode0/chan0: 80000000 irq0: 14 dmamode1/chan1: 80000000 irq1: 80000000 dmamode2/chan2: 80000000 irq2: 80000000 dmamode3/chan3: 80000000 irq3: 80000000 ============================================================= >>> E.2.2.
If you did not have the PCMCIA fax/modem card inserted in the slot when the system was installed, then you need to add the following line to your system kernel configuration file, (/sys/conf/HOSTNAME where HOSTNAME is the name of your system): controller ace2 at * slot ? vector aceintr If you plan to use two modem cards simultaneously, add the following lines to your system configuration file: controller controller ace2 ace3 at * at * slot ? vector aceintr slot ? vector aceintr Once the system confi
crw-rw-rwcrw-rw-rw- 1 root 1 root system system 35, 35, 2 Oct 27 14:02 tty02 3 Oct 27 14:02 tty03 E.2.5 The /etc/remote File You must edit the /etc/remote file must be modified to add new access line definitions for the PCMCIA modem cards to be used. If you have a 28.8kpb modem card and will be using the full speed, the baud rate (br) in the /etc/remote file should be set to 38400.
should be ejected, because it is not configured. A possible solution is to remove some other ISA/EISA devices in the system and reboot the system, freeing I/O resources that may be required. E.2.7 Removing a PCMCIA Modem Card Once you are finished using the modem card, push the button next to the card slot to eject it. You should see the following message on the console terminal or console Log window.
Table E–1 can help you determine how to set up the entries for the tablet in the /usr/var/X11/Xserver.conf file. Table E–1: CalComp DrawingBoard III Tablet Configuration Options and Values Option Description device The port (tty ) to which the device is connected. The default is tty00. mode This should be set to 1 for absolute motion. tabletWidth Width of the active tablet area in inches, not the physical size. The default is 12.
After you have configured the /usr/var/X11/Xserver.conf file, you must follow these steps to turn on support for the tablet in the Xserver: 1. Plug the tablet into your system and turn it on. 2. Enter the following command to restart the Xserver so that the Xinput extension can recognize the tablet: # /usr/sbin/shutdown -r +5 \ "Turning on support for the Calcomp Drawingboard III tablet" (The backslash in this example indicates line continuation and is not in the actual display.
E.4 AlphaServer GS140 Logical Partitions A single AlphaServer GS140 system can be divided into a maximum of three logical partitions. Each partition is allocated its own dedicated set of hardware resources. A partition is viewed by the operating system and applications software as a single AlphaServer GS140 system. Logical partitions employ a share nothing model. That is, all hardware resources (processors, memory, and I/O) allocated to a partition are isolated to that partition.
The minimum memory size supported for a partitions is 512 MB. However, applications running in a partition may require more than the 512 MB minimum memory. • A software load source device (CDROM drive or network adapter) • A minimum AlphaServer GS140 console firmware revision level of Version 5.4. When installing and configuring logical partitions on a system, refer to the release notes covering the release of Tru64 UNIX that you will be installing, and update the firmware revision if required.
aware of prior to making the system operational. Precautions must be taken to prevent actions by the console on a partition from interfering with operation of another partition. The next section describes logical partitioning terms used throughout the rest of this document. After reviewing these terms, proceed to section Section E.4.3. E.4.2.1 Definition of Commonly Used Terms You should become familiar with the following terms before configuring your partitions.
• ENABLE – Power is applied to the system (all partitions). The primary console’s ctrl/p halt function is enabled. • RESET – This is a momentary position. Moving the switch to RESET and then releasing it will cause a complete initialization of the system. All secondary partitions will be immediately terminated. The primary partition will display the normal power on self-test messages and enter console mode.
P##>>>init Typing init at the console (P##>>>) prompt of any partition causes a complete reinitialization of the entire system. All active partitions are immediately terminated and the system is reset (as if the power switch was momentarily moved to the RESET position). If partitions are enabled, the console will request verification of the init command by displaying the following prompt: Do you really want to reset ALL partitions? (Y/) Type Y to complete the init command or N to cancel it. E.4.
2. After a short delay (about 15 seconds) configuration information (similar to the following example) will display on the primary console screen: F E D C B A 9 8 A o . o . + . 7 A o . o . + . 6 M + . + . + . 5 . . . . . . . 4 M + . + . + . 3 P ++ EE ++ EE ++ EE 2 P ++ EE ++ EE ++ EE 1 P ++ EE ++ EE ++ EE 0 P ++ EB ++ EB ++ EB NODE # TYP ST1 BPD ST2 BPD ST3 BPD . . . . . + . . + . + + + . . . + + + + + . C0 PCI + C1 XMI + . . . . . . . . . + . + . . . . . + . + .
A = IOP (IO port module) 8 7 6 5 4 3 2 1 0 +---+---+---+---+---+---+---+---+---+ | | | | | | | | | | | | | | | | | | | | +---+---+---+---+---+---+---+---+---+ 4. Divide your system into logical partitions by assigning slots (and therefore modules) to each partition. Each partition must be assigned at least one dual CPU module, one MEM module, and one IOP module. With a total of nine slots, the AlphaServer GS140 can be configured for a maximum of three partitions.
hexadecimal numbers, which are bit masks in which a bit position in the mask correspondes to a module or processor number. Hardware configuration rules require modules to be installed in specific slot numbers, based on the module type, as follows: • IO port (IOP) modules are installed in slots 8, 7, and 6 in descending order with a maximum of three IOP modules allowed. • CPU (dual processor) modules are installed in slots 0 through N in ascending order (N depends on the number of CPU modules installed).
Console EV Value lp_io_maskN IOP module assignment mask for partition N lp_mem_mode Memory isolation mode The following table shows a sample configuration of two partitions based on the configuration information in Section E.4.3.3.
Note that there will be a 10 second delay after you issue each command and that the console will display the value of each EV after you create it.
P00>>>set P00>>>set P00>>>set P00>>>set P00>>>set P00>>>set lp_count 0 lp_cpu_mask0 f lp_cpu_mask1 f0 lp_io_mask0 100 lp_io_mask1 80 lp_mem_mode isolate E.4.3.7 Disabling Automatic Boot Reset The boot_reset console EV must be set to OFF. This is required so booting a partition does not interfere with the operation of other (previously booted) partitions. If boot_reset is set ON, then a system wide reset is done when the boot command (P00>>>boot) is executed.
modules) to each partition and spawns a console for each secondary partition as follows: 1. Set the lp_count EV to the number of partitions. For example, to enable two partitions: P00>>>set lp_count 2 2. Initialize partition 0: P00>>>init Configuration information (as previously described) will display on the primary console screen, followed by the console prompt; P00>>>. 3. Initialize all secondary partitions.
Then, repeat the steps in this section. E.4.5 Installing the Operating System When partitions are configured and initialized, you can install the operating system to each partition. Install the operating system by following the instructions in the Installation Guide. AlphaServer GS140 systems ship with Tru64 UNIX preinstalled on one of the disks. You can use this disk as the root disk for one of the partitions (usually partition 0).
If you execute the init command, the console will print a message asking you to confirm that you actually want to reset all partitions. Answer no to abort the init command or yes to continue with the init command. E.4.6.1.2 Shutting Down or Rebooting the Operating System To shut down the operating system running in a partition and return to console mode (P##>>> prompt), use the shutdown command.
_______________________ Note _______________________ In the unlikely event that the processor cannot be halted the system must be reset by momentarily setting the four way OFF/ENABLE switch to the RESET position, then releasing it. The following procedures only work if the Power OFF/ENABLE switch is in the ENABLE position. Primary Partition Typing ctrl/p on the primary console terminal will force the primary processor to enter console mode and display the P##>>> prompt.
Once you have determined the layout of the new partition, follow these steps to reconfigure your partitions: 1. Shut down the operating system in each partition: # /usr/sbin/shutdown -h +5 "shutting down to reconfigure partitions" 2. Disable partitions and reset the system as follows: P00>>>set lp_count 0 P00>>>init 3. Use the console set command to change the value of any or all of the console EVs. For the two partition example discussed in Section E.4.3.
E.4.6.7 Logical Partitioning Informational Messages at Boot Time If logical partitions are set up and enabled, several informational messages will displayed by the operating system on the console terminal for each partition near the beginning of the bootstrap process.
• Adding or removing system hardware components (CPUs, memory, IOPs, PCI busses, IO controllers, and IO devices [except for hot swappable disks]). • Changing any partition’s hardware resource assignments by modifying any console EV with lp_ prepended to its name. • Running the ECU (Eisa Configuration Utility) or the RCU (Raid Configuration Utility) from the floppy disk drive. E.4.7.
3. Set the auto_action console EV for the primary partition to HALT as follows: P00>>>set auto_action halt Note that you may need to reset the auto_action EV in step 1 of the next procedure, initializing and rebooting the partitions. 4. Reinitialize the system by typing this command on the primary console terminal. P00>>>init When the system returns to the P00>>> prompt you can perform system management and maintenance tasks.
hardware configuration changes and whether or not a kernel rebuild is required: Change Requirements Processors – adding, removing, or reassigning CPU modules. Changing the lp_cpu_mask# EV for any partition does not require a kernel rebuild. Remember that both processors on a dual CPU module must be assigned to the same partition. IO Processors – adding, removing, or reassigning IOP modules.
• Kernel booting and the single-user mode prompt. • Saving and copying kernels. 1. Boot the generic kernel to single-user mode. P##>>>boot -fl s -fi genvmunix 2. Check and mount file systems. # bcheckrc Refer to Chapter 7 for more information on mounting file systems 3. Set the host name (system name) for this partition. # hostname NAME 4. Rebuild the kernel using the doconfig command.
Non-recoverable hardware errors require immediate termination of normal system operation and some form of corrective action (such as a system reset). Nonrecoverable hardware errors are reported to the operating system as a machine check.
Do you really want to reset ALL partitions? (Y/) Type Y to perform the reset. 4. After the reset is completed and if auto_action is set to BOOT, the console firmware will automatically reinitialize all partitions.
LP_ERROR: no IOP for partition (check lp_io_mask) The value of lp_io_mask# (# represents the current partition number) is set incorrectly. There are no IO Port modules allocated to this partition. LP_ERROR: lp_count > 1, but partitions not initialized Please execute ’lpinit’ command at >>> prompt The message indicates that partitions were configured, but not initialized. LP_ERROR: must set lp_mem_mode [share or isolate] The lp_mem_mode console EV is not set or set incorrectly.
reset was performed via the RESET switch on power-on (not through the init command). Insufficient memory interleave sets to partition system. Issue command "set interleave none" then reset system. This message indicates that the interleave console EV is incorrectly set. You need to change the setting to none. Insufficient memory modules to partition system. Each partition requires a dedicated memory module. You need to reduce the number of partitions or install a memory module for each partition.
CPU # not configured in any partition. No valid primary processor specified for partition #. In this message, the CPU number (#) may be a single CPU or a list of CPUs. These messages (together or separately) indicate incorrect setting of the lp_cpu_mask# console EV. The mask may be set to zero or to incorrect CPU numbers. You should correct the setting and retry the lpinit command.
F Using the System Exercise Tools This appendix describes how you test system components when you see error messages that relate to a component or if you observe unexpected behavior. F.1 System Exercisers The Tru64 UNIX system provides a set of exercisers that you can use to troubleshoot your system. The exercisers test specific areas of your system, such as file systems or system memory.
Most of the exerciser commands have an online help flag that displays a description of how to use that exerciser. To access online help, use the −h flag with a command. For example, to access help for the diskx exerciser, use the following command: # diskx −h The exercisers can be run in the foreground or the background and can be canceled at any time by pressing Ctrl/C in the foreground.
using either the dia command (preferred) or the uerf command. For information on the error logger, see the Section 13.1. For the meanings of the error numbers and signal numbers, see the intro(2) and sigvec(2) reference pages. F.1.3 Exercising a File System Use the fsx command to exercise the local file systems. The fsx command exercises the specified local file system by initiating multiple processes, each of which creates, writes, closes, opens, reads, validates, and unlinks a test file of random data.
F.1.4 Exercising System Memory Use the memx command to exercise the system memory. The memx command exercises the system memory by initiating multiple processes. By default, the size of each process is defined as the total system memory in bytes divided by 20. The minimum allowable number of bytes per process is 4095. The memx command runs 1s and 0s, 0s and 1s, and random data patterns in the allocated memory being tested.
-tmin Specifies how many minutes you want the memx command to exercise the memory. If you do not specify the -t flag, the memx command runs until you terminate it by pressing Ctrl/C in the foreground. The following example of the memx command initiates five memxr processes that test 4095 bytes of memory and runs in the background for 60 minutes: # memx −m4095 −p5 −t60 & F.1.5 Exercising Shared Memory Use the shmx command to exercise the shared memory segments.
which are set in the /sys/include/sys/param.h file. -sn Specifies n as the number of memory segments. The default (and maximum) number of segments is 3. The following example tests the default number of memory segments, each with a default segment size: # shmx & The following example runs three memory segments of 100,000 bytes for 180 minutes: # shmx -t180 -m100000 -s3 & F.1.6 Exercising a Disk Drive Use the diskx command to exercise the disk drives.
with an r (for example, rz1). The last character of the file name can specify the disk partition to test. If a partition is not specified, all partitions are tested. For example, if the devname variable is /dev/rra0, all partitions are tested. If the devname variable is /dev/rra0a, the a partition is tested. This parameter must be specified and can be used with all test flags. The following flags specify the tests to be run on disk: −d Tests the disk’s disktab file entry.
−r Specifies a read-only test. This test reads from the specified partitions. Specify the −n flag to run this test on the block special file. This test is useful for generating system I/O activity. Because it is a read-only test, you can run more than one instance of the exerciser on the same disk. −w Specifies a write test. This test verifies that data can be written to the disk and can be read back to verify the data. Seeks are also done as part of this test.
−Q Suppresses performance analysis of read transfers. This flag only performs write performance testing. To perform only read testing and to skip the write performance tests, specify the −R flag. The −Q flag can be used with the −p test flag. −R Opens the disk in read-only mode. This flag can be used with all test flags. −S Performs transfers to sequential disk locations. If this flag is not specified, transfers are done to random disk locations.
operations. This parameter can be used with all test flags. −err_lines Specifies the maximum number of error messages that are produced as a result of an individual test. A limit on error output prevents a large number of diagnostic messages if persistent errors occur. This parameter can be used with all test flags. −minutes Specifies the number of minutes to test. This parameter can be used with the −r and −w test flags. −max_xfer Specifies the maximum transfer size to be performed.
−perf_max Specifies the maximum transfer size to be performed. If transfers are done using random sizes, the sizes are within the range specified by the −perf_min and −perf_max parameters. If fixed size transfers are specified (see the −F flag), transfers are done in a size specified by the −perf_min parameter. This parameter can be used with the −p test flag. −perf_min Specifies the minimum transfer size to be performed. This parameter can be used with the −p test flag.
The following example shows that performance tests are run on the a partition of /dev/rz0, and program output is logged to the diskx.out file. The −S flag causes sequential transfers for the best test results. Testing is done over the default range of transfer sizes: # diskx -f /dev/rz0a -o diskx.out -p -S The following command runs the read test on all partitions of the specified disks. The disk exerciser is invoked as three separate processes, which generate extensive system I/O activity.
−err_lines Specifies the error printout limit. −fixed bs Specifies a fixed block device. Record sizes for most devices default to multiples of the blocking factor of the fixed block device as specified by the bs argument. The following parameters can be used with the −a flag, which measures performance: −perf_num Specifies the number of records to write and read. −perf_rs Specifies the size of records. Other parameters are restricted for use with specific tapex flags.
Table F–1: The tapex Options and Option Parameters (cont.) tapex Flag Flag and Parameter Descriptions −d Tests the ability to append records to the media. First, the test writes records to the tape. Then, it repositions itself back one record and appends additional records. Finally, the test does a read verification. This test simulates the behavior of the tar −r command.
Table F–1: The tapex Options and Option Parameters (cont.) tapex Flag Flag and Parameter Descriptions −F Specifies the file-positioning tests. First, files are written to the tape and verified. Next, every other file on the tape is read. Then, the previously unread files are read by traversing the tape backwards. Finally, random numbers are generated, the tape is positioned to those locations, and the data is verified. Each file uses a different record size.
Table F–1: The tapex Options and Option Parameters (cont.) tapex Flag Flag and Parameter Descriptions −j Specifies the write phase of the tape-transportability tests. This test writes a number of files to the tape and then verifies the tape. After the tape has been successfully verified, it is brought off line, moved to another tape unit, and read in with the −k flag. This test proves that you can write to a tape on one drive and read from a tape on another drive. The −j flag is used with the −k flag.
Table F–1: The tapex Options and Option Parameters (cont.) tapex Flag Flag and Parameter Descriptions −q Specifies the command timeout test. This test verifies that the driver allows enough time for completion of long operations. This test writes files to fill the tape. It then performs a rewind, followed by a forward skip to the last file. This test is successful if the forward skip operation is completed without error. −r Specifies the record size test.
Table F–1: The tapex Options and Option Parameters (cont.) tapex Flag Flag and Parameter Descriptions −S Specifies single record size test. This test modifies the record size test (the −r flag) to use a single record size. The following parameters can be used with the -S flag: −inc Specifies the record increment factor. −max_rs Specifies the maximum record size. −min_rs Specifies the minimum record size. −num_rec Specifies the number of records. −T Displays output to the terminal screen.
The following example performs random record size tests and outputs information in verbose mode. This test runs on the default tape device /dev/rmt0h, and the output is sent to the terminal screen. # tapex -g -v The following example performs read and write record testing using record sizes in the range 10K to 20K. This test runs on the default tape device /dev/rmt0h, and the output is sent to the terminal screen.
you do not specify the −t flag, the cmx command runs until you terminate it by pressing Ctrl/C in the foreground. −l line Specifies the line or lines you want to test. The possible values for line are found in the /dev directory and are the last two characters of the tty device name. For example, if you want to test the communications system for devices named tty02, tty03, and tty14, specify 02, 03, and 14, separated by spaces, for the line variable.
Index A ac command, 12–17 account password, 9–9 accounting, 12–1 automatic, 12–9, 12–11 charge units, 12–33 charging fees, 12–33 commands ac, 12–17 acctcms, 12–27 acctcom, 12–24 acctcon1, 12–18 acctdisk, 12–33 acctdusg, 12–32 acctmerg, 12–39 accton, 12–23 acctprc1, 12–28 acctprc2, 12–29 acctwtmp, 12–17 diskusg, 12–31 fwtmp, 12–15 last, 12–20 lastcomm, 12–29 list of, 12–2 sa, 12–25 wtmpfix, 12–15 connect session, 12–13 daily records, 12–8 daily reports, 12–8 disk samples, 12–39 disk usage, 12–30 error messag
shell scripts ckpacct, 12–23 dodisk, 12–30 lastlogin, 12–19 list of, 12–2 prctmp, 12–19 prdaily, 12–40 prtacct, 12–40 runacct, 12–35 shutacct, 12–12 startup, 12–12 turnacct, 12–23 turnacct off, 12–23 turnacct on, 12–23 turnacct switch, 12–23 starting, 12–12 stopping, 12–12 submitting commands to cron, 12–11 turning off, 12–19 using the crontab command, 12–11 utmp file structure, 12–14 accounting samples, 12–39 acctcms command, 12–27 acctcom command, 12–24 acctcon1 command, 12–18 acctdisk command, 12–33 acct
syntax, 13–11 binlogdumpfile file, 13–19 boot preparation after a system crash, 3–5 from a halted system, 3–4 powered-down systems, 3–3 to single-user mode, 3–5 bootable tape, 11–3 disk space requirement, 11–5 LSM, 11–8 requirements, 11–7 supported processors, 11–8 supported tape devices, 11–8 tape requirements, 11–7 booting alternate kernel, 3–10 genvmunix, 3–3 overriding set commands, 3–10 overview, 3–1 bounds file description of, 13–18 BSD_TTY configuration file definition, 5–55 btcreate command, 11–3 bt
comm ports ( See also console port ) Common Access Method (CAM) I/O Subsystem, B–1 communications system ( See terminal communications system ) Compact Disc File System ( See CDFS ) Compaq Analyze, 13–3 COMPAT_43 configuration file definition, 5–51 compressed crash dumps, 13–22 Computer Interconnect bus ( See CI ) config keyword, 5–47 configuration kernel, 5–1 dynamic , 5–6 static, 5–17 of kernel subsystems, 5–1 printer, 10–19 steps in at installation time, 5–2 system, 2–3 configuration checklist, 2–3 confi
saving in files, 13–21 version number assignment, 13–18 crash recovery, 3–5, 13–13 cron daemon setting up automatic accounting, 12–11 submitting commands to, 4–13 crontab command, 4–13 crontabs directory modifying files in, 4–13 customization tasks introduction, 1–2 D daemon binlogd, 13–2 envmond, 13–25 syslogd, 13–2 daemons class scheduler, 4–33 date command, 3–15 DCD ( See modem ) dd command, 7–29 cloning on a data disk, 7–29 DDR, 6–1 compiling changes to databases, 6–3 conforming to standards, 6–2 conve
disk drive adding, 6–7 adding static, 6–7 testing with diskx, F–6 disk groups, 8–4 LSM, 8–8 disk management ( See LSM ) disk name definition of, 8–7 disk partition, 7–2 changing parameters, 7–29 changing size, 7–28 defined, 7–2 overlapping partitions, 7–31 sizes, 7–2 writing the default label, 7–28 disk quota activating, 7–26 activating edquota editor, 7–26 reaching, 7–25 recovering from over-quota condition, 7–25 setting grace period, 7–26 turning off, 7–26 verifying, 7–26 disk quotas ( See also file syste
attribute files, 5–5 attribute listing, 5–5 subsystem listing, 5–5 dxkerneltuner graphical user interface, 5–4 dxpower, 4–35 dxproctuner, 4–29 dynamic configuration, 5–6 Dynamic Device Recognition ( See DDR ) dynamic subsystem configuring into the kernel, 5–7 determining the state of, 5–7 unloading, 5–9 E ECU, 1–1 ( See environment configuration utility ) editing root file system, 3–3 edquota command, 9–16 edquota editor activating, 7–26 setting grace period, 7–26 enhanced core file naming, 13–14 envconfig
binlog.conf file, 13–7 binlog_data.
regular, 7–12 symbolic link files, 7–12 fsck program, 7–15, 7–17 checking file system, 7–15 correcting file system, 7–15 overlapping partitions, 7–15 syntax, 7–15 fstab file, 7–16, 7–17, 7–19 editing, 7–17 fsx exerciser, F–3 full crash dumps ( See crash dumps ) fwtmp command, 12–15 correcting wtmp file, 12–16 deleting a group from the, 9–22 deleting users from the, 9–19 line length limits, 9–4 group identifier ( See GID ) groups, 9–1 grpck command, 9–13 H halt command, 3–20 halting systems, 3–17 hard limi
changing run levels, 3–12 multiuser run levels, 3–12 reexamining the inittab file, 3–13 init directory structure, 4–9 init.
login shell, 9–12 changing, 9–15 loop configuration file definition, 5–59 lpc command arguments, 10–17 lpd daemon, 10–19 filter representation in printcap, 10–8, 10–26 lpd filter explanation of, 10–26 lpr command, 10–19 lprsetup, 10–9 choosing options in, 10–9 example, 10–11 main menu, 10–10 modifying printer configuration, 10–9 running, 10–10 lptest command, 10–14 ls configuration file definition, 5–58 LSM, 8–1 configuration, 8–3 configuration definition, 5–58 disk groups, 8–8 disk operations with, 8–7 fea
exercising with memx, F–4 shared memory testing with shmx, F–5 system memory, F–4 memory size setting default limits, 5–39 setting maximum limits, 5–39 memx exerciser, F–4 swap space restrictions of, F–4 message catalogs, 4–14 messages receiving from system, 13–28 metadata cache changing size in configuration file, 5–45 mirrors, 8–4 mknod command, 7–12 mnemonics device, A–1 modem connecting, 2–5 setting up, 2–5, 2–6 settings, 2–5 timer settings, 2–5 modem connections ( See also closing ) ( See also console
( See deferred mode swapping ) overlapping disk partitions checking for, 7–31 newfs command, 7–15 P pac command, 12–34 paging allocating disk space for, 7–4 description, 7–4 panic string for hardware restart, 13–23 for hung system, 13–23 param.
lock file, 10–21 lpc command, 10–17 name, 10–4 pac command, 12–34 reference names, 10–23 remote client, 10–30 printcap symbols, 10–23 server, 10–30 removing printers, 10–16 reporting usage, 12–34 setting up manually, 10–15 setting up remote, 10–13 spooler directory, 10–8 spooling directory, 10–20 spooling queue, 10–17, 10–19 starting lpd daemon, 10–17 status, 10–17 status file, 10–21 synonyms, 10–6 testing, 10–14 troubleshooting information, 10–31 type, 10–5 using lprsetup, 10–9 printer control file ( See P
( See system reboot ) reboot operations, 3–18 record binary accounting, 12–29 daily accounting, 12–29 overall connect session, 12–19 remote connection, 2–4 remote system, 2–4, 2–7 remote system administration ( See also console port ) removeuser command, 9–18 restore and backup introduction, 1–5 procedures, 11–1 restore command, 11–16 retrieving a file system, 11–17 retrieving data, 11–15 retrieving files, 11–18 from a remote tape device, 11–22 interactively, 11–20 root file system mounting read only from s
format, B–1 general purpose commands, B–3 maintaining SCSI disks, B–1 online help, B–3 syntax conventions, B–1 scu program maintaining SCSI disks, 7–20 secondary swap partition ( See swap space ) sector defined, 7–2 securettys file securing terminal line, 4–9 security establishing, 1–3 policy, 4–22 segmentation keyword, 5–47 semaem keyword, 5–41 semmni keyword, 5–41 semmns keyword, 5–41 semmsl keyword, 5–41 semopm keyword, 5–41 semume keyword, 5–41 semvmx keyword, 5–41 Server System MIB variables, 13–27 sha
STRKINFO configuration file definition, 5–54 strpush configuration file definition, 5–59 stty, 2–8 subdisks, 8–4 subsystem ( See also dynamic subsystem ) administering with dxkerneltuner, 5–4 configuring, 5–1 determining the type of, 5–8 viewing with dxkerneltuner, 5–4 subsystem attribute determining the operations allowed, 5–11 determining the value of, 5–10 listing database values of, 5–14 SVR4 pty name space, 6–6 swap space adding, 7–5, 7–6, 7–17 allocating, 7–5 allocating disk space for, 7–4 deferred mo
system administration tools, 2–3 system clock setting, 3–15 system configuration, 2–3 dynamic ( See loadable drivers ) static, 5–17 system configuration file pseudodevice entry, 6–4 system crash, 3–5 dump created during, 13–19 hardware failure, 3–5 logging of by system, 13–18 recovery, 3–5 system environment customizing, 4–1 remote, 2–4 system event reporting, 13–1 system events and errors, 13–1 logging, 1–6 system exercisers, 1–6 diagnostics, F–2 getting help, F–2 log files, F–2 requirements, F–1 using uer
terminfo database, 4–8 TERMINFO environment variable, 4–8 threadmax keyword, 5–43 tic command, 4–8 time setting, 3–15 time zone, 4–19 SVID, 4–19 timezone keyword, 5–39 tip connection, 2–4 total accounting record, 12–29 Tower of Hanoi, 11–11 troubleshooting editing root files, 3–3 event logs, 13–1 sys_check, 4–26 TRSRCF configuration file definition, 5–54 tunefs command, 7–20 tuning, 5–2 turnacct shell script, 12–23 U ubcbuffers keyword, 5–47 uerf command, D–1 data files, D–1 displaying hexadecimal, D–11 ex
/usr/adm/binary.errlog, 7–14 /usr/adm/lperr, 7–14 utmp file structure, 12–14 uucp, 2–7 uugetty, 2–6 V VAGUE_STATS configuration file definition, 5–53 /var file system restoring, 11–23 /var/adm/crash directory, 13–17 /var/adm/messages, 5–44 /var/adm/syslog.dated, 7–14 VFS, 7–2 file system overview, 7–2 virtual disks, 8–4 Virtual File System ( See VFS ) virtual memory description, 7–4 vmcore.n file, 13–17 vmstat, 4–29 vmunix.
How to Order Tru64 UNIX Documentation You can order documentation for the Tru64 UNIX operating system and related products at the following Web site: http://www.businesslink.digital.com If you need help deciding which documentation best meets your needs, see the Tru64 UNIX Documentation Overview or call 800-344-4825 in the United States and Canada. In Puerto Rico, call 787-781-0505. In other countries, contact your local Compaq subsidiary.
Reader’s Comments Tru64 UNIX System Administration AA-PS2RF-TE Compaq welcomes your comments and suggestions on this manual. Your input will help us to write documentation that meets your needs. Please send your suggestions using one of the following methods: • This postage-paid form • Internet electronic mail: readers_comment@zk3.dec.
Do not cut or tear - fold here and tape NO POSTAGE NECESSARY IF MAILED IN THE UNITED STATES FIRST CLASS MAIL PERMIT NO.