Mailing List Archive

Warning F: Failed to open logfile
Hello

At the moment, I am having a problem when I run Analog in batch via a Java
servlet.

Initially, the servlet writes a cfg file:

c:\monolith2\build\web\reports\serverlogreport-070813070814.cfg

And then uses the following code to execute Analog:

String[] cmd = {AnalogPath, AnalogPars};
try {
Runtime rt = Runtime.getRuntime();
Process pr = rt.exec(cmd);
// Allow Analog time to run.
Thread.sleep(2000);
}
catch(InterruptedException ex) {
}

Where the value for the 'cmd' array in the servlet translates as:

c:\progra~1\analog\analog.exe +g"c:\monolith2\build\web\reports\serverlogreport-
070813070814.cfg" -G

However, the problem is that I receive messages as follows in the default error
file "errors.txt"

c:\progra~1\analog\analog.exe: Warning F: Failed to open logfile
+gc:\monolith2\build\web\reports\serverlogreport-070813070814.cfg -G:
ignoring it
c:\progra~1\analog\analog.exe: Fatal error: failed to open output file
C:\Program Files\analog 6.0\Report.html for writing: exiting

Yet, when I run the instruction manually via 'Run' or in a DOS batch file,
everything is fine and Analog works normally.

Can you tell me where I am wrong?

Thanks

Martin O'Shea.


+------------------------------------------------------------------------
| TO UNSUBSCRIBE from this list:
| http://lists.meer.net/mailman/listinfo/analog-help
|
| Analog Documentation: http://analog.cx/docs/Readme.html
| List archives: http://www.analog.cx/docs/mailing.html#listarchives
| Usenet version: news://news.gmane.org/gmane.comp.web.analog.general
+------------------------------------------------------------------------
Re: Warning F: Failed to open logfile [ In reply to ]
MartinOShea <appy74@...> writes:

I have been able to solve this problem. It was to do with the way I was writing
the 'cmd' array in the Java code.

Thanks anyway.

Martin O'Shea.

+------------------------------------------------------------------------
| TO UNSUBSCRIBE from this list:
| http://lists.meer.net/mailman/listinfo/analog-help
|
| Analog Documentation: http://analog.cx/docs/Readme.html
| List archives: http://www.analog.cx/docs/mailing.html#listarchives
| Usenet version: news://news.gmane.org/gmane.comp.web.analog.general
+------------------------------------------------------------------------
Re: Warning F: failed to open logfile [ In reply to ]
Joshua,

Check the directory permissions for the tree of all directories above the file (ie the /u /u/2 /u/2/j /u/2/j/jf2412). I've run into this programme with one of the web based systems I've written.

If that doesn't work try copying one of the log files to /tmp and seeing if that works (give it '777' permissions within /tmp).

Rgds

Alan Wright
FEHS Techncian

>>> "Stephen Turner" <analog-author@lists.meer.net> 18/04/2008 07:18:38 >>>
On 18/04/2008, Joshua S. Freeman <jf2412@columbia.edu> wrote:
> So, no more ideas, huh?
>
> It's all quiet on the analog front..
>
> It *is* strange, isn't it?
>
> Running analog manually at the command line... File perms wide open...
>
> Passing strange.
>

Well, analog just does a simple fopen(). If anything can read it,
analog should be able to.

What happens if you specify the logfile name on the analog command line?

--
Stephen Turner
+------------------------------------------------------------------------
| TO UNSUBSCRIBE from this list:
| http://lists.meer.net/mailman/listinfo/analog-help
|
| Analog Documentation: http://analog.cx/docs/Readme.html
| List archives: http://www.analog.cx/docs/mailing.html#listarchives
| Usenet version: news://news.gmane.org/gmane.comp.web.analog.general
+------------------------------------------------------------------------


+------------------------------------------------------------------------
| TO UNSUBSCRIBE from this list:
| http://lists.meer.net/mailman/listinfo/analog-help
|
| Analog Documentation: http://analog.cx/docs/Readme.html
| List archives: http://www.analog.cx/docs/mailing.html#listarchives
| Usenet version: news://news.gmane.org/gmane.comp.web.analog.general
+------------------------------------------------------------------------