Discussion:
[Openvpn-users] log files???
Leandro Tracchia
2008-11-03 13:54:59 UTC
Permalink
where are my openvpn logs???

cat /var/log/messages | grep openvpn
cat /var/log/syslog | grep openvpn
cat /var/log/auth.log | grep openvpn

all of these commands show nothing!
tiggersWelt.net (Support)
2008-11-03 14:04:28 UTC
Permalink
Post by Leandro Tracchia
where are my openvpn logs???
cat /var/log/messages | grep openvpn
cat /var/log/syslog | grep openvpn
cat /var/log/auth.log | grep openvpn
all of these commands show nothing!
You may want to take a look at your openvpn-configuration.
Especially the config-options

log and log-append

will answer your questions ;-)
If those aren't specified you might do this on your own and your
openvpn-server will redirect its logs to stdout.
--
\\\||///
\\ - - //
( @ @ )
-oOo--( )--oOo-------------------------------------------------------
Firma Bernd Holzmüller www.tiggersWelt.net
***@tiggerswelt.net
Mönchstrasse 25 Tel: 07 11 / 550 425-90
70191 Stuttgart Fax: 07 11 / 550 425-99
Deutschland/Germany OpenPGP/GnuPG: 0xDF553B9F
Wayne Gemmell
2008-11-03 14:10:49 UTC
Permalink
Post by Leandro Tracchia
cat /var/log/syslog | grep
Try
cat /var/log/syslog | grep ovpn
--
Regards
Wayne Gemmell
Flash Media Group
Tel: 27 (0)12 430 7597 (Ext 04)
Cell: 27 (0)83 666 3342
Leandro Tracchia
2008-11-03 14:12:57 UTC
Permalink
aren't these only command line options??? can i add these options to
server.conf ??
++
--daemon [progname]
Become a daemon after all initialization functions are completed. This
option will cause all message and error output to be sent to the syslog
file (such as /var/log/messages), except for the output of shell scripts
and ifconfig commands, which will go to /dev/null unless otherwise
redirected. The syslog redirection occurs immediately at the point that
--daemon is parsed on the command line even though the daemonization
point occurs later. If one of the --log options is present, it will
supercede syslog redirection.
The optional progname parameter will cause OpenVPN to report its
program name to the system logger as progname. This can be useful in
linking OpenVPN messages in the syslog file with specific tunnels. When
unspecified, progname defaults to "openvpn".
When OpenVPN is run with the --daemon option, it will try to delay
daemonization until the majority of initialization functions which are
capable of generating fatal errors are complete. This means that
initialization scripts can test the return status of the openvpn command
for a fairly reliable indication of whether the command has correctly
initialized and entered the packet forwarding event loop.
In OpenVPN, the vast majority of errors which occur after
initialization are non-fatal.
--syslog [progname]
Direct log output to system logger, but do not become a daemon. See
--daemon directive above for description of progname parameter.
Post by Leandro Tracchia
Den 3. november 2008 kl. 14:54, i meldingen
"Leandro
Post by Leandro Tracchia
where are my openvpn logs???
cat /var/log/messages | grep openvpn
cat /var/log/syslog | grep openvpn
cat /var/log/auth.log | grep openvpn
all of these commands show nothing!
-------------------------------------------------------------------------
Post by Leandro Tracchia
This SF.Net email is sponsored by the Moblin Your Move Developer's
challenge
Post by Leandro Tracchia
Build the coolest Linux based applications with Moblin SDK & win
great prizes
Post by Leandro Tracchia
Grand prize is a trip for two to an Open Source event anywhere in the
world
Post by Leandro Tracchia
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Openvpn-users mailing list
https://lists.sourceforge.net/lists/listinfo/openvpn-users
Jan Just Keijser
2008-11-03 14:19:08 UTC
Permalink
Post by Leandro Tracchia
aren't these only command line options??? can i add these options to
server.conf ??
all commandline options can be included in server/client config files ,
with the leading '--' removed. Thus
openvpn --log-append /var/log/openvpn.log
is equivalent to having
log-append /var/log/openvpn.log
in the corresponding config file.

HTH,

JJK
Post by Leandro Tracchia
++
--daemon [progname]
Become a daemon after all initialization functions are completed. This
option will cause all message and error output to be sent to the syslog
file (such as /var/log/messages), except for the output of shell scripts
and ifconfig commands, which will go to /dev/null unless otherwise
redirected. The syslog redirection occurs immediately at the point that
--daemon is parsed on the command line even though the daemonization
point occurs later. If one of the --log options is present, it will
supercede syslog redirection.
The optional progname parameter will cause OpenVPN to report its
program name to the system logger as progname. This can be useful in
linking OpenVPN messages in the syslog file with specific tunnels. When
unspecified, progname defaults to "openvpn".
When OpenVPN is run with the --daemon option, it will try to delay
daemonization until the majority of initialization functions which are
capable of generating fatal errors are complete. This means that
initialization scripts can test the return status of the openvpn command
for a fairly reliable indication of whether the command has correctly
initialized and entered the packet forwarding event loop.
In OpenVPN, the vast majority of errors which occur after
initialization are non-fatal.
--syslog [progname]
Direct log output to system logger, but do not become a daemon. See
--daemon directive above for description of progname parameter.
Leandro Tracchia
2008-11-03 14:21:20 UTC
Permalink
great! thanks for your help.
Post by Leandro Tracchia
aren't these only command line options??? can i add these options to
server.conf ??
all commandline options can be included in server/client config files , with
the leading '--' removed. Thus
openvpn --log-append /var/log/openvpn.log
is equivalent to having
log-append /var/log/openvpn.log
in the corresponding config file.
HTH,
JJK
Post by Leandro Tracchia
++
--daemon [progname]
Become a daemon after all initialization functions are completed. This
option will cause all message and error output to be sent to the syslog
file (such as /var/log/messages), except for the output of shell scripts
and ifconfig commands, which will go to /dev/null unless otherwise
redirected. The syslog redirection occurs immediately at the point that
--daemon is parsed on the command line even though the daemonization
point occurs later. If one of the --log options is present, it will
supercede syslog redirection.
The optional progname parameter will cause OpenVPN to report its
program name to the system logger as progname. This can be useful in
linking OpenVPN messages in the syslog file with specific tunnels. When
unspecified, progname defaults to "openvpn".
When OpenVPN is run with the --daemon option, it will try to delay
daemonization until the majority of initialization functions which are
capable of generating fatal errors are complete. This means that
initialization scripts can test the return status of the openvpn command
for a fairly reliable indication of whether the command has correctly
initialized and entered the packet forwarding event loop.
In OpenVPN, the vast majority of errors which occur after
initialization are non-fatal.
--syslog [progname]
Direct log output to system logger, but do not become a daemon. See
--daemon directive above for description of progname parameter.
n***@hushmail.com
2008-11-04 17:44:03 UTC
Permalink
On Mon, 03 Nov 2008 08:54:59 -0500 Leandro Tracchia
Post by Leandro Tracchia
where are my openvpn logs???
cat /var/log/messages | grep openvpn
cat /var/log/syslog | grep openvpn
cat /var/log/auth.log | grep openvpn
all of these commands show nothing!
-------------------------------------------------------------------
I believe they reside in the default installation directory for
OpenVPN. For example /etc/openvpn/openvpn.log.

HTH...nD
____________________________________________________________________
_
Post by Leandro Tracchia
Openvpn-users mailing list
https://lists.sourceforge.net/lists/listinfo/openvpn-users
--
Save for the future with great IRA Funds. Click now!
http://tagline.hushmail.com/fc/Ioyw6h4eN0esJJbWmk7lgrZVgQ1v7FuPHg3GJRyOs9939HOkcYx7A1/
n***@hushmail.com
2008-11-04 17:47:39 UTC
Permalink
On Mon, 03 Nov 2008 08:54:59 -0500 Leandro Tracchia
Post by Leandro Tracchia
where are my openvpn logs???
cat /var/log/messages | grep openvpn
cat /var/log/syslog | grep openvpn
cat /var/log/auth.log | grep openvpn
all of these commands show nothing!
-------------------------------------------------------------------
------
I believe that the log for each daemon running is stored in the
default installation directory. For example,
/etc/openvpn/openvpn.log, /etc/openvpn/openvpn1.log, etc. Note that
this is based on the 2.0 version - I don't know if it changed w/
the 2.1 version.


HTH...nD
___________________________________________________________________
Post by Leandro Tracchia
This SF.Net email is sponsored by the Moblin Your Move Developer's
challenge
Build the coolest Linux based applications with Moblin SDK & win
great prizes
Grand prize is a trip for two to an Open Source event anywhere in
the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Openvpn-users mailing list
https://lists.sourceforge.net/lists/listinfo/openvpn-users
--
Save for the future with great IRA Funds. Click now!
http://tagline.hushmail.com/fc/Ioyw6h4eN0e3zf45F9DLDuQIp6bEbN8Br9hoMG0tfxvIBgWlvXGK05/
jessica six
2008-11-05 16:32:47 UTC
Permalink
Is there an easy way to roll the log files?  It seems a HUP/kill -1 doesn't do the trick, either.  If openvpn could log to a syslog facility, that would solve the problem too.
Jan Just Keijser
2008-11-06 08:15:46 UTC
Permalink
/var/log/openvpn.log {
rotate 5
copytruncate
missingok
notifempty
size 512k
}
Is there an easy way to roll the log files? It seems a HUP/kill -1
doesn't do the trick, either. If openvpn could log to a syslog
facility, that would solve the problem too.
openvpn supports syslog: add --daemon and do not specify
--log/--log-append and all messages are automatically sent to syslog.

I mostly use 'log-append' and the following logrotate script:

/var/log/openvpn.log {
rotate 5
copytruncate
missingok
notifempty
size 512k
}


HTH,

JJK

Continue reading on narkive:
Loading...