by these elements: - Packet rate:
Packet rate specifies the number of packets that are sent in a
certain time interval. The packet rate is usually specified in
packets per second (pps). Packet rate is the multiplicative
inverse of the packetization period. The packetization period
is the amount of voice (time) that will be encapsulated per
packet and is usually specified in milliseconds.
- Packetization size: Packetization size specifies the
number of bytes that are needed to represent the voice
information that will be encapsulated per packet. Packetization
size depends on the packetization period and the bandwidth of
the codec that is used.
- IP overhead: IP
overhead specifies the number of bytes that are added to the
voice information during IP encapsulation. When voice is
encapsulated into RTP, UDP, and IP, the IP overhead is the sum
the overhead of all these headers.
- Data-link
overhead: Data-link overhead specifies the number of bytes
that are added during data-link encapsulation. The data-link
overhead depends on the used data-link protocol, which can be
different for each link.
- Tunneling overhead:
Tunneling overhead specifies the number of bytes that are added
by any security or tunneling protocol, such as 802.1Q
tunneling, IPsec, Generic Route Encapsulation (GRE), or
Multiprotocol Label Switching (MPLS). This overhead must be
considered on all links between the tunnel source and the
tunnel destination.
Because some of these elements
come from the same source, the information units that are
needed for bandwidth calculation are packetization period or
packetization size, codec bandwidth, IP overhead, data-link
overhead, and tunneling or security overhead.
Content
2.4 Calculating Bandwidth Requirements for VoIP
2.4.2 Impact of Codecs on Bandwidth A codec
transforms analog signals into digital format. Different codecs
have different bandwidth requirements: - G.711:
The G.711 codec uses the most bandwidth. It encodes each of the
8000 samples that are taken each second into 8 bits, resulting
in a 64-kbps codec bandwidth.
- G.722: The G.722
wideband codec splits the input signal into two sub-bands and
uses a modified version of adaptive differential pulse code
modulation (ADPCM) (including adaptive prediction) for each
band. The bandwidth of G.722 is 64, 56, or 48 kbps.
- G.726: The G.726 ADPCM coding schemes uses less
bandwidth. These coding schemes encode each of the 8000 samples
that are taken each second using 4, 3, or 2 bits, resulting in
bandwidths of 32, 24, or 16 kbps.
- G.728: The
G.728 low-delay code excited linear prediction (LDCELP) coding
scheme compresses PCM samples using a codebook. Waveshapes of
five samples are represented by a 10-bit codeword, which
identifies the best matching pattern of the codebook. Because
of the compression of five samples (worth 40 bits in PCM) to 10
bits, the bandwidth of LDCELP is 16 kbps.
- G.729: The G.729 conjugate structure algebraic code
excited linear prediction (CS-ACELP) coding scheme also offers
codebook-based compression. Waveshapes of 10 bits are
represented by a 10-bit codeword, reducing the bandwidth to 8
kbps.
The bandwidth codec, however, indicates only
the bandwidth that is required for the digitized voice itself.
It does not include any packetization overhead.
Content
2.4 Calculating Bandwidth Requirements for
VoIP 2.4.3 How the Packetization Period Affects
VoIP Packet Size and Rate The packetization overhead that a
VoIP device adds to the codec bandwidth depends on the size of
the added headers and the packet rate. Sending more packets
adds more IP, UDP, and RTP headers to the voice payload. The
overall VoIP bandwidth requirement includes the whole VoIP
packet (headers and voice payload) and the sending rate of the
VoIP packets. On VoIP devices, you can specify, in addition to
the codec, the amount of voice encapsulated per packet.
Usually, this value is configured by the packetization period
(in milliseconds). A higher packetization period results in a
larger IP packet size because of the larger payload (the
digitized voice samples). However, a higher packetization
period results in a lower packet rate, reducing the IP overhead
because of the smaller number of packets that must be
generated. Figure contrasts two scenarios with different
packetization periods. In the first scenario, portions of 20 ms
of voice (160 PCM samples) are packetized. The packet rate is
the reciprocal of the packetization period. If packetization is
done every 20 ms, 50 packets are generated per second. For a
total of 60 ms of voice, three packets, each carrying 20 ms of
voice, are needed. Therefore, packetization of this 60 ms of
voice introduces an overhead of three IP, UDP, and RTP
headers. In the second scenario in Figure , chunks of 30 ms of
voice (240 PCM samples) are packetized. This packetization
results in a lower packet rate of 33.3 pps. For the 60 ms of
voice shown in the figure, only two packets (carrying 30 ms of
voice each) are generated, so the IP overhead is reduced by one
third compared to the first scenario. The default value for the
packetization period on most Cisco VoIP devices is 20 ms. This
default is the optimal value for most scenarios. When you
consider increasing this value to benefit from lower IP
encapsulation overhead, you also have to consider that a higher
packetization period causes a higher delay. The extra delay is
introduced during packetization because more voice information
has to be collected before a packet can be generated and sent.
Caution
You should only increase the default
packetization period if you are sure that the additional delay
can be accepted (for instance, if other sources of delay, such
as buffering, are rather small) and if you cannot solve
bandwidth issues by any other means (for example, using cRTP or
adding bandwidth). Because of the additional overhead, you
should avoid trying to reduce delay by decreasing the default
packetization period and use other methods to reduce delay
(such as QoS or adding bandwidth). The table in Figure shows
examples of VoIP encapsulation with varying codecs and
packetization periods. You can see that an increased
packetization period increases the size of the IP packet while
reducing the packet rate. In the table, the IP overhead is
assumed to be 40 bytes. This value is the normal value for VoIP
packets composed of 20 bytes of IP header, 8 bytes of UDP
header, and 12 bytes of RTP header. If cRTP is used, the IP
overhead decreases. Note
The table in Figure shows
the IP packet size only and does not consider the overhead that
is caused by data-link encapsulation.
Content
2.4 Calculating Bandwidth Requirements for
VoIP 2.4.4 Data-Link Overhead When a VoIP
device sends IP packets over a link within an IP network, the
device encapsulates the packets using the data-link protocol
for that link. Each link can use a different data-link
protocol. Figure illustrates an IP packet that is going from
one IP phone to another. The two IP phones are located in
different LANs and separated by a Frame Relay network. Before
the sending telephone transmits the VoIP packet onto the LAN,
the telephone has to encapsulate the packet into an Ethernet
frame. The router that receives the frame removes the Ethernet
header and encapsulates the VoIP packet into Frame Relay before
sending the packet out to the WAN. The router receiving the
VoIP packet from the Frame Relay network removes the Frame
Relay header and encapsulates the VoIP packet into an Ethernet
frame again before passing the packet on to the receiving IP
phone. As illustrated in Figure , the Ethernet header and the
Frame Relay header differ in size. The overhead of data-link
protocols commonly used for VoIP is 18 bytes for Ethernet, 22
bytes for 802.1Q-tagged Ethernet frames, and 6 bytes for Frame
Relay or multilink PPP (MLP). When you calculate the bandwidth