Hi, On Friday, December 2, 2011 19:41 CET, Henning Brauer <lists-open...@bsws.de> wrote: > * Sebastian Reitenbach <sebas...@l00-bugdead-prods.de> [2011-12-02 16:16]: > > On Friday, December 2, 2011 15:30 CET, Henning Brauer > > <lists-open...@bsws.de> wrote: > > > well, you actually found the answer yourself. if your em is running at > > > 100M the 10MByte/s download is superb. Why it isn't going to gig - dunno. > > > > Yes, Its also not my main concern, I guess, with a different card, I'd also > > get the full 155MBit like I get with Linux in this case. > > I was just curious if someone knows why this card doesn't make GigaBit on > > OpenBSD, therefore appended dmesg... > > i have never seen an em misnegotiating - but this might also have to > do with the choice of switches. > > > But as said, its not my main problem. > > hmm, then i missed it. > > > > your other issue is wasting time, electrons, energy and whatnot with > > > calomel.org garbage. > > > > > > if someone feels like he could do the broader community a favor, track > > > down whoever runs that site and at least ask him to remove that > > > network tuning on openbsd page. or better all pages he has about > > > openbsd - all garbage, bad advice, plain wrong, you get the idea. > > > > OK, I got it, forgetting about calomel.org. > > At least with older OpenBSD releases, there were the recvspace, and > > sendspace to tune the buffers used for the networking. Especially for the > > high bandwith and high latency case, they improved things for me in the > > past. > > the socket buffers are autosized these days. no more manual twiddling > needed. > > > So when I understand you right, there are no knobs anymore I can tune? > > well, I usually touch ifq.len and the icmp err pps limit on higher > bandwidth routers. > > > Also the FAQ: http://www.openbsd.org/faq/faq6.html#Tuning says, it should > > not be necessary for most of the cases, as it states: > > VERY FEW people will need to adjust any networking parameters! > > that statement is true. > > > But since with Linux, I get about 1MB/s more throughput on the > > overseas connection. Since the FAQ did not stated, there are no > > knobs, I was hoping there might be something I can tune for my use case? > > the socket buffer autosizing algorithm might not raise enough in your > case... and if that is indeed the culprit we need to adjust it. > > > If someone can say for sure, there is no knob I can tune, then I'll > > take it as is. > > If there is someone who could explain, why its slower on OpenBSD, so > > that I could understand what the problem is, then I'd like to hear > > about it, and I'd be happy. > > tracking that down isn't trivial. > > at that point, I'd start to read the code and experiment.
Thanks to your pointers on icb, I found the autosizing algorithm at the end of netinet/tcp_userreg.c. There I saw its comparing the actual value of fill level of the buffer, and how much got transferred against a maximum defined in sys/socketvar.h: #define SB_MAX (256*1024) With the default value of 256*1024, I got the maximum transfer rate of about 1.5MB/s. This speed there was fairly constant, when the maximum was reached. Then I doubled the value to 512*1024, and got constant transfer rates of about 2.7MB/s, which is about the same speed like I got with the Linux host. Then I again doubled the value to 1024*1024, and got speeds of about 5MB/s. This was not so constant anymore. Here I got spikes of up to 7MB/s, and in the middle it dropped down to 2-3 MB/s. Then again doubled the value to 2048*1024, and then I got transfer speeds of about 8MB/s. So about 2.5 times faster than with Linux as the server. Also here, the transfer rates are not constant over the download, they are varying from 3MB/s and going up to over 9MB/s, nearly to the maximum the network card in the server provides (100MBit). Since my knowledge to the network stack is next to zero, I don't really know what side effects it would have, to raise the default to a higher value, and if it would acceptable to have those varying transfer speeds, instead of the constant rates with the lower values. Maybe a problem for machines with lower memory? cheers, Sebastian > > -- > Henning Brauer, h...@bsws.de, henn...@openbsd.org > BS Web Services, http://bsws.de, Full-Service ISP > Secure Hosting, Mail and DNS Services. Dedicated Servers, Root to Fully > Managed > Henning Brauer Consulting, http://henningbrauer.com/