Community technical support mailing list was retired 2010 and replaced with a professional technical support team. For assistance please contact: Pre-sales Technical support via email to sales@march-hare.com.
> From: Greg Lee [mailto:glee-list at swspec.com] > Sent: Wednesday, 22 March, 2006 10:55 > > > > Please remember to provide both client and server platform > > You are correct, Linux is at both the client (kernel version > 2.6.12) and server (kernel version 2.4.21) ends. Thanks. > > > I am having a problem when I commit changes to any file. The > > > client always returns a > > > message saying "Exec failed: No such file or directory" ... > > > > Offhand it appears that you should be getting more verbose logging of > > what CVSNT is trying to run; I'm not sure why you aren't, but it's late > > and I haven't looked at that part of the source. In fact, with -tttt I > > get a *lot* more trace output from "cvs commit" than what you > > show - did you remove part of the trace output? > > No, I did not remove part of the output. I did use the form > "-t -t -t -t" instead of > "-tttt", but I just tried "-tttt" and it returned the same results. Huh. Maybe tracing is less verbose in the 2.5 sources; I'm running 2.0 here. > I determined that the error is coming from the server side so > I added some code on the > server side to see what is being executed: > > [glee at dev1 zzz]$ cvs -tttt commit -m "testing" > -> main loop with CVSROOT=glee at 192.168.0.94:/home/cvsroot > -> Starting server: /usr/bin/ssh -l glee 192.168.0.94 cvs server > glee at 192.168.0.94's password: > -> Sending file `z.c' to server > Checking in z.c; > /home/cvsroot/zzz/z.c,v <-- z.c > new revision: 1.17; previous revision: 1.16 > done > -> unlink_file(CVS/Base/z.c) > -> Register(z.c, 1.17, Wed Mar 22 15:35:14 2006, , ) > -> rename(CVS/Entries.Backup,CVS/Entries) > -> unlink_file(CVS/Entries.Log) > Exec failed ("(echo ; id; echo zzz z.c,1.16,1.17; date; cat) >> > /home/cvsroot/CVSROOT/commitlog "): No such file or directory > -> Lock_Cleanup() > > This is what I did to get this information: > > --- cvsnt-2.5.03.2260/cvsapi/unix/RunFile.cpp 2006-03-22 > 10:34:54.000000000 -0500 > +++ cvsnt-2.5.03.2260.orig/cvsapi/unix/RunFile.cpp > 2006-01-11 13:00:35.000000000 > -0500 > @@ -184,18 +184,8 @@ > > char **myargv = (char**)m_args->toArgv(); > execvp (myargv[0], myargv); > -{ > - char buf[2000] = "Exec failed (\""; > - int i; > - for(i=0; myargv[i] != NULL && i < 20; i++) > - { > - strcat(buf, myargv[i]); > - strcat(buf, " "); > - } > - strcat(buf, "\")"); > - perror(buf); > + perror("Exec failed"); > exit(-1); > -} > } > > if(m_inFd>=0) Looks OK. > So it looks like something in "(echo ; id; echo zzz > z.c,1.16,1.17; date; cat)" is not > executing. In fact, isn't execvp trying to execute the first > argument in the list, i.e. > "(echo"? "(echo" is not valid, the "(" is wrong. "echo" is > valid assuming it is in the > path. Maybe the intent was to pass this string to a shell > (sh, bash, etc)? That would be my guess. Unfortunately this doesn't seem to be in the 2.0.51d source, which is all I have downloaded at the moment. Perhaps the problem occurs if $SHELL isn't set in the server process's environment? myargv is constructed from m_args, which is probably built as a command line, ie as a single string, so if the command name were missing I bet you'd end up with the first parameter in myargv[0]. -- Michael Wojcik Principal Software Systems Developer, Micro Focus