CiviCRM upgrade from 4.6 to 5.3 > [warning] Both parameters should have an equal number of elements Relationship.php:2222
This error is displayed when some Names for a relationship type do not match the Labels.

For example in civicrm_relationship_type table you may have something like

name_a_b = Mayor
name_b_a = Mayor
label_a_b = Mayor of
label_b_a = Mayor is

You can correct these either in SQL or via the UI



UPDATE

To identify the rows causing the issue 

select name_a_b, label_a_b, name_b_a, label_b_a from civicrm_relationship_type where name_a_b &lt;&gt; label_a_b;
select name_b_a, label_b_a from civicrm_relationship_type where name_b_a &lt;&gt; label_b_a;


To fix we want to set the name = to the label

Make a temporary backup - this will be dropped when you log out of mysql.

create temporary table temp_civicrm_relationship_type as select * from civicrm_relationship_type;
update civicrm_relationship_type set name_b_a = label_b_a where name_b_a &lt;&gt; label_b_a;
update civicrm_relationship_type set name_a_b = label_a_b where name_a_b &lt;&gt; label_a_b;


Confirm that the number of rows updated matches result of the query.

(nb I just grabbed this from a ticket in our own system but hope it is helpful in your case)