3 Clarified a sentence.
source | link

According to the details you explain about your network topology, my understanding is:

  • Cisco switch is root of the spanning-tree.
  • Port A4 in switch HP 7 is root port and therefore it is in forwarding state
  • Port B1 in switch HP 8 is root port and therefore it is also in forwarding state

Now let´s focus in the other link closing the loop, the one between both HP switches. You can have only a designated port and because the cost to root advertised by both HP switches into the link is the same, switches would have to check the lowest sender bridge ID and lowest sender port ID in order to agree which ischoose the designated port and the blocking port. Setting

So, setting a different costcosts for ports in the link between HP switches will have no effect in choosing the designated port in thefor this link.  

According to the details you explain about your network topology, my understanding is:

  • Cisco switch is root of the spanning-tree.
  • Port A4 in switch HP 7 is root port and therefore it is in forwarding state
  • Port B1 in switch HP 8 is root port and therefore it is also in forwarding state

Now let´s focus in the other link closing the loop, the one between both HP switches. You can have only a designated port and because the cost to root advertised by both HP switches into the link is the same, switches would have to check the lowest sender bridge ID and lowest sender port ID in order to agree which is the designated port and the blocking port. Setting a different cost will have no effect in choosing the designated port in the link.  

According to the details you explain about your network topology, my understanding is:

  • Cisco switch is root of the spanning-tree.
  • Port A4 in switch HP 7 is root port and therefore it is in forwarding state
  • Port B1 in switch HP 8 is root port and therefore it is also in forwarding state

Now let´s focus in the other link closing the loop, the one between both HP switches. You can have only a designated port and because the cost to root advertised by both HP switches into the link is the same, switches would have to check the lowest sender bridge ID and lowest sender port ID in order to choose the designated port and the blocking port.

So, setting a different costs for ports in the link between HP switches will have no effect in choosing the designated port for this link.

2 Fixed answer, as my first answer was wrong.
source | link

According to the details you explain about your network topology, my understanding is:

  • Cisco switch is root of the spanning-tree.
  • Port A4 in switch HP 7 is root port and therefore it is in forwarding state
  • Port B1 in switch HP 8 is root port and therefore it is also in forwarding state

Now let´s focus in the other link closing the loop, the one between both HP switches. You can have only a designated port in this link. By forcing a higherand because the cost in port A1 switchto root advertised by both HP 8 you make sure this isswitches into the port that will be in blocking state in this link. This is the most direct way to force the port to stay as backup.

Otherwise, if costs in both ports connecting HP switches would matchsame, the switches would have to check the lowest sender bridge ID and lowest sender port ID in order to agree which is the designated port and the blocking port.

So, it makes sense toSetting a different cost will have no matching costs for both ports no effect in choosing the designated port in the same link. 

According to the details you explain about your network topology, my understanding is:

  • Cisco switch is root of the spanning-tree.
  • Port A4 in switch HP 7 is root port and therefore it is in forwarding state
  • Port B1 in switch HP 8 is root port and therefore it is also in forwarding state

Now let´s focus in the other link closing the loop, the one between both HP switches. You can have only a designated port in this link. By forcing a higher cost in port A1 switch HP 8 you make sure this is the port that will be in blocking state in this link. This is the most direct way to force the port to stay as backup.

Otherwise, if costs in both ports connecting HP switches would match, the switches would have to check the lowest sender bridge ID and lowest sender port ID in order to agree which is the designated port and the blocking port.

So, it makes sense to have no matching costs for both ports in the same link.

According to the details you explain about your network topology, my understanding is:

  • Cisco switch is root of the spanning-tree.
  • Port A4 in switch HP 7 is root port and therefore it is in forwarding state
  • Port B1 in switch HP 8 is root port and therefore it is also in forwarding state

Now let´s focus in the other link closing the loop, the one between both HP switches. You can have only a designated port and because the cost to root advertised by both HP switches into the link is the same, switches would have to check the lowest sender bridge ID and lowest sender port ID in order to agree which is the designated port and the blocking port. Setting a different cost will have no effect in choosing the designated port in the link. 

1
source | link

According to the details you explain about your network topology, my understanding is:

  • Cisco switch is root of the spanning-tree.
  • Port A4 in switch HP 7 is root port and therefore it is in forwarding state
  • Port B1 in switch HP 8 is root port and therefore it is also in forwarding state

Now let´s focus in the other link closing the loop, the one between both HP switches. You can have only a designated port in this link. By forcing a higher cost in port A1 switch HP 8 you make sure this is the port that will be in blocking state in this link. This is the most direct way to force the port to stay as backup.

Otherwise, if costs in both ports connecting HP switches would match, the switches would have to check the lowest sender bridge ID and lowest sender port ID in order to agree which is the designated port and the blocking port.

So, it makes sense to have no matching costs for both ports in the same link.