内に含ま
その他のドキュメント
サポート リソース
| PDF 文書ファイルをダウンロードする
Examining and Changing System Information
63
- This chapter describes tasks required to examine and change the most common system information. This is a list of the step-by-step instructions in this chapter.
-
Using the Workstation Information Window to Display System Information
- "Workstation Info . . ." in the OpenWindows Workspace menu . . .
-

- . . . provides the following information about a system:
-
- Workstation name and type
- Host ID
- Internet address and network domain
- Physical memory (RAM) and virtual memory
- Operating system and window system versions
- Some of the same information can be displayed with commands described later in this section, but this screen is a convenient way to display this particular collection of information.
- If your OpenWindows Workspace menu does not include the Workstation Info command, see "How to Add "Workstation Info" to the Workspace Menu" on page 1272.
· How to Add "Workstation Info" to the Workspace Menu
-
-
Use the editor of your choice to open .openwin-menu in your home directory.
-
-
-
Add the following line to the .openwin-menu file.
-
"Workstation Info ..." exec $OPENWINHOME/bin/wsinfo
|
- The placement of this line determines the placement of the command in the menu. In other words, if you place it above the Properties line, it will appear above the Properties command in the menu:
-

-
-
Exit the file, saving the changes.
Using Commands to Display System Information
-
Table 63-1 shows man pages and descriptions for some commands that enable you to display general system information.
-
Table 63-1
| Command | Enables You to Display a System's ... |
| uname(1) | Operating system name, release, and version; node name;
hardware name; processor type |
| hostid(1) | Host ID number |
| prtconf(1M) | Installed memory |
| date(1) | Date and time |
· How to Display General System Information
- To display system information, use the uname command.
-
- In this command,
-
| uname | Displays only the name of the operating system. |
| -a | Displays the operating system name as well as the system node name, operating system release, operating system version, hardware name, and processor type. |
Example--Displaying General System Information
- The following example shows sample output from the uname command on the system jupiter.
-
$ uname
SunOS
$ uname -a
SunOS jupiter 5.5 preview95 sunrm sparc
|
· How to Display a System's Host ID Number
- To display the host identification number in hexadecimal format, use the hostid command.
-
Example--Displaying a System's Host ID Number
- The following example shows sample output from the hostid command.
-
· How to Display a System's Installed Memory
- To display the amount of memory installed on your system, use the prtconf command.
-
$ prtconf [| grep Memory]
|
- In this command,
-
grep Memory.....Focuses output from this command to display memory information only.
Example--Displaying a System's Installed Memory
- The following example shows sample output from the prtconf command.
-
# prtconf | grep Memory
Memory size: 32 Megabytes
|
· How to Display the Date and Time
- To display the current date and time according to your system clock, use the date command.
-
Example--Displaying the Date and Time
- The following example shows sample output from the date command.
-
$ date
Thu Apr 13 10:31:43 EST 1995
|
Using Commands to Change System Information
-
Table 63-2 shows man pages and descriptions for some commands that enable you to change general system information.
-
Table 63-2
| Command | Enables You to Change a System's ... |
| rdate(1M) | Date and time to match those of another system |
| date(1) | Date and time to match your specifications |
- By using these commands, you can set a system's date and time to synchronize with the date and time of another system, such as a server. Or you can change a system's date and time by specifying new information.
- The message of the day (MOTD) facility, located in /etc/motd, enables you to send announcements or inquiries to all users of a system when they log in. Use this facility sparingly, and edit this file regularly to remove obsolete messages.
- By editing the /etc/system file, you can:
-
- Change the number of processes per user
- Increase the number of pseudo-ttys to 256
- Increase the number of lock requests
- Increase shared memory segments
- By default, the number of lock requests that may occur simultaneously is 512. As users log out, they lock files, including utmp. If more than 512 users are likely to log out simultaneously (within a few seconds), the number of file locks allowed must be increased.
· How to Synchronize Date and Time From Another System
-
-
Become root.
-
To reset the date and time to synchronize with another other system, use the rdate command.
-
# rdate other-system-name
|
- In this command,
-
other-system-name..Is the name of another system.
Verification--Synchronizing Date and Time From Another System
- To verify that you have reset your system's date and time by using rdate, check your system's date and time using the date command. The output should show a date and time that matches that of the other system.
Example--Synchronizing Date and Time From Another System
- The following example shows how to use rdate to synchronize the date and time of one system with another. In this example, the system Neptune, which is running several hours behind, is reset to match the date and time of the server Pluto.
-
neptune$ date
Tue Mar 28 19:31:43 EST 1995
neptune$ rdate pluto
Tue Mar 28 22:00:00 EST 1995
neptune$ date
Tue Mar 28 22:00:00 EST 1995
|
· How to Set a System's Date and Time Manually
-
-
Become root.
-
Enter the new date and time.
-
- In this command,
-
| mm | Is the month, using two digits. |
| dd | Is the day of the month, using two digits. |
| HH | Is the hour, using two digits and a 24-hour clock. |
| MM | Are the minutes, using two digits. |
| cc | Is the century, using two digits. |
| yy | Is the year, using two digits. |
Verification--Setting a System's Date and Time Manually
- After you set the date and time manually, you can use date with no options to display your system's new date and time to confirm that this information has changed.
Example--Setting a System's Date and Time Manually
- The following example shows how to use date to manually set a system's date and time.
-
$ date
Fri Dec 9 10:31:00 MST 1994
$ date 032318151995
Thu Mar 23 18:15:00 MST 1995
|
· How to Set Up a Message of the Day
-
-
Become root.
-
Open the /etc/motd file, using the editor of your choice.
-
Edit the text to include the message that will be displayed as part of the user login process, including spaces, Tabs, and Returns.
-
Exit the file, saving your changes.
Verification--Setting Up a Message of the Day
- To view the /etc/motd file, use the cat or more command.
-
$ cat /etc/motd
Welcome to the UNIX Universe. Have a nice day.
|
Example--Setting Up a Message of the Day
- The default message of the day, provided when you install Solaris software, contains SunOS version information:
-
Sun Microsystems Inc SunOS 5.5 Generic August 1995
|
- The following example shows an edited /etc/motd file that provides information about system availabilty to each user who logs in.
-
The system will be down from 7:00 a.m to 2:00 p.m.on
Saturday, August 5, for upgrades and maintenance.
Do not try to access the system during those hours.
Thank you...
|
· How to Set the Number of Processes per User
-
-
Open the /etc/system file, using the editor of your choice.
-
Add the following line to the file.
-
- In this command,
-
value.........Is the number of processes a user can run at once.
-
-
Exit the file, saving changes.
-
Reboot the system.
Example--Setting the Number of Processes per User
- The following example shows the line to add to the /etc/system file to allow users to run 10 processes each.
-
· How to Increase the Number of Pseudo-ttys to 256
-
-
Open the /etc/system file, using the editor of your choice.
-
Add the following line to the file.
-
-
-
Exit the file, saving changes.
-
Instruct the system to reconfigure upon rebooting.
-
-
-
Reboot the system.
· How to Increase the Number of Lock Requests
-
-
Open the /etc/system file, using the editor of your choice.
-
Add the following line to the file to increase the number of lock requests (default is 512).
-
-
-
Exit the file, saving changes.
-
Reboot the system.
· How to Increase Shared Memory Segments
-
-
Open the /etc/system file, using the editor of your choice.
-
Add the following lines to the file to accommodate a system with a large amount of memory (for example, 128 MBytes) that is running a large database application.
-
set shmsys:shminfo_shmmax=268435456
set semsys:seminfo_semmap=250
set semsys:seminfo_semmni=500
set semsys:seminfo_semmns=500
set semsys:seminfo_semmsl=500
set semsys:seminfo_semmnu=500
set semsys:seminfo_semume=100
set semsys:seminfo_shmmin=200
set semsys:seminfo_shmmni=200
set semsys:seminfo_shmseg=200
|
-
-
Exit the file, saving changes.
-
Reboot the system.
|
|