• Aucun résultat trouvé

Installing, Configuring, and Using Communications

On an HP-UX system, the terms communications and networking can mean the same thing, or they can refer to different means of having systems interact.

In this manual, networking refers to services provided by networking products (for example, ARPA-Berkley Services). Communications refers to HP-UX commands that help you communicate with other people. The following table shows the communication commands.

Command How It Helps You Communicate

/usr/bin/uuep Provides file transfer among UNIX ™ systems, which includes HP-UX. Additional commands within the uucp facility let you send messages. The facility uses RS-232C.

/usr/bin/mailx Provides electronic mail capability among users having /usr/bin/mail NS-ARPA Services. The mailx and mail commands are user

agents of the sendmail and uuep facilities. An alternative here is to use the elm facility.

/usr/bin/news A command and directory for helping users stay abreast of announcements.

jete/wall U sed by the system administrator to warn users about sudden /ete/ewall changes in the run level of the system, use ewall on an HP-UX

cluster.

/bin/write Copies lines from a local terminal to another user. This rather old command was an early form of electronic mail.

The following sections explain how to use these commands, or they point you to the appropriate documentation.

Constructing an HP-UX System 2-43

Installing, Configuring, and Using uucp

The lusr Ibin/uuep facility lets you transfer files among HP-UX and UNIX

systems.

Prerequisites and Conditions

• You need two or more systems running HP-UX or UNIX and linked by RS- 232-C modem or direct connections.

• Your system is the local system. Any other system is a remote system.

• Meet with system administrators of remote systems to agree on hostnames, the direction of file transfers, and so on.

Procedure

See the UUCP HP- UX Concepts and Tutorials manual to get complete information about planning, installing, configuring, customizing, and using uuep. The manual also explains related commands (for example, eu, uueieo, uux). Besides working manually, you can use SAM as follows:

The following page shows the specific tasks you can perform under this item.

2-44 Constructing an HP-UX System

Under tasks:

you can select and perform the following

Constructing an HP-UX System 2-45

Setting Up mailx and mail or elm

The sendmail facility in the NS-ARPA Services provides the mailx and mail commands. As an alternative, you can set up the elm facility.

Prerequisites and Conditions

• HP-UX systems that have been networked.

• Update HP-UX, if necessary, to include the filesets in the NS-ARPA Services.

• For users to get a message saying they have mail, the. profile file in the home directory should contain these lines:

if [ -f /bin/mail ]

1. To install mail, see the part named "Internetwork Mail-Routing (Sendmail)"

in the Installing and Maintaining NS-ARPA Services. This document has complete information.

2. To use electronic mail, see:

a. The chapter named "Sending and Receiving Mail" in the Beginner's Guide to Using HP- UX.

b. The article named "Mailx" in the Shells and Miscellaneous Tools HP- UX . Concepts and Tutorials.

3. To set up and use elm, see A Beginner's Guide to Using HP- UX.

2-46 Constructing an HP-UX System

Using news

The news command lets you place announcements to users on a system. Users get a message indicating they have news during the login process.

Prerequisites and Conditions

• The / etc/news directory must contain one or more news files .

• The. profile file (or csh . login) in the home directory should contain the following code:

if [ -f /usr/bin/news then news -n

fi

You can get the code from / etc/profile and / etc/ csh . login.

Procedure

1. Ensure that. profile or . csh . login contain the code shown above.

2. Create news files in /usr/news, for example acme-editor:

The ACME Editor was added to the system last night.

To use the editor, get into a shell and type:

acme-ed [Return]

Press? to get help. The help explains what to do.

3. During login, users see a message indicating they have news. To see the news, users execute:

news

4. Each news file appears, preceded by a header such as:

acme-editor (root) Mon Apr 3 23:53:04 1989 5. If a news file scrolls off the display, execute:

news I more

Constructing an HP-UX System 2-47

Using wall or cwall

The command immediately broadcasts a message to every user.

Prerequisites and Conditions

• On an HP-UX cluster, wall writes to users on the system from which the command executed. On an HP-UX cluster, cwall writes a message to users in the cluster.

• The message goes to logged-in users and is preceded by:

Broadcast Message from ...

• In a windowed environment, the message is disruptive and potentially confusing because it appears in every text window including the window from which the user started the window system.

Procedure (Use the same one for cwall in HP-UX clusters) 1. Execute: / etc/wall.

2. The cursor drops down one line, waiting for you to type the message such as:

The system must go down in one minute.

Save your work and log off. Your sys admin apologizes for the inconvenience.

3. When you finish typing the message and wait the appropriate amount of time (indicated in the message), type:

W!D-@

2-48 Constructing an HP-UX System

Using write

A person in a group can use write to communicate interactively with another user.

Prerequisites and Conditions

• Have a terminal connected to a multi-user system.

• Be a member of a group.

• Terminal users must not have used mesg in their. profile files to deny write permission.

Procedure

Use the following syntax:

wri te user [message]

The write command sends message (if supplied) to the terminal of user.

Interaction between the users continues until one of the following things occurs:

1. an end-of-file is read from a terminal ("D);

2. an interrupt is sent (esc); or 3. the recipient executes mesg n.

See write(l) in the HP-UX Reference manual to get more information.

Constructing an HP-UX System 2-49