Jesus was totally aware of the future, and he was also aware of all of the possibilities of people making differing decisions. In other words God will not interfere with our free will, and so the future depends heavily on all our decisions and each decision will set into motion a different course for the future.
Although Jesus was afraid of nothing, the plan of Salvation was based on all of those decisions happening in a specific order.
Matthew 26:18 KJV And he said, Go into the city to such a man, and say unto him, The Master saith, My time is at hand; I will keep the passover at thy house with my disciples.
Jesus had to follow the plan God had determined, and every step along that path was necessary to fulfill the prophesies of the Old Testament. As for instance the Scripture cited above, was necessary not only to show that he was diligently following a specific course, but that by knowing the specifics of the plan; he was of necessity, showing his disciples the proper reactions to God.
It need be noted here that this also led to his teaching them servitude by his washing their feet, an action normally assigned to the lowest of servants.
Jesus was afraid of no man but did fear not completely following the plans of God. Unless every facet of Jesus life were to take place exactly as planned some important part of the plan would be incomplete. Therefore, Jesus was warning them that there was a danger in not completing the plan completely.
John 7:8 KJV Go ye up unto this feast: I go not up yet unto this feast; for my time is not yet full come.
John 7:8 is indicative of just how critical the timing was in Jesus life since Jesus did go to Jerusalem, but not at the minute that the others did, so it was not going to the feast Jesus was avoiding, but the timing. Had Jesus gone with them it is possible that when he got to the Temple the Sanhedrin might have been there with their Temple guards and could even have prevented his display of anger at the commercialization of the Temple.
Were not every jot and tittle of his life in the exact timing of God's plan, we must wonder how it would have effected the plan of Salvation.
Jesus was born, lived, and died in total consonance with God's plan to save you and me.
In short the only thing Jesus feared was not being totally obedient to the Father, that is not to say that he desired all of the pain and suffering he encountered, but knew that every pain was necessary to Save us from our sin