Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[stunnel-users] Stunnel log file limit

216 views
Skip to first unread message

mehmet ozisik

unread,
Jul 18, 2013, 2:53:05 AM7/18/13
to
Hi,

I would like to ask some questions regarding stunnel logging which I could not find answer with googling.

1) what is the limit of stunnel log file (can we define this)?
2) If there is a limit, when the limit is reached does it remove the filled file and starts with the same name an empty log file?


Regards
Mehmet

Michal Trojnara

unread,
Jul 18, 2013, 4:11:30 AM7/18/13
to
Log rotation is already on my TODO list:
https://www.stunnel.org/sdf_todo.html

Mike
_______________________________________________
stunnel-users mailing list
stunne...@stunnel.org
https://www.stunnel.org/cgi-bin/mailman/listinfo/stunnel-users

mehmet ozisik

unread,
Jul 18, 2013, 4:26:30 AM7/18/13
to
Hi Michal,

thanks for the fast response.
But in to do list it seems that rotate is for windows.Also seems never be supported.
I mean for linux also stunnel's self log rotation.

Could you please inform me?

Regards
Mehmet


2013/7/18 Michal Trojnara <Michal....@mirt.net>

Michal Trojnara

unread,
Jul 18, 2013, 4:36:37 AM7/18/13
to
mehmet ozisik wrote:
> I mean for linux also stunnels self log rotation.
>
> Could you please inform me?

Try:
https://www.google.com/search?q=linux+log+file+rotation

mehmet ozisik

unread,
Jul 18, 2013, 4:49:29 AM7/18/13
to
Hi Michal,

I am running stunnel on a minimal system which has limited flash size, so using extra binary is expensive for me.
I know those mechanisms there are on linux. But I am asking something like this within stunnel codes :
While stunnel running it will check also log size, then when stunnel realized the log size limit (which is defined in conf file for example) reached it will re-open the log file in write mode (by the way old info will be deleted).

Regards
Mehmet


2013/7/18 Michal Trojnara <Michal....@mirt.net>
mehmet ozisik wrote:

Michael D. Setzer II

unread,
Jul 18, 2013, 6:26:06 AM7/18/13
to
On 18 Jul 2013 at 11:49, mehmet ozisik wrote:

Date sent: Thu, 18 Jul 2013 11:49:29 +0300
From: mehmet ozisik <mehm...@gmail.com>
To: Michal Trojnara <Michal....@mirt.net>
Copies to: stunne...@stunnel.org
Subject: Re: [stunnel-users] Stunnel log file limit

>
> Hi Michal,
>
> I am running stunnel on a minimal system which has limited flash size,
> so using extra binary is expensive for me. I know those mechanisms
> there are on linux. But I am asking something like this within stunnel
> codes : While stunnel running it will check also log size, then when
> stunnel realized the log size limit (which is defined in conf file for
> example) reached it will re-open the log file in write mode (by the
> way old info will be deleted).
>
> Regards
> Mehmet

I did some testing, and this is what I came up with that seems to
work. Original had just tried deleting the log file, but then later
usage of stunnel would not add to the file. truncate seems to keep
the file in a state were stunnel will continue. I used 473 since that
is the size of my stunnel.log after an original startup. I also just
used 50000 as a limit size for no real reason.

if [ `ls -l /var/log/stunnel.log | awk '{print $5}'` -gt 50000 ] ; then
truncate -c -s 473 /var/log/stunnel.log
fi

Don't know if you current setup has awk or truncate, so it might
also add a little size. Probable other ways to get the file size, and
you could then run it with cron, or add a sleep option, and have it
call itself.






>
>
> 2013/7/18 Michal Trojnara <Michal....@mirt.net>
> mehmet ozisik wrote:
> I mean for linux also stunnels self log rotation.
>
>
> Could you please inform me?
>
> Try:
> https://www.google.com/search?q=linux+log+file+rotation
>
>
> Mike
> _______________________________________________
> stunnel-users mailing list
> stunne...@stunnel.org
> https://www.stunnel.org/cgi-bin/mailman/listinfo/stunnel-users
>


+----------------------------------------------------------+
Michael D. Setzer II - Computer Science Instructor
Guam Community College Computer Center
mailto:mi...@kuentos.guam.net
mailto:mset...@gmail.com
http://www.guam.net/home/mikes
Guam - Where America's Day Begins
G4L Disk Imaging Project maintainer
http://sourceforge.net/projects/g4l/
+----------------------------------------------------------+

http://setiathome.berkeley.edu (Original)
Number of Seti Units Returned: 19,471
Processing time: 32 years, 290 days, 12 hours, 58 minutes
(Total Hours: 287,489)

BOINC@HOME CREDITS
SETI 15449173.944312 | EINSTEIN 12398299.479852
ROSETTA 7976197.637931 | ABC 16155563.883398
0 new messages