Return to BSD News archive
Received: by minnie.vk1xwt.ampr.org with NNTP id AA6392 ; Sat, 09 Jan 93 01:04:14 EST Xref: sserve comp.sys.sgi:26040 comp.unix.admin:8863 comp.unix.internals:5500 comp.unix.misc:6196 comp.unix.bsd:9793 Newsgroups: comp.sys.sgi,comp.unix.admin,comp.unix.internals,comp.unix.misc,comp.unix.bsd Path: sserve!manuel.anu.edu.au!munnari.oz.au!uunet!pipex!doc.ic.ac.uk!cc.ic.ac.uk!imperial.ac.uk!vulture From: vulture@imperial.ac.uk (Thomas Sippel - Dau) Subject: Re: Problem to transfer large data via socket communication - Need Help Message-ID: <1993Jan11.133545.16876@cc.ic.ac.uk> Sender: vulture@carrion.cc.ic.ac.uk (Thomas Sippel - Dau) Nntp-Posting-Host: cscgc Reply-To: cmaae47@imperial.ac.uk Organization: Imperial College of Science, Technology and Medicine References: <1993Jan8.071612.13716@news.uni-stuttgart.de> Date: Mon, 11 Jan 93 13:35:45 GMT Lines: 32 In article <1993Jan8.071612.13716@news.uni-stuttgart.de>, wnkretz@ikesg1.energietechnik.uni-stuttgart.de (Oliver Kretzschmar) writes: ...... - to send data from socket to socket (stream): - - write(socket,(char*)data,buffer) - read(socket,(char*)data,buffer) - - But now we've problems sending/receiving large data for - example 50*50*50 matrix of floats or larger. Is there any - transfer-bufferlimitation by using streamsockets, that we can - manipulate ? Yes, there is a number of streams buffers configured in the kernel, see (on IRIX) /usr/sysgen/master.d/kernel. However, you main error is to use read/write, which is for "unbuffered" I/O and has generally been designed to be fast and for people who know what they are doing and are willing to cope with hardware limitations themselves. For applications programers the latter is not generally true, so use fread/fwrite and swallow the extra layer of software for the benefit of generality. Thomas -- *** This is the operative statement, all previous statements are inoperative. * email: cmaae47 @ ic.ac.uk (Thomas Sippel - Dau) (uk.ac.ic on Janet) * voice: +44 71 589 5111 x4937 or 4934 (day), or +44 71 823 9497 (fax) * snail: Imperial College of Science, Technology and Medicine * The Center for Computing Services, Kensington SW7 2BX, Great Britain