Re: RE : Packet analysis: WinXP vs. Linux<->VMS shows dramatic differ ences
On Wed, 2004-09-22 at 15:59 +0200, COLLOT Jean-Yves wrote: > Another way > to say is: according to me, the "WinXP vs. Linux<->VMS shows dramatic > differences" topic is true only when using "ruby". Could someone tell me if > I am right or wrong here? We ported the ruby script to C++. I'm in the process of running tests, capturing output, and analyzing it as I did before. Expect results soon ... What I can tell you so far is only that the C++ test runs fine on Linux -> OpenVMS with performance figures similar to the Ruby test. See samba_test.cpp below: Ben -- cut here -- #include #include #include #include #include #include using namespace std; int main(int argc, char * argv[]) { time_t startTime, endTime; char drive[50]; long int blocks = 1, blocksize = 1024; switch (argc) { case 1: strcpy(drive, "S:\\"); break; case 2: strcpy(drive, argv[1]); break; case 3: strcpy(drive, argv[1]); blocks = strtol(argv[2], NULL, 10); if (errno == ERANGE) { cout << "Invalid # of blocks: " << argv[2] << endl; cout << " Default of 1 used." << endl; blocks = 1; } break; case 4: strcpy(drive, argv[1]); blocks = strtol(argv[2], NULL, 10); if (errno == ERANGE) { cout << "Invalid blocks # used: " << argv[2] << endl; cout << " Default of 1 used." << endl; blocks = 1; } blocksize = strtol(argv[3], NULL, 10); if (errno == ERANGE) { cout << "Invalid blocksize # used: " << argv[2] << endl; cout << " Default of 1024 used." << endl; blocksize = 1024; } break; default: cout << "Usage: samba_test.exe {drive {blocks {blocksize}}}" << endl; } cout << "Generating stats with the following arguments:" << endl; cout << "Drive: " << drive << endl; cout << "Blocks: " << blocks << endl; cout << "Blocksize: " << blocksize << endl; char * data; data = new char[blocksize]; memset(data, ' ', blocksize); char dataFile[60]; strcpy(dataFile, drive); strcat(dataFile, "BENCH.TMP"); ofstream fout; time(&startTime); fout.open(dataFile); if (fout.bad()) { cout << "Error opening the data file" << endl; } for (int i=0; i < blocks; i++) { fout << data << endl; } fout.close(); remove(dataFile); time(&endTime); long int elapsed_time = (long) difftime(endTime, startTime), bytesOut = blocks * blocksize; cout << "On drive " << drive << " time to write " << bytesOut << " bytes = " << elapsed_time << " seconds." << endl; delete [] data; return 0; } -- cut here -- PLEASE READ THIS IMPORTANT ETIQUETTE MESSAGE BEFORE POSTING: http://www.catb.org/~esr/faqs/smart-questions.html
RE : Packet analysis: WinXP vs. Linux<->VMS shows dramatic differ ences
Once again, I am sorry, but it looks like I don't understand. As far as I know, Ben pointed out a problem of performances when writing files on a Samba/VMS 2.2.8 server from an XP client. I could reproduce that problem by using "ruby", but I could not by using anything else. Another way to say is: according to me, the "WinXP vs. Linux<->VMS shows dramatic differences" topic is true only when using "ruby". Could someone tell me if I am right or wrong here? When you refer to "a Windows NT 4.0 client on SAMBA 2.0.6", or to issues dealing with "modify in place stream-CRLF or stream-LF files", you are perfectly right, but I don't clearly see the connection with Ben's problem. Porting Samba 3 or 4 to VMS is obviously a very nice thing to do, but I fear that it will take a lot of work and quite some time. In the meantime, I may be able to understand or even fix Ben's problem on 2.2.8, so I prefer to focus on that specific problem. I have a last question: what is exactly "the notepad problem on VMS" ? JYC PLEASE READ THIS IMPORTANT ETIQUETTE MESSAGE BEFORE POSTING: http://www.catb.org/~esr/faqs/smart-questions.html
RE: RE : RE : Packet analysis: WinXP vs. Linux<->VMS shows dramatic differ ences
> -Original Message- > From: > [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] > rg] On Behalf Of COLLOT Jean-Yves > Sent: Wednesday, September 22, 2004 9:47 AM > To: 'John E. Malmberg'; '[EMAIL PROTECTED]' > Subject: RE : RE : Packet analysis: WinXP vs. Linux<->VMS > shows dramatic differ ences > > > In order to see the slow behavior, the file transfer has to > be greater > > than 64,000 Kb. With smaller files, it will not be seen. > > Excuse me, but I don't agree. I just ran Ben's "ruby" bench, > which is creating that 1 Kb file, and I can see the very, > very slow behaviour: it takes more than 36 seconds to run the > bench (compared to 2.35 seconds for running a simple COPY). > > I thought Ben's bench results were the point, but I may have > misunderstood. > Could you tell me exactly what kind of tests I could make in > order to reproduce that other kind of slow behaviour you are > referring to? The confusion is a matter of blocks vs. bytes. In my original message I said that the pattern changes after the first 64K is written, not after the first 64,000K is written. Ben PLEASE READ THIS IMPORTANT ETIQUETTE MESSAGE BEFORE POSTING: http://www.catb.org/~esr/faqs/smart-questions.html
Re: RE : Packet analysis: WinXP vs. Linux<->VMS shows dramatic differ ences
COLLOT Jean-Yves wrote: Hi. - BENCH.TMP is a 1 Kb local file (the file created by Ben's ruby bench) Hello Jean-Yves, In order to see the slow behavior, the file transfer has to be greater than 64,000 Kb. With smaller files, it will not be seen. Ben, There is nothing that I can find in the VMS specific or VMS modified part of the code that would cause the protocol to be negoticiated differently. It may be that this is something that was fixed in Samba post 2.2.8. Samba 3.x knows about more protocol negotiations than Samba 2.x, and Samba 4 will know even more. Right now I am trying to untangle a dependency there are now 5 different sized "struct stat" structures on VMS depending on what version of VMS that the code was compiled on and the build options, and if the modules are compiled with different #defines set, bad things happen, some hard to detect. -John [EMAIL PROTECTED] Personal Opinion Only PLEASE READ THIS IMPORTANT ETIQUETTE MESSAGE BEFORE POSTING: http://www.catb.org/~esr/faqs/smart-questions.html
RE : Packet analysis: WinXP vs. Linux<->VMS shows dramatic differ ences
Hi. I was very interested (and very surprised) by the experiments and results described in the last messages, so I tried to reproduce the issue myself. Note that, instead of using Ethereal or other utilities, you can run smbd with log level 3, and all the transactions are logged. I downloaded the "ruby" stuff, and I ran the bench provided by Ben Armstrong. I saw exactly the behaviour described by Ben (1024 bytes writes, 1 byte writes, QUERY_FILE_INFOs, etc..). The result is incredibly slow. I did some other tests with a simple "copy" DOS command, and with copy/paste clicks in the Windows Explorer. Those times, there was only 61 Kb writes. No more 1024 bytes writes, no more 1 byte writes, no more QUERY_FILE_INFOs, and good performances. I then used a utility (http://www.pc-tools.net/win32/ptime/) that you may know, and that enables you to get the execution time of a command. Here are the results, for a "COPY BENCH.TMP Z:\BENCH.TMP" command : - BENCH.TMP is a 1 Kb local file (the file created by Ben's ruby bench) - My whole network is 100Mbits/Full Duplex - My client is a Windows XP/SP2 PC - when Z: is a Samba/Linux box (bi-processors Intel 2Ghz), the elapsed time is 2.75 seconds - when Z: is a Windows NT server (a quite old one, I don't know exactly the type), the elapsed time is 3.79 seconds - when Z: is a Samba/VMS Alpha DS20-666, the elapsed time is 2.35 seconds As you see, the performances of Samba/VMS are not so bad. My feeling is that there are some strange things happening between Windows/Ruby and the Samba/VMS server. Fixing that will probably be quite difficult, and will probably demand analysis of the Ruby code as much as the Samba code, in order to understand what happens. Is this Ruby thing used by many people? Do any of you have similar very bad performances when writing a file, but with other software? JYC PLEASE READ THIS IMPORTANT ETIQUETTE MESSAGE BEFORE POSTING: http://www.catb.org/~esr/faqs/smart-questions.html