# How to initialize global variable on standby unit

**URL:** <https://community.f5.com/t/how-to-initialize-global-variable-on-standby-unit/9404>\
**Category:** Technical Forums\
**Tags:** irules, dev, devops, application-delivery\
**Created:** [May 3, 2010, 10:02am UTC](https://community.f5.com/t/how-to-initialize-global-variable-on-standby-unit/9404 "2010-05-03T10:02:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Robert\_Reznicek](https://avatars.discourse-cdn.com/v4/letter/r/a6a055/32.png) [@Robert\_Reznicek](https://community.f5.com/u/Robert_Reznicek)\
**Post date:** [May 3, 2010, 10:02am UTC](https://community.f5.com/t/how-to-initialize-global-variable-on-standby-unit/9404/1 "2010-05-03T10:02:08Z")

</div>

Hi there,

I have some global variable initialized within a RULE\_INIT event. This variable is visible on active unit, however when I make a standby unit active, this variable is not visible. Is it possible to propagate this variable to the standby unit somehow please?

Thanks a lot!

---

<div class="post-metadata">

**Author:** ![JRahm](https://d1p9zq3aats0t8.cloudfront.net/user_avatar/community.f5.com/jrahm/32/3327_2.png) [@JRahm](https://community.f5.com/u/JRahm)\
**Post date:** [May 3, 2010, 4:50pm UTC](https://community.f5.com/t/how-to-initialize-global-variable-on-standby-unit/9404/2 "2010-05-03T16:50:05Z")

</div>

variables are not synced to standby systems. However, if you use the session command (or table if on v10.1+) that data is mirrored, and so you should be set.

---

<div class="post-metadata">

**Author:** ![hoolio](https://avatars.discourse-cdn.com/v4/letter/h/f6c823/32.png) [@hoolio](https://community.f5.com/u/hoolio)\
**Post date:** [May 4, 2010, 9:16pm UTC](https://community.f5.com/t/how-to-initialize-global-variable-on-standby-unit/9404/3 "2010-05-04T21:16:57Z")

</div>

I tested using the session table for a globally accessible variable in v10.0.x. But I didn’t think to test this for mirroring. Maybe it would work for you?

[http://devcentral.f5.com/wiki/default.aspx/iRules/CMP\_v10\_compatible\_counters\_using\_the\_session\_table.html](http://devcentral.f5.com/wiki/default.aspx/iRules/CMP%5C_v10%5C_compatible%5C_counters%5C_using%5C_the%5C_session%5C_table.html)

If you try it, could you reply back?

Thanks, Aaron
