[X-Unix] MTUs in Panther

William H. Magill magill at mcgillsociety.org
Tue Nov 23 07:27:56 PST 2004


On 21 Nov, 2004, at 14:45, David Gilden wrote:
> Just got Fiber Optics Internet via Verizon,  Problem is the PCs on the 
> network get
> a data rate of up to 15 MegaBit, but the Mac is stuck at 4.5 Megabits.
>
> Running Panther -- here....  All switches are 100/10 BaseT
>
> A Verzion tech sent me the following link....
> and the link to the Apple KB article, however it is for OSX 10.2
>
> Does anyone have anyone suggestions on in improving the Data Rate for 
> the Mac (G4 1Ghz...)

In System Preferences, Network, Ethernet -- select configure manually.
You will be able to modify the MTU "somewhat."
(this is also in your Mac Help file)
Setting advanced Ethernet options
http://docs.info.apple.com/article.html?artnum=152315

You can (should be able to) also set the MTU with ifconfig. (Never 
tried it.)

However, I do not know if the network interface card in your box 
supports changing the MTU or if it has any kind of bound ... (it's a 
hardware thing).

man ifconfig

Here's a discussion of the issue and an assortment of pointers

http://www.psc.edu/~mathis/MTU/

However, the next question/issue is of course, who is measuring the 
throughput and how?

The data-throughput rate is independent of the speed at which the 
network is operating.

The "wire-speed" for Ethernet will ALWAYS be either 10 or 100 MegaBits 
per second.
How much data is fed onto the wire and transmitted is a different story.

You have a switch involved, make certain that it is set to 
AUTO-NEGOTIATE.

The definition of the Duplex Detection protocol for Ethernet (802.3) 
states that if either end refuses to negotiate, the network adapter 
should default to Half-Duplex! This means that if the switch is 
hard-set to Full-Duplex, the Mac will always default to Half-Duplex, 
and you get a Duplex Mismatch which will result in lowered throughput! 
(This problem is only visible with large file transfers, keystrokes and 
other things, like web pages, are not large enough to make the problem 
visible.)

You could set the duplex on the Mac via ifconfig, but it is a far 
better idea to use the auto-negotiate capabilities, since the Mac does 
it well.

There was a time, roughly 10 years ago, when auto-negotiate did not 
work reliably because of the classic vendor inter-op problem; but that 
was long ago. Today the issue is mostly the fact that most people do 
not understand that Ethernet SPEED is "detected" and DUPLEX is 
"negotiated."

See:
Power Mac G4: Maximizing Ethernet Performance
http://docs.info.apple.com/article.html?artnum=42665

Network Connection Troubleshooting
http://docs.info.apple.com/article.html?artnum=24887

Power Mac G4: Read Me
http://docs.info.apple.com/article.html?artnum=58433

The second major factor effecting network throughput is "where is the 
data going/coming from?" That is to say -- memory to wire to memory 
transfers are ALMOST ALWAYS much faster than disk to memory to wire to 
memory to disk. FTP of large files has been always influenced by the 
efficiency of the FTP program and the I/O subsystem.

The classic test in Unix has been to FTP vumunix (mach_kernel) to 
another system multiple times. The first time, the FTP (or scp) goes 
very slowly, but subsequent copies go much faster. Why? because the, 
nominally, half meg file is read from disk into the I/O buffers on the 
first pass; subsequent copies then simply are re-reading the I/O 
buffer!

To test for both the Duplex problem and the overall I/O issue, create 
"megafile" by copying vmunix (mach_kernel) to it multiple times:
      cp mach_kernel >> megafile

When you get a file that's about a 10 meg, you can ftp it between two 
systems. If there is a duplex mismatch, the ftp will take "forever." It 
starts out quickly and then slows down dramatically over time, to the 
point where it seems it will never complete. A 10 meg file also 
eliminates the benefits derived from a large I/O buffer, and gives you 
a better measure of overall SYSTEM throughput capabilities. The speed 
with which a file can be read from the disk and written to the disk can 
make a big difference in throughput... 5400 RPM drives are simply much 
slower than 7200 or 10K or 15K RPM drives and SCSI faster than ATA.

T.T.F.N.
William H. Magill
# Beige G3 - Rev A motherboard - 768 Meg
# Flat-panel iMac (2.1) 800MHz - Super Drive - 768 Meg
# PWS433a [Alpha 21164 Rev 7.2 (EV56)- 64 Meg]- Tru64 5.1a
# XP1000  [Alpha EV6]
magill at mcgillsociety.org
magill at acm.org
magill at mac.com
whmagill at gmail.com




More information about the X-Unix mailing list