SYSC_3303_TFTP_Design2.13

SYSC_3303_TFTP_Design2.13 - SYSC 3303 Real-Time Concurrent...

Info iconThis preview shows pages 1–10. Sign up to view the full content.

View Full Document Right Arrow Icon
SYSC 3303 - TFTP Client-Server Design Part 2 1 SYSC 3303 Real-Time Concurrent Systems TFTP Client-Server Design Part 2 Copyright © 2000-2003 D.L. Bailey, Copyright 2002-2005 © L.S. Marshall, Systems and Computer Engineering, Carleton University revised March 1 st , 2005
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
SYSC 3303 - TFTP Client-Server Design Part 2 2 What's In This Set of Slides? • We'll show how to use UCMs to model the cause- effect scenarios that result in ERROR packets being sent while writing a file from a client to a server • We'll show how to use UCMs to model the wait for acknowledgment/timeout/retransmit protocol used by TFTP to recover when packets are lost • We’ll show how to use UCMs to reason about the behaviour of a TFTP client & server when packets are delayed or duplicated • We'll show how to use UCMs to visualize the Sorcerer's Apprentice Bug & its solution
Background image of page 2
SYSC 3303 - TFTP Client-Server Design Part 2 3 ERROR Packets • Recall that errors detected during TFTP file transfer result in an ERROR packet being sent by the host that detects the error to the host at the other end of the connection • The next several slides use UCMs to model the cause-effect paths through the system when errors occur while a client writes a file to a server
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
SYSC 3303 - TFTP Client-Server Design Part 2 4 UCM: Error-free WRQ Datagram Socket Datagram Socket (port 69) Datagram Socket Client Server for m - WRQ x -dgram send-dgram x rcv dgram x extract -msg x x x verify-WRQ x x -ACK x verify- ACK x x x x create-socket
Background image of page 4
SYSC 3303 - TFTP Client-Server Design Part 2 5 WRQ Errors • Cause: the server receives a message through port 69 that is not a properly formed WRQ packet (invalid opcode, filename, or mode fields) • Effect: the server creates an ERROR packet with error code 4 (illegal TFTP operation), sends it to the client, and terminates the connection
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
SYSC 3303 - TFTP Client-Server Design Part 2 6 WRQ Errors • Cause: the server receives a WRQ packet, but cannot open the specified file for writing • Effect: the server creates an ERROR packet with error code 2 (access violation), error code 3 (disk full), or error code 6 (file already exists - do we really need this one?); sends it to the client; and terminates the connection – errors detected depend on the file I/O library provided by the programming technology
Background image of page 6
SYSC 3303 - TFTP Client-Server Design Part 2 7 UCM for WRQ Error Handling • New responsibilities (see next slide): – form-ERROR: prepare a TFTP ERROR packet – handle-ERROR: determine that the received message is a TFTP ERROR packet and handle the error condition (release resources, terminate connection)
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
SYSC 3303 - TFTP Client-Server Design Part 2 8 UCM: WRQ Error Handling Datagram Socket Datagram Socket (port 69) Datagram Socket Client Server for m - WRQ x -dgram send-dgram x rcv dgram x extract -msg x x verify-WRQ x x -ERROR x x x x x create-socket handle-ERROR x done
Background image of page 8
SYSC 3303 - TFTP Client-Server Design Part 2 9 WRQ Errors (2) • Cause: a WRQ packet is duplicated between the client and server. The server establishes two connections, and sends two ACK packets (with
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 10
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 55

SYSC_3303_TFTP_Design2.13 - SYSC 3303 Real-Time Concurrent...

This preview shows document pages 1 - 10. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online