---

** [tickets:#2247] Log stream file is not reserved during si-swap**

**Status:** unassigned
**Milestone:** 5.2.FC
**Created:** Wed Dec 28, 2016 10:50 AM UTC by Tai Dinh
**Last Updated:** Wed Dec 28, 2016 10:50 AM UTC
**Owner:** nobody


The fix for #2215 introduce a change in log_stream_open_fileinit(). i.e:
-  if (stream->numOpeners == 0) {
+  if ((stream->numOpeners == 0) || (*stream->p_fd == -1)) {

This will cause an unexpected behaviour during switchover, I guess.
The reason of it is because numOpeners will be checkpointed between the 
activate and the standby one meanwhile p_fd is node locally.
At starting up, both ACTIVE and STANDBY will have numOpeners and p_fd set to 0 
and -1 accordingly.
After that, ACTIVE open the stream, increase the numOpeners and sync this value 
to standby. Also p_fd on ACTIVE will be set to the opened file but this value 
is not checked point to standby.
During switchover, the p_fd of standby will always equal to -1, this cause the 
stream filename will always be changed.

This can be easily reproduce by
- create an application stream
- saflogger to write some messages to it 
- trigger an si-swap on OpenSAF SI.
- write another log to above application stream.
- Check that the stream filename has been rotated.

/Tai


---

Sent from sourceforge.net because [email protected] is 
subscribed to https://sourceforge.net/p/opensaf/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/opensaf/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Opensaf-tickets mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-tickets

Reply via email to