295 298




Linux Unleashed, Third Edition:FTP and Telnet





-->















Previous
Table of Contents
Next




Using Telnet
Telnet gives you the capability to log into a remote server and act as though you were physically attached to that machine and all its resources. If the server has a powerful CPU, you can use that CPU instead of your weaker local processor. If the server has some special devices, such as a scanner, CD-writer, or magneto-optical storage device, you can use them. You can also use the remote server’s file system.

Using Telnet is quite simple because the protocol takes care of all the configuration and setup processes for you. As part of its startup, Telnet passes a series of messages between the client and server that establish the terminal identifications and special features your terminal allows. All you have to do, really, is tell Telnet which machine you want to log into, then supply the user ID and password.
There are a number of Telnet implementations available for practically every operating system there is. These implementations include commercial products (usually as part of a TCP/IP suite) and public domain or shareware programs that are designed specifically for telnet emulation. The choice of a telnet program is pretty much a personal one because the programs all do the same task.
Starting telnet is a simple matter. If you are at a command prompt, such as on a Linux system, you normally enter the telnet command followed by the name of the remote machine you want to log into. You can supply either a name or an IP address for the remote machine, although a name must be resolvable by TCP/IP into an IP address. Some systems may impose security limitations on Telnet, so if you are not sure of access capabilities, check with your system administrator.
The telnet command supports a lot of options that can customize the behavior of the service, although they are seldom used in typical Telnet sessions. The options supported tend to change depending on the version of Telnet and the operating system, so you may want to check the documentation supplied with your operating system if you want to modify the default behavior of Telnet. Most people find that the standard application is good enough, with no need for options.
Using Telnet and GUIs
If you want to connect to a remote GUI system and display graphics on your local machine, you need to instruct both ends of the connection how to display graphics. If you are connecting from one Linux machine to another, the process is quite easy because Linux has the capability to redirect windowing output with a minimal of fuss. If you are calling from one UNIX or Linux machine to another running Motif, for example, the first step is to allow the remote machine to open windows on your terminal. This is done with the xhost command. The command


xhost +


instructs Linux to allow a remote machine to open windows on your display. (This is an all-encompassing command, allowing any remote machine to open windows on your terminal. This may not be desired, so you can specify the remote machine name following the plus sign to limit access, if you want.)

After you have established a Telnet connection to the remote GUI-based system, you need to instruct it to open all windows on your local machine. With Linux, you can do this with the DISPLAY environment variable. If you are using the C Shell, issue a command like this:


setenv DISPLAY tpciws5:0.0


where tpciws5 is the name of your local terminal. The :0.0 portion of the command following your local terminal name must be supplied, or the GUI will not open windows properly. The setenv command is used by the C Shell to set the environment variable DISPLAY used by Motif and X. Under the Bourne and Korn shells, you must change the command to reflect the syntax of those shells.
TN3270 and Others
Depending on the type of system you are logging into, Telnet may not be able to provide proper terminal characteristics for you. This is especially true of machines, such as IBM mainframes and some minicomputers, that require IBM 3270 terminal emulation. The basic Telnet program is unable to provide this capability, so a special version of Telnet called TN3270 is usually supplied with telnet. TN3270 offers proper IBM 3270 terminal emulation. Some TCP/IP suites also include TN5250, which is a higher-capability terminal than the 3270. Both 3270 and 5250 terminals support full color.
TN3270 and TN5250 can be used with any type of server as long as it can emulate those terminal types. You can use TN3270 to obtain color when connected to a smaller UNIX server, for example, whereas Telnet won’t provide that capability. Most TN3270 and TN5250 systems enable you to change onscreen fonts and colors at will.
Summary
FTP and Telnet are extremely useful on local area networks where you have many applications residing on different machines. Telnet is very easy to get going, start up, and use. All you need is the remote machine’s IP address and a connection (through TCP/IP) to the network. From here, there are a number of related subjects you may want to read about. To learn about:


Setting up X on your Linux systems, see Chapter 22, “Installing and Configuring XFree86.”
Administering your system and the processes on it, see Part VI, starting with Chapter 32, “System Administration Basics.”
FTP sites that hold Linux binaries, see Appendix A, “Linux FTP Sites and Newsgroups.”





Previous
Table of Contents
Next














Wyszukiwarka

Podobne podstrony:
29812
295 QXQQREZZF7RL6FW5Z3GOIJHNMTTISJXXVHVVPNQ
293 295
Naci Bolek Str 295
29818
SHSpec 298 6308C22 Project 80
298 Steele Jessica Pieniądze dają szczęście
Mazowieckie Studia Humanistyczne r1997 t3 n1 s292 298
29819
Naci od Bolcia str 298

więcej podobnych podstron