logo       

Re: 2.0-beta6: "Error: cannot open" with log-append: msg#00495

network.openvpn.user

Subject: Re: 2.0-beta6: "Error: cannot open" with log-append

Mathias Sundman <mathias@xxxxxxxxxx> said:

> When I start openvpn as a service on WinXP I get the following in my
> log-file:
>
> Sun Jun 27 22:34:37 2004 Error: cannot open --log file: c:\program
> files\openvpn\log\ljustero.log: The process cannot access the file because
> it is being used by another process. (errno=32)
> Sun Jun 27 22:34:37 2004 Exiting

Using --log or --log-append in a service is sort of redundant because the
service is already redirecting stdout/stderr to a log file before it starts
the openvpn.exe process.

Maybe what's happening is that the service wrapper (openvpnserv.exe) is
already opening ljustero.log and setting stdout/stderr to point to it,
executing openvpn.exe, and then openvpn.exe is trying to open the same file
that's already open.

If you want to append to the log file from a service, it would be better to
change the registry setting that controls that (see install notes) rather than
putting --log-append into the config file.

>
>
> If I start openvpn by right-clicking the same config-file, it works as it
> should, and I get the logging in the file I've specified with log-append.

Right, log and log-append are really designed for cases where you are running
openvpn.exe yourself, or instantiating openvpn.exe from another app of your
own design, rather than when it is run automatically from the openvpnserv.exe
service wrapper.

James



-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 -
digital self defense, top technical experts, no vendor pitches,
unmatched networking opportunities. Visit www.blackhat.com


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise