Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ binmail(1) — SunOS 3.2/SYS4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

mail(1)

biff(1)

write(1)

uucp(1C)

uux(1C)

xsend(1)

sendmail(8)

aliases(5)

csh(1)

BINMAIL(1)  —  USER COMMANDS

NAME

binmail − send or receive mail among users

SYNOPSIS

/bin/mail [ −i ] [ −p ] [ −q ] [ −f filename ]
/bin/mail address ...

DESCRIPTION

Note: This is the old version 7 UNIX system mail program.  The default mail command is described in mail(1), and its binary is in the directory /usr/ucb. 

/bin/mail with no address prints a user’s mail, message-by-message in last-in, first-out order.  /bin/mail accepts commands from the standard input to direct disposition messages. 

When addresses are named, /bin/mail takes the standard input up to an end-of-file (or a line with just ‘.’) and adds it to each person’s ‘mail’ file.  The message is preceded by the sender’s name and a postmark.  Lines that look like postmarks are prepended with ‘>’.  A person is usually a user name recognized by login, or a network address (see aliases(5)).

If there is any pending mail, login tells you there is mail when you log in.  It is also possible to have the C-Shell, or the daemon biff tell you about mail that arrives while you are logged in. 

To forward mail automatically, add the addresses of additional recipients to the .forward file in your home directory.  Note that forwarding addresses must be valid, or the messages will "bounce."  (You cannot, for instance, reroute your mail to a new host by forwarding it to your new address if it is not yet listed in the YP aliases domain.) 

OPTIONS

Printing Mail

−i continue after interrupts — an interrupt normally terminates the /bin/mail accepts the following interactive commands when printing messages. 

−p print messages without prompting for commands.  Exit immediately upon receiving an interrupt. 

−q quit immediately upon interrupt. 

−f filename
use filename as if it were the mail file. 

Sending Mail

−d deliver mail directly, don’t route the message through sendmail. This option is often used by programs that send mail.

−i continue after interrupts — an interrupt normally terminates the /bin/mail command and leaves the mail file unchanged. 

−r name
specify a string to appear as the name of the sender.

COMMANDS

?  print a command summary. 

EOT (control-D)
put unexamined mail back in the mail file and quit.

!command
escape to the Shell to do command.

− go back to previous message. 

+ go on to next message. 

newline
go on to next message.

d delete message and go on to the next. 

dq delete message and quit. 

m [ person ] ...
mail the message to the named persons (yourself is default). 

n go on to next message. 

p print message (again). 

q same as EOT. 

s [file] ...
save the message in the named files (‘mbox’ default).  If saved successfully, remove it from the list and go on to the next message. 

w [ file ] ...
save the message, without a header, in the named files (‘mbox’ default).  If saved successfully, remove it from the list and go on to the next message. 

x exit without changing the mail file. 

FILES

/etc/passwd     to identify sender and locate address
/usr/spool/mail/∗incoming mail for user ∗
mboxsaved mail
/tmp/ma∗temp file
/usr/spool/mail/∗.locklock for mail directory
dead.letter     unmailable text is saved here
$HOME/.forwardlist of forwarding recipients

SEE ALSO

mail(1), biff(1), write(1), uucp(1C), uux(1C), xsend(1), sendmail(8), aliases(5), csh(1)

BUGS

Race conditions sometimes result in a failure to remove a lock file. 

The superuser can read your mail, unless it is encrypted by des, encrypt, or xsend.  Even if you encrypt it, the superuser can delete it. 

Sun Release 3.2  —  Last change: 23 September 1985

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026