Storing Subscriber and Service Session Data
To aid in recovering from an SAE failover, the SAE stores subscriber and service session data. In releases earlier than SDX Release 6.2, the software stored subscriber and session data on the router. The SAE now stores session data in flat files on the SAE host. The SRC component that controls the storage of session data on the SAE is called the session store. The session store queues data and then writes the data to session store files on the SAE host's disk. Once the data is written to disk, it can survive a server reboot.
You can configure how the SAE stores session data for JUNOSe routers, JUNOS routing platforms, simulated routers, and PacketCable Multimedia Specification (PCMM) devices.
Session Store Files
Session store files are numbered flat files. When the SAE starts, the session store component creates a directory on the SAE host. Session store files are located in the directory. You can configure the size of session store files. Once the maximum size is reached, the session store creates a new file and begins writing data to the new file.
Store operations, such as adding a session to the store (put store operations) or removing a session from the store (remove store operations), are queued in a buffer before they are written to the session store file. You can configure parameters that determine when the session store writes a queue to a session store file.
Session store files are deleted if they have not been modified and if no session activity has taken place for one week. All of the data files that contain the sessions associated with a particular virtual router are deleted at the same time.
Active and Passive Session Stores
You can have a community of SAEs and duplicate session store data on each SAE in the community in case of an SAE failover. SAE communities are made up of SAEs that you configure as connected SAEs for a virtual router object.You can configure SAE communities with SDX Admin by selecting the SAE Connection tab in the VirtualRouter pane.
SAEs in a community are given the role of either active SAE or passive SAE. The active SAE keeps session data up to date within the community. Each active session store opens a Transmission Control Protocol (TCP) connection to its passive SAE. The TCP connection triggers the creation of a passive session store in that SAE. When the active session store writes operations to the session store file, it passes them to passive sessions stores on all SAEs in the community.
When you modify a community, wait for passive session stores on the new community members to be updated before you shut down the currently active SAE. Otherwise, if you add a new member to a community, and then a failover from the current active SAE to the new member is triggered immediately, the new member's session store may not have received all data from the active SAE's session store.
Session Store File Rotation
The session store periodically rotates the session store files. During rotation, the session store copies put store operations for live sessions from the oldest file to the end of the newest file. (Live sessions are sessions that have been created but not yet deleted.) It then deletes the oldest file. Sessions are rotated in batches, and you can configure the number of sessions that are rotated at the same time, and how much disk space is used by live sessions before files are rotated. No session store activity can take place while a batch of sessions is rotated.