# Colocation with one-way failover dependency

**URL:** <https://forums.suse.com/t/colocation-with-one-way-failover-dependency/35144>\
**Category:** SLES High Availability Extension\
**Created:** [July 14, 2020, 5:03pm UTC](https://forums.suse.com/t/colocation-with-one-way-failover-dependency/35144 "2020-07-14T17:03:16Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![PRIYANKA](https://avatars.discourse-cdn.com/v4/letter/p/919ad9/32.png) [@PRIYANKA](https://forums.suse.com/u/PRIYANKA)\
**Post date:** [July 14, 2020, 5:03pm UTC](https://forums.suse.com/t/colocation-with-one-way-failover-dependency/35144/1 "2020-07-14T17:03:16Z")

</div>

Hi Folks!  
I have a query related to SLES HA crm constraints.  
I have a use case where there needs to be a colocation constraint between two resources (let’s say A and B )  
The restrictions are that

- B should be colocated w.r.t A
- Failure/Failover in A should cause failover in B
- Failure of B should not impact A  
Can anyone please help me regarding this query.  
Thanks Ahead!

---

<div class="post-metadata">

**Author:** ![strahil](https://avatars.discourse-cdn.com/v4/letter/s/b5ac83/32.png) [@strahil](https://forums.suse.com/u/strahil)\
**Post date:** [July 16, 2020, 5:15am UTC](https://forums.suse.com/t/colocation-with-one-way-failover-dependency/35144/2 "2020-07-16T05:15:47Z")

</div>

I think that you can do it with a simple colocation rule. This will lead that in case of A fails over, B will be moved always. Keep in mind that the colocation rule won’t guarantee if you need B to start after A.  
`crm configure colocation always-B-with-A inf: B A`

---

<div class="post-metadata">

**Author:** ![strahil](https://avatars.discourse-cdn.com/v4/letter/s/b5ac83/32.png) [@strahil](https://forums.suse.com/u/strahil)\
**Post date:** [July 16, 2020, 5:28am UTC](https://forums.suse.com/t/colocation-with-one-way-failover-dependency/35144/3 "2020-07-16T05:28:48Z")

</div>

When I think about it, if B fails you might have A affected. In such case , you can use `op monitor on-fail=ignore` for B resource only.

---

<div class="post-metadata">

**Author:** ![PRIYANKA](https://avatars.discourse-cdn.com/v4/letter/p/919ad9/32.png) [@PRIYANKA](https://forums.suse.com/u/PRIYANKA)\
**Post date:** [July 16, 2020, 6:25am UTC](https://forums.suse.com/t/colocation-with-one-way-failover-dependency/35144/4 "2020-07-16T06:25:21Z")

</div>

Sure, I did try ‘on-fail=ignore’ option. But the issue faced with that was , the status “ignored” got cleared after failure-timeout and the resource was showing as “Started”.  
Is there any other option which would keep the status consistent for the user to know always that the resource has actually failed without affecting resource A.

---

<div class="post-metadata">

**Author:** ![strahil](https://avatars.discourse-cdn.com/v4/letter/s/b5ac83/32.png) [@strahil](https://forums.suse.com/u/strahil)\
**Post date:** [July 19, 2020, 5:49am UTC](https://forums.suse.com/t/colocation-with-one-way-failover-dependency/35144/5 "2020-07-19T05:49:19Z")

</div>

It shouldn’t show ‘Started’ unless someone really starts it. Better open a bug report.
