The packet switching can broadly be divided into two main categories, first is the virtual circuit approach and other is the datagram approach. In the virtual circuit approach to packet switching, the relationship between all packets belonging to the message or a session is preserved. A single route is chosen between the sender and the receiver at beginning of the session. When the data are sent, all packets of transmission travel one after another along that route. The wide area networks use the virtual circuit approach to the packet switching. The virtual circuit approach needs a call setup for establishing a virtual circuit between the source and destination. A call teardown deletes virtual circuit. After the setup, routing takes place based on the identifier known as the virtual circuit identifier. This approach can be used in the WANs, frame relay and an ATM.
In the other approach of packet switching that is the datagram approach, each packet is treated independently of all others. Even if one packet is just a piece of a muti-packet transmission, the network treats it as though it is existed alone. Packets in this approach are known as the datagram. The internet has chosen datagram approach to switching in the network layer. It uses the universal addresses defined in network layer to route packets from the source to destination.
In the other approach of packet switching that is the datagram approach, each packet is treated independently of all others. Even if one packet is just a piece of a muti-packet transmission, the network treats it as though it is existed alone. Packets in this approach are known as the datagram. The internet has chosen datagram approach to switching in the network layer. It uses the universal addresses defined in network layer to route packets from the source to destination.