Presentation is loading. Please wait.

Presentation is loading. Please wait.

File Transfer & Access (FTP, TFTP, NFS)

Similar presentations


Presentation on theme: "File Transfer & Access (FTP, TFTP, NFS)"— Presentation transcript:

1 File Transfer & Access (FTP, TFTP, NFS)
Chapter 25

2 File Access & Transfer Many network systems provide file access on remote machines Lots of designs; each optimized for some goals Lower overall cost; use centralized file server Data archive Data sharing by multiple users, programs or sites

3 On-line Shared Access Two distinct forms of file sharing
On-line access Multiple programs can access single file concurrently Changes take affect immediately; available to all Whole-file copying Program obtains local copy to access a file Often used for read-only data If must be modified, changed copy is transferred back

4 File sharing is usually easy to use
Advantage: no change to application programs Disadvantages may be less obvious Network/Remote machine down: application may not work Remote could be overloaded or network congested Application appears unreliable Implementing integrated, transparent access may be difficult File names may be hard to map Mechanism must handle notions of ownership, authorization, and access protection Different file representations may make it difficult or impossible to implement all operations on all files

5 Sharing by File Transfer
Alternative to transparent, integrated, on-line access User obtains local copy; operates on the copy Transfer mechanism not integrated w/file system Special client program used to transfer files Specify remote machine & any login information Client contacts server and asks for copy of file After transfer, user terminates client Have efficient usage of file once have copy

6 Whole-file transfer can be difficult
Client & server must agree on: Ownership, protection, authorization, data format Exact detail of differences in representation techniques depends on the systems involved Information can be lost during translations

7 FTP – File Transfer Protocol
The major TCP/IP file transfer software File transfer one of most used TCP/IP applications Accounts for much network traffic Early ARPANET transfer protocols evolved into current standard Other functions offered beyond file transfer: Interactive interface with remote server File format specification Authentication control

8 FTP Process Model FTP servers allow concurrent access by multiple clients Clients use TCP to connect Have usual master/slave functions Except, slave not perform all necessary computation Slave handles control connection from the client Carries commands telling which file to transfer Separate processes handle data transfer connection Also uses TCP as the transport protocol

9 Figure 25.1

10 TCP Port Number Assignment
Multiple connections require multiple ports Control connection: Client: random, locally assigned port Server: uses well-known port (21) For data transfer: Client: unused port; server process: FTP data transfer port (20) Server cannot accept connection from any process Control connection used to communicate port number Client control process gets port for data transfer; creates transfer process to listen; sends number to server over control connection; waits for server to connect to the port Use NVT protocol for data on the control connection

11 Anonymous FTP FTP contains access authorization facilities
Strict enforcement keeps arbitrary users away Anonymous FTP used to access public files Client does not need an account or password Uses login name of anonymous; password guest Have access, but only to public files

12 ftp> open ftp.cs.purdue.edu
Connected to lucan.cs.purdue.edu. 220 lucan.cs.purdue.edu FTP server (Version wu-2.6.2(1) Mon Feb 28 15:45:56 EST 2005) ready. User (lucan.cs.purdue.edu:(none)): anonymous 331 Guest login ok, send your complete address as password. Password: 230- Purdue University Department of Computer Sciences Access is allowed all day. Local time is Thu Aug 3 12:46: All transfers are logged with your host name and address. If you don't like this policy, disconnect now! If your FTP client crashes or hangs shortly after login, try using a dash (-) as the first character of your password. This will turn off the informational messages which may be confusing your ftp client. Report any problems to 230 User ftp logged in. Access restrictions apply.

13 Remote system type is UNIX.
Using binary mode to transfer files. ftp> ls 200 PORT command successful. 150 Opening ASCII mode data connection for /bin/ls. total 14 drwx Jan OLD d--x--s--x Jun bin d--x--s--x Jun dev d--x--s--x Apr d--x--s--x Jun lib drwxr-sr-x May 2 14:00 pub d--x--s--x Apr usr 226 Transfer complete.

14 ftp> help Commands may be abbreviated. Commands are: ! debug mdir put size $ dir mget pwd status account direct mkdir quit struct append disconnect mls quote system ascii form mode recv sunique bell get modtime reget tenex binary glob mput rstatus trace bye hash newer rhelp type case help nmap rename user cd idle nlist reset umask cdup image ntrans restart verbose chmod lcd open rmdir win close ls prompt runique ? cr macdef proxy send delete mdelete sendport site ftp> quit 221-You have transferred 0 bytes in 0 files. 221-Total traffic for this session was 1476 bytes in 1 transfers. 221-Thank you for using the FTP service on lucan.cs.purdue.edu. 221 Goodbye.

15 TFTP FTP is the most general file transfer protocol in the TCP/IP suite Also most complex & difficult to program Many applications do not need full functionality Has second file transfer protocol Provides inexpensive, unsophisticated service Trivial File Transfer Protocol (TFTP) Intended for applications with less complex interactions between the client and the server

16 Secure File Transfer Original FTP has password mechanism
Password and data are unencrypted Other protocols have added security Secure Sockets Layer FTP (SSL-FTP) Uses secure socket mechanism Secure File Transfer Program (sftp) Alternative to FTP; uses SSH tunnel Secure Copy (scp) Uses same syntax as Unix copy command Uses SSH

17 Summary Two forms of remote data access FTP uses whole-file copying
Shared on-line access FTP uses whole-file copying Provides transfer and user interface facilities TFTP provides simple alternative for FTP Are secure alternatives to FTP


Download ppt "File Transfer & Access (FTP, TFTP, NFS)"

Similar presentations


Ads by Google