Using the rlogin Command● To access your workstation remotely to read mail.. Using the rlogin CommandTerminating a Local Process From a Remote Machine When your system is not responding
Trang 1Using the rlogin Command
● To access your workstation remotely to read mail
● To kill a process that has caused your workstation to hang
Command Format
rlogin hostname [-option]
Trang 2Using the rlogin Command
Trang 3Using the rlogin Command
Specifying a Different Login ID
Use the-loption to specify a different login ID for the remote loginsession
The system administrator can set up a guest account so users canremotely log on to a server
Command Format
rlogin hostname -l username
Trang 4Using the rlogin Command
Before attempting to remotely log in to another system as a differentuser, be sure you have an account on the desired remote machine.Check with your system administrator if you do not have an account
on the remote machine The information you will need to know is:
● Machine name
● Login ID
● Password of the new account
Logging in Remotely as Another User
$ rlogin saturn -l user15 Password:
Last login: Mon Dec 21 11:04:27 from venusSun Microsystems Inc SunOS 5.7 Generic October 1998You have mail
Trang 5Using the rlogin Command
Terminating a Local Process From a Remote Machine
When your system is not responding and you do not want to reboot,you may be able to kill a process on your system remotely by logging
on to another machine and using therlogincommand to access yoursystem For example:
$ rlogin hostnamePassword:
Last login: Tue Jun 8 17:40:30 from venusSun Microsystems Inc SunOS 5.7 Generic October 1998You have mail
Trang 6Using the rlogin Command
Session
When your workstation does not appear to be responding to mouse orkeyboard input, the odds are excellent that the problem stems fromwithin your CDE session as opposed to the underlying operatingsystem itself In such cases, you can use another workstation to accessyour workstation via rlogin(ortelnet) and then use thepkill
command to terminate the corrupted CDE session; all withoutrebooting your workstation
$ rlogin hostnamePassword:
Last login: Fri Jul 9 16:50:30 from barneySun Microsystems Inc SunOS 5.7 Generic October 1998
$ pkill -9 loginshell
If you do not know your default shell, type the following command:
$ pkill -9 ‘basename $SHELL‘
which will determine and terminate all instances of your login shell for
you
Either variant will return you to the dtloginscreen, enabling you tostart a new CDE session
Trang 7Network Commands
Theftpcommand (part of an industry-standard application calledFTP, or File Transfer Protocol) is used to transfer files using ASCII orbinary mode between systems using similar or dissimilar operatingsystems Servers with sites set up for downloading files sometimes
provide an anonymousftpaccount so users can pull files off the server.For this kind of an account, at theNameprompt, the wordanonymous
is entered instead of accepting the default displayed If a password isrequired for the anonymous account, it will usually be your full emailaddress
Trang 8Network Commands
Once you have successfully usedftpto access a remote site, somefamiliar file and directory access commands like cdandlsareavailable If permissions are set by the site’s system administrator for auser to see the contents of a directory, the lscommand will displayfiles in that directory If permissions are set such that a user does nothave access to the files, when the lscommand is entered, a promptwill be returned in response As on your local system, cdwill changedirectories on the remote system If it is necessary for you to changedirectories on your own system in the middle of the ftpsession, the
lcd(local change directory) command can be used To end anftp
session, type byeat the prompt
$ ftp venus
Connected to 129.150.212.16
220 venus FTP server (UNIX(r) System V Release 4.0) ready
Name (129.150.212.16:lister): Return <CR>
331 Password required for lister
ftp> get hosts /tmp/hosts
200 PORT command successful
150 Binary data connection for hosts (129.159.129.38,33425) (77 bytes)
226 Transfer complete
local: /tmp/hosts remote: hosts
77 bytes received in 0.0014 seconds (5,25 Kbytes/s)
ftp> bye
Trang 9Using the rusers Command
Use theruserscommand to see who is logged in on the localnetwork
Command Format
rusers [-option(s)] [hostname]
Displaying Remote Users on a Network
Trang 10Using the rusers Command
Displaying Remote Users on a Network
If you want to see whether a specific user is logged in, specify theuser’s host name
Sending broadcast for rusersd protocol version 3
Sending broadcast for rusersd protocol version 2
$
Trang 11The NIS+ Naming Service
The goal of the NIS+ naming service is to allow centralization ofnetwork administration
Decentralized Administration
The administration of a group of machines grows in complexity withthe number of machines and users to manage Thus, decentralizedadministration is conceivable for two or three machines, it becomesmore complex if the number exceeds that limit
For example, imagine a group of five machines If all the users have to
be able to log in as themselves on each machine, the administratormust duplicate the/etc/passwdon every machine Although puttingthis in place initially is possible, maintenance becomes difficult Ineffect, each modification of one element of the password file makes itnecessary to reproduce the change on each machine
Trang 12The NIS+ Naming Service
Decentralized Administration
The problem that is raised by the /etc/passwordfile is exponentiallyincreased by necessary changes to many other administrative files,such as the groups and hosts files
Centralized Administration
It is advisable for administrators to set up networks with a centralizedadministration that distributes a database to all the machines known
by the distributed administration
This database can be centralized on one server, which provides theadministrative services The group of machines using the database on
the server is called a domain This centralized administration uses a
naming service as the framework for the domain(s) NIS (NetworkInformation Service) and NIS+ are two naming services that can be set
up for use in the Solaris networked environment
Note – This section and the following one on NFS™ are intended as
introductions to some networking concepts The topics are in no wayaddressed completely in this class They are covered more fully in the
SA-287: Solaris 7 System Administration II and advanced networking
courses
Trang 13The NFS System
The NFS system is Sun’s distributed computing file system It is anetwork service that allows users to transparently access files anddirectories located on another disk on the network
Trang 14The NFS System
NFS Server
The NFS system server:
● Has a local disk
● Allows access to the resources on the disk to machines withspecified permissions (restrictions)
● Responds to requests from diverse clients
● Does not maintain any status information about the files opened
by clients, so there are no dependencies between server and clients
● Can serve clients of other servers and be an NFS client itself
Trang 15The NFS System
NFS Client
The NFS system client:
● Mounts the desired file system which has been authorized by theNFS system server
● Reads or writes to files on the NFS server
● Maintains open files
● Can access many NFS servers and be an NFS server, if it has alocal disk
Trang 16Exercise: Performing Network Basics
Exercise objective – In this exercise you will use some of the
networking commands introduced in this module
Tasks
Complete the following steps:
1 Use therlogincommand to log in to another machine in yourclassroom
In what directory are you placed on the remote machine?
4 Use therlogincommand and option to log in to another machine
as the userguestwith a password ofguest(or as another user asspecified by your instructor)
5 Log out of the remote machine
Workshop Lab
Use what you have learned so far in this course to work through thefollowing:
1 Start thefindcommand that was previously stopped
2 Log in to your machine from another student’s machine and killthefindcommand
Trang 17Exercise: Performing Basic Network Commands
Exercise Summary
Discussion – Take a few minutes to discuss what experiences, issues,
or discoveries you had during the lab exercises
✓ Manage the discussion here based on the time allowed for this module, which was given
in the “About This Course” module If you find you do not have time to spend on
discussion, then just highlight the key concepts students should have learned from the lab exercise.
● Experiences
✓ Ask students what their overall experiences with this exercise have been You might want
to go over any trouble spots or especially confusing areas at this time.
✓ Explore with students how they might apply what they learned in this exercise to
situations at their workplace.
Trang 18Exercise: Performing Basic Network Commands
Exercise Solutions
Complete the following steps:
1 Use therlogincommand to log in to another machine in yourclassroom
$ rlogin hostname
In what directory are you placed on the remote machine?
A home directory on the remote machine (either/home/username or
/export/home/username) or the root directory (/) if no home directory exists.
2 Issue the command that shows you the hostname of the currentmachine
4 Use therlogincommand and option to log in to another machine
as the userguestwith a password of guest
$ rlogin hostname -l guest
5 Log out of the remote machine
$ exit
Trang 19Check Your Progress
Before continuing on to the next module, check that you are able toaccomplish or answer the following:
❑ Describe the terms client-server and distributed processing
❑ Open a session on a remote machine usingtelnet
❑ Log in remotely to another machine on the network
❑ Use ftpto get a file from a remote system
❑ Identify users logged in on the local network
❑ Describe the concept of naming services
Trang 20Think Beyond
What other advantages of a networked environment can you think of?
Trang 22Upon completion of this module, you should be able to:
● Describe the main features of the Mail Tool
● Compose and send an electronic mail (email) message
● Read an electronic mail message
● Respond to a mail message
● Delete and undelete mail messages
● Set mail aliases
● Create alternate mailboxes
● Attach files to mail messages
● Describe the major functions of the Calendar Manager
● Add appointments to your calendar
● View your calendar in the four formats: Day, Week, Month, andYear
● Set Calendar options
Trang 23✓ Present the following question to stimulate the students and get them thinking about the issues and topics presented in this module While they are not expected to know the answer to the question, the answer should be of interest to them and inspire them to learn the content presented in this module.
Discussion – What types of information do you send through email?
Do you need to send only text, or files in various formats? Do you savemessages?
What advantages can you see to keeping a calendar of appointments
on your system? Would you want to make this calendar available toother users in your group?
Trang 24The Mail Icon and Mail Window
The Mail icon
on the FrontPanel
The Mail iconshowing newmail has been
List of receivedemail messages Message viewingarea
received
Trang 25The Mail Window
By default, the Mail window is divided into two portions
The upper portion displays a list of the email messages which havebeen received
The lower portion displays the text content of the currentlyhighlighted message This allows you to view each message’s contents
by clicking once on an email subject header line in the upper portion
Trang 26The Mail Window
New Messages
A new message, that has not yet been read is shown with the letter
“N” to the left of the sender’s name
Attached Files
When an email message has one or more files attached, a diamondcharacter will be displayed after the New Message indicator (the letterN) To read an attachment, double-click on its icon at the bottom of thewindow
New mailmessages
Attachment
Trang 27Increasing and Decreasing the Message Viewing Area
To increase or decrease the message viewing area, drag the button,circled in the above example, up or down
Trang 28Responding to a Received Message
To reply to a message that you have received, open the Composemenu You are given the choice of replying to the sender or to allrecipients of the message You are also given a choice of including theoriginal message or not Mail is frequently sent out in a mass mailing
to many recipients who happen to be on a mail alias Mail aliases areoften quite large and general, so use the Reply to All option withcaution
If you want to reply and include the message you received, you canbypass the Compose menu and click on the Reply, Include Messageicon on the toolbar of the Mail Tool
Trang 29Responding to a Received Message
Reply, Include Message icon
Trang 30Responding to a Received Message
After you choose a method of reply, the window above will bedisplayed
By default, the original Subject text will be used, preceded by Re:, andthe To: entry will, automatically, be set to the email address of thesender of the message
Trang 31Deleting Mail Messages
Delete
options
Trang 32Deleting Mail Messages
To keep the list of received mail messages to a minimum (and to savedisk space), periodically delete mail messages
There are a number of delete options, which are displayed on thepreceding page
Choosing to delete the mail messages does not remove the mail.Rather, the messages are stored until you close the mail window Thisgives you an opportunity to decide not to delete the message You canforce the mail program to delete any mail messages which werepreviously selected for deletion by clicking on Mailbox ➤ DestroyDeleted Messages
While you continue to work with the mail program, you can view alist of the deleted mail messages and undelete one or more messagesfrom the list When a message is undeleted, it will reappear in the list
of received mail messages
Trang 33Deleting Mail Messages
Trang 34Creating Alternate Mailboxes
Messages that you receive may contain information that you will want
to access at a later time In the CDE Mail Tool, you can create multiplemailboxes for the purpose of storing mail for later retrieval Thesemailboxes can be named to reflect the contents you intend to store inthem
Trang 35Moving Messages to Alternate Mailboxes
Once a new mailbox has been created, you can then use the Movemenu to move received mail into it
Trang 36Composing New Mail Messages
To compose a new mail message, click on Compose➤New Message.This will display a window where you can fill in the appropriateinformation Make sure the address you are sending the message to iscomplete You can include more than one name, separated by commas,
in the To: and CC: fields When you are finished creating the message,click on the Send button in the bottom left corner of the pane to sendthe message to the addressees
Trang 37Attaching Files to Mail Messages
To attach a file to a message you are composing, click onAttachments➤Add File A window will be displayed from which youcan choose the file you want to attach
Trang 38Setting up Mail Aliases
Email addresses can be difficult to remember Mail Tool provides a toolthat allows you to set up aliases for either a particular person or agroup of people that you frequently send mail to This utility can beaccessed by clicking on Options➤Aliases Choose a name for the aliasand enter the email addresses of all users you want to be part of thealias The email addresses must be separated by a comma After analias has been entered, click on Add to place it in your list of aliases.When you are finished creating aliases, click on OK
Trang 39Other Mail Tool Options
Many options can be customized with the different categories listedunder the Options menu Some of these include
● Saving copies of mail that you have sent
● Specifying how often you would like the system to check for newmail
● Specifying how you would like to be notified of new mail
● Setting a vacation message to be sent in reply to messages whenyou are unavailable
● Creating a custom signature that can be attached to all outgoingemail
Trang 40The Calendar Manager
The Calendar Manager icon is situated on the Front Panel
By default, the Calendar window displays a month view of yourcalendar The view can be changed by clicking on one of the four viewicons at the top right hand side of the window, as circled in the
example