Is there any difference between the two idioms, "one-to-one" and "one-on-one", when the meaning is 'between only two persons'? Can they be used interchangeably, for instance, in the following situations?

1. The pastor had a one-to-one session with the family discussing its problems.

2. The lecturer preferred the one-on-one meetings with his students.

3. The father had a frank one-to-one discussion with his children.

4. Do not miss the chance to meet the President one-on-one.

5. The monk mentioned this during his one-to-one class with his disciples.
In all five sentences it should be "one-on-one." "One-on-one" is used for this kind of intimate, person to person meeting.

"One-to-one" is used in more abstract situations, as in: "There is a one-to-one correspondence between the independent variable and the dependent variable in a mathematical function."

There is no difference. Feel free to use either of them.