no, NFS by default does sync writes (at least unless you go to the effort of configuring async writes on NFSv3)

As far as I know, turning sync on would only matter if you are worried about having partial log messages on disk in the event of a crash.

enabing sync slows the output so that you will probably have fewer logs on disk than if you didn't do sync, but you won't have a partial log.

Unless you also change all your queues to disk-only queues (which is VERY slow compared to memory queues), you will still loose log messages in a crash, sync=on doesn't protect you from this

So, by itself, there is very little reason to use sync=on, but if you were doing full audit-grade logs (where you would rather have the system be unusable rather than miss a single log message, and are willing to sacrafice 99% of your performance to do so), sync=on is an indication that the system is configured wrong.

David Lang

On Tue, 6 May 2014, Dave Caplinger wrote:

Perhaps if you are writing to a file that happens to be remote via NFS? With async, the local filesystem buffer will report to rsyslog that it completed the write successfully, but after that point the write via NFS may fail, and now rsyslog will never know those messages never actually made it to disk on the remote box..?

--
Dave Caplinger, Director of Architecture | Ph: (402) 361-3063 | Solutionary — 
An NTT Group Security Company

On May 6, 2014, at 6:23 AM, Rainer Gerhards <[email protected]> wrote:

Sent from phone, thus brief.
Am 06.05.2014 11:36 schrieb "Thomas D." <[email protected]>:

Hi,

Rainer Gerhards wrote:
Besides, at least on a busy system, syncing is counter-productive. While
what is on the disk stays on the disk, the in-memory queue fills up more
rapidly. So in many use cases, activating sync potentially causes *more*
message loss.

[...]

Would you still recommend to enable syncing for important files like
"/var/log/auth.log" or not?

see above: definitely no

Interesting.

Just for my understanding: Could you describe a typical use case when
you would definitely want to set "Sync = on" for an action? Actual it
sounds like that there's never a reason...

I don't know one. Anyone else?

Rainer

Thanks!


-Thomas

_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad
of sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you
DON'T LIKE THAT.
_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of 
sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE 
THAT.

_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of 
sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE 
THAT.
_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of 
sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE 
THAT.

Reply via email to