When was the Old Testament Canon defined?
I wonder if it was defined in the days when Jesus was crucified
Not at the time of Jesus. At that time the definition of the Hebrew Scriptures was uncertain. Or perhaps a better way to see it is as the Jewish Encyclopedia suggests: Since all Jewish literature of the time was religious, it was more a question of which writings were not holy enough to be called scripture. The Bible as a book did not exist yet. There were many holy books, usually in the form of scrolls that might contain one long scripture, such as Isaiah, or several short ones, such as the Minor Prophets. There were also many more recent writings, which ultimately did not become "scripture."
A question of emphasis
The Sadducees apparently emphasized mainly the Torah (the first five books), while the Pharisees accepted a broader collection. This is one of the reasons the NT describes them as disagreeing about the doctrine of the afterlife/resurrection (Acts 23:8), since this teaching is not found in the Torah itself but in later writings such as the Prophets and Job.
The Talmud relates that, in answer to the question of a Sadducee concerning the Biblical basis for the belief that God causes the dead to rise, the patriarch Gamaliel [a Pharisee] sought proof "in Torah, Prophets, and Holy Writings" (Sanh. 90b). Furthermore, the Jewish Encyclopedia article on Resurrection states:
The Sadducees denied the resurrection (Josephus, "Ant." xviii. 1, § 4; idem, "B. J." ii. 8, § 14; Acts xxiii. 8; Sanh. 90b; Ab. R. N. v.). All the more emphatically did the Pharisees enunciate in the liturgy (Shemoneh 'Esreh, 2d benediction; Ber. v. 2) their belief in resurrection as one of their fundamental convictions (Sanh. x. 1; comp. Abot iv. 22; Soṭah ix. 15).
Greek vs. Hebrew versions
In addition to disputes about which texts were more authoritative, the Greek version of the Jewish Scriptures (the Septuagint), included works that were eventually excluded from the standard Jewish collection today. It was read especially by Jews living in the Greek world outside of Judea and the Galilee, and was also the preferred version of early Christian writers. This collection is included as part of the OT and Apocrypha in Catholic Bibles, but not in most Protestant editions.
The putative Council of Jamnia in the late first century has often been cited as the moment of the formalization of the Hebrew Canon. However, this is only a theory. What we may be certain of is that Hebrew Bible was not canonized in the time of Jesus. Indeed it seems to have been formalized in part because Christians used the broader Greek collection of Jewish scriptures, some of which the Rabbis did not accept. The Septuagint, however, is very ancient, being compiled by Egyptian Jews in the 2nd-3rd c. BCE. The Masoretic text, which contains the currently accepted 24 books of the Hebrew Bible, was compiled between the 7th and 10th centuries of the Common Era.
The scriptures that Jesus would have known would have been either in Hebrew or Aramaic/Syriac. However, they would not be in the form of a single codex or book. Synagogues would have a collection of scrolls for public reading and guided study. Local synagogues may not have been able to afford a complete collection. The process of canonization was gradual. The current Hebrew Bible did not reach its final form until the Middle Ages.