Logo What's New

Let our core competencies complement yours...

 Company  About Us  Services  Technology  News  Contact Us  Search
Bar

AppleTalk   Networking: A Lower Layers Primer

AppleTalk  is a proprietary protocol architecture developed by Apple Computer Inc.  AppleTalk  shares many characteristics with IPX and IP.  AppleTalk transport and application services operate over a best effort delivery datagram protocol (Datagram Delivery Protocol, DDP).  AppleTalk  transport services provide reliable delivery by using the AppleTalk Data Stream Protocol (ADSP).

AppleTalk Version 2 operates a distance-vector based routing protocol, Routing Table Maintenance Protocol (RTMP), which like IP and IPX RIP, constructs best paths based on hop-count information propagated through neighbors. Like Novell Netware/IPX, AppleTalk  protocols support client-server, networked operating system (NOS) capabilities.

AppleTalk Stack :

AppleTalk Filing, Postscript

ZIP, PAP, AppleTalk Session and Data Stream protocols

Routing Table Maintenance and Name Binding Protocols

Datagram Delivery Protocol and AppleTalk ARP

Link and Physical stuff

Computers (primarily Macintosh and Power Macintosh, but in some cases PCs or enterprise servers, e.g., AS/400s) use AppleTalk  protocols and services to share resources such as printers or files.  For example, the Printer Access Protocol is used between end node clients  and printers or print servers to download files for printing.  The Filing Protocol (AFP) is used by clients and servers to access and share files across a network.

AppleTalk  addresses. AppleTalk addresses are 24 bits long.  Apple injects hierarchy to its addressing scheme by assigning a given network a range of 16 bit network numbers, where each number in that range is capable of supporting 254 nodes; such networks are called Extended AppleTalk  networks.  These are distinguished from a non-extended network, which is a network having only a single 16-bit network number, and hence capable of supporting a maximum of 254 nodes.  In the AppleTalk network topology depicted on the right, we illustrate two networks connected via a router, one with a single network number of 53, the other with network numbers assigned in the range 20-25.

 Zones. An AppleTalk  network is logically divided into areas called zones .  Zones help a user identify where a network entity, or service, can be found; i.e., they are used to constrain a name lookup to a group of logically associated nodes.  Each node in an AppleTalk network belongs to one and only one zone.  Extended networks can have multiple zones.  We assigned a zone name inside to the group of nodes in network number 53 above, and outside to the group of end nodes network range 20:25 in the AppleTalk network topology shown earlier.
 

Names  Name Binding .  A network-visible entity (NVE) is an AppleTalk network-addressable service, such as a socket.  Each NVE has at least one name, for example HP5ML@inside (the Hewlett-Packard printer identified as node 53.17 in the AppleTalk  network topology supports the Printer Access Protocol, PAP).  An NVE also has an attribute list associated with it, which identifies the characteristics of the NVE.  Named NVEs are associate with or bound to their network addresses through the name binding process. Name binding may be performed when a node first joins an AppleTalk network, or dynamically, immediately before the first use of a name. The Name Binding Protocol (NBP) is used by end nodes and routers to register, confirm and delete names.  Like TCP/IP s DNS, NBP is also used to associate names with addresses by nodes wishing to connect to remote services.
 

The Name Binding information maintained by the router our sample network topology might look like this:
 

 Net  Adr  Skt    Name                        Type                 Zone

 53  24   254   atalk-rtr.xyz.com.EtherciscoRouter                inside

 53  24     8   atalk-rtr.xyz.com      SNMP Agent                 inside

 21  139  254   atalk-rtr.xyz.com.EtherciscoRouter               outside

 59  114    8   atalk-rtr.xyz.com      SNMP Agent                outside
 

 Discovery Mechanisms: AARP. AppleTalk is a plug and play  architecture.  End nodes acquire a unique AppleTalk  address; end nodes also learn of resources and their locations dynamically. Nodes accomplish dynamic address configuration by using a feature of the AppleTalk  Address Resolution Protocol (AARP) called Probe.  A node proposes an AppleTalk address for itself, broadcasts the address over the network, and waits for a reply from any other node on the network claiming that the address in the probe is already in use.  The probe is repeated a number of times to increase the probability that all nodes will receive a copy.  If the node doesn't receive a response, then it concludes that the address is unique on the network and assigns the address to its interface.  If a response to a probe is received (i.e., another node has claimed the proposed address), the node proposes a new address, and repeats the probe process until it succeeds in acquiring an unused address, or until all assignable addresses are exhausted.  This addressing selection scheme is medium-independent; with AARP, AppleTalk  addresses can be associated with any length MAC or data link service addresses (so in practice, AppleTalk  can run over Ethernet, Token Ring, and FDDI LANs, and SMDS WANs or ATM LANs or WANs).
 

The AppleTalk ARP table for our sample network might look like this:
 

 Address      Age (min)  Type              Hardware Addr        Encap     Interface

 53.24              -   Hardware          0000.0c31.ae22.0000   SNAP     Ethernet0

 53.17              1   Dynamic           0800.079c.4e06.0000   SNAP     Ethernet0

 53.70              5   Dynamic           0005.0260.23d0.0000   SNAP     Ethernet0

 53.3               1   Dynamic           0005.0260.23de.0000   SNAP     Ethernet0

 53.51              9   Dynamic           0005.0260.23a1.0000   SNAP     Ethernet0

 21.139             -   Hardware          0000.0c31.ae23.0000   SNAP     Ethernet1

 21.20              2   Hardware          0005.0260.23a4.0000   SNAP     Ethernet1

 21.17              3   Hardware          0005.0260.2303.0000   SNAP     Ethernet1

 (node 20.25 is powered off)

 Routers must have a unique address for each AppleTalk  interface as well.  Certain router implementations do not support dynamic assignment, so addresses must be explicitly assigned to each AppleTalk  interface through the router s configuration management system.  Other routers perform AARP as described.
 

Discovery Mechanisms: ZIP. Once an end node acquires an address, it uses the Zone Information Protocol (ZIP) during network initialization to choose a zone and to acquire internetwork zone information.  An end node obtains zone and internetwork information from routers on the network by broadcasting ZIP messages requesting this information.  Routers supply the zone name to network range bindings in ZIP replies.  The Zone information for our sample topology looks like this:
 

 Name                                                        Network(s)
 outside                                                     20-25
 inside                                                      53
 Total of 2 zones
 

Routing. Like IP and IPX, routers forward data packets from source nodes to destination nodes across heterogeneous media.  When a router receives a DDP packet, it checks to see if the packet's destination network number is the local network.  If it is, the router passes the packet down to the data link layer which forwards the packet toward the destination node.  If the destination network number is a different network, the router refers to its routing tables to determine the next hop on the shortest path toward the destination.

To forward a DDP packet to a directly connected node over a given medium, a router must know the hardware-specific address that corresponds to the destination node s 24-bit AppleTalk  address.  Just as IP hosts and routers maintain an IP-to-hardware address cache and use IP ARP to maintain that cache, an AppleTalk  router maintains list of mappings between AppleTalk  and corresponding hardware addresses and uses AARP to maintain an Address Mapping Table.  When the router attempts to send a packet to a given AppleTalk  address, it scans its local AARP cache to find the corresponding hardware address.  If the hardware address is not known, the router broadcasts a single AARP packet requesting the address mapping.  The node whose AppleTalk address matches that specified in the request packet replies with the hardware address that corresponds to the AppleTalk address.  The router then updates its address table with this new information.

Most operational AppleTalk  networks use an adaptive routing protocol called the Routing Table Maintenance Protocol (RTMP) to create and maintain a routing database for an AppleTalk  network. The accuracy of the routing database is maintained by having each router periodically broadcast its topology information to all neighboring routers (i.e., routers directly reachable over one of the routers AppleTalk -enabled interfaces). All routers receiving the this information to update their own routing tables; i.e., they compute the least cost path to all destinations, RTMP routing tables contain an entries of the form {destination network, interface over which packets for this destination are to be forwarded, next-hop node address, hop count to destination, and route state (good, suspect, or bad)}. Some routers route strictly on hop-count, while others allow a network administrator to assign a weighted cost value to AppleTalk interfaces (up to a maximum cost of 15, the maximum hop count value for RTMP).  The routing table maintained by the router in our sample topology looks like this:
 

Codes: R - RTMP derived, E - EIGRP derived, C - connected, A - AURP
       S - static  P - proxy
2 routes in internet

The first zone listed for each entry is its default (primary) zone.

C Net 53    directly connected, Ethernet0, zone inside
C Net 20-25 directly connected, Ethernet1, zone outside

Router Responsibilities. In addition to supporting AARP and RTMP, AppleTalk  routers must support the Zone Information Protocol (ZIP), which is used to map network numbers to zone names on the network, and the Name Binding Protocol (NBP), which is used to bind names of network visible entities  (e.g., printers or file servers) to AppleTalk addresses.  Each router periodically broadcasts ZIP Query packets requesting zone list information to all routers in the network, and constructs a local zone information table from the replies it receives. This information is used by end nodes for zone selection and resource location. Routers also assist in name-to-address processing on behalf of end nodes by listening for NBP Broadcast Request packet for a named entity from an AppleTalk node, and either broadcasting an NBP Lookup Request packet across the local zone or issuing an NBP Forward Request packet toward the router connected to the destination zone.

Conclusions. AppleTalk is a remarkably easy network system to install and operate.  The naming system is intuitive to users.  The mechanisms to access networking, for example, the MacOS Control Panels  Chooser, Users  Groups, Sharing Setup, File Sharing Monitor use the naming system and free users completely from having to understand anything about how AppleTalk works.  This ease-of-use comes with a price.  The routing, naming, and addressing support system are demanding on the routed infrastructure: they consume CPU cycles and bandwidth, and rely heavily on the features of multi-access broadcast LANs such as Ethernet.

Bar
[Company] [About Us] [Services] [Technology] [News] [Contact Us] [Search]

Contact our webmaster with questions or comments regarding this site.
Copyright 2008 Core Competence, Inc. All rights reserved.