The whole story is mythical in nature and intention. Even finding similarities to actual events is seen as quite the fruitless endeavour.
The biggest problem with this question is that it asks for the historical validity of the Joseph-story in its biblical version.
But while the story is set in the second millennium BCE, it was first written down in the first millennium BCE (~400 BCE*). That is 1000 years after the events described are said to have been happened.
But the problems do not stop there.
The Bible was not set in stone, the Tora was not set in stone. But constantly written and re-written for a long time. We currently do not know exactly when the texts really solidified, but it was much later than the Babylonian exile.
That means that the current biblical text as published in books called "Bible" today is far removed from the text as it was written down first. Looking for any historical evidence in that book is hampered by later additions from the biblical editors. So much was added that the text as such is almost unreadable now.
Luckily, historical critical scholarship has attempted and is constantly attempting to unearth the original story, the urtext. The most crucial work in this field was presented in 1991 by Harald Schweizer.
While mainly in German the following book is continually updated and also contains an English translation of what his team now believes to be the original Joseph story.
Harald Schweizer: "Josephsgeschichte", Tübingen, 2. Oktober 2017. (online, large version, 3971 pages, 21MB, PDF!))
Compared to the current version in most books sold today, you might compare the start of the story from page 1970 in that fantastic Schweizer book (actul translation by Jo Van Vliet):
JOSEPH was as a guardian together with his brothers at the small livestock. He was just a small boy.
ISRAEL loved JOSEPH more than all his sons because a son of his old age he was to him.
He had therefore made him a coat of many colors.
JOSEPH once dreamed a dream, and he told his brothers, and said to them:
»Hear, I pray you, this dream which I dreamed!
We were binding sheaves in the middle of the field Suddenly stood up my sheaf, and even stayed upright.
And, there round about stood your sheaves, and bowed to my sheaf.
There his brothers said to him:
»You want to be a king someday, king of us?
Or reign, you want to reign over us?« And jealous of him were his brothers.
Whereas his father retained the incident.
JOSEPH’s brothers went to graze the small livestock of their father in SHECHEM.
And said ISRAEL to JOSEPH:
»Are not your brothers presently as shepherds in SHECHEM?
I want to send you to them.« He said to him:
»I am ready.« And he said to him:
Ascertain the well-being of your brothers and the well-being of the flocks, and bring me word again!« And he sent him out of the plain of HEBRON, and he reached SHECHEM.
Ran into him a man as he was wandering around the open field.
Also note the quite positive mental picture that emerges of "Egypt" from a Hebrew perspective. This is in the starkest and unexplained contrast to the following Exodus narrative where Egypt is a slave-driving hell on earth. The whole story is so generic in its corner points that actual historical hints are really not found at all.
That said, some kind of historical motive in the Joseph story might be found in the actual history of King Jeroboam who fled to Egypt and was treated well there. But while the book of Kings is somewhat on firmer historical grounds, that story is shrouded in mist as well and only ever so slightly better as a historical source. Going by the archaeological evidence, even that king never existed in any form near what is written down about him in our texts. But note how the traditional dating of Joseph clashes with Jeroboam –– or gives hints towards the improbable historicity of Joseph.
*: Or even later, for the original, first version, during firmly hellenistic times around 300BCE. A: Kunz: "Ägypten in der Perspektive Israels am Beispiel der Josephsgeschichte", BZ 47, 2003, 206–229.
And a seriously considered dating, albeit on the outer side of extreme, 100 BCE: B.J. Diebner: "Le roman de Joseph, ou Israël en Egypte. Un midrash post-exilique de la Tora", in: O. Abel & F. Smyth (Eds): "Le livre de traverse de l'exégèse biblique à l'anthropologie.", 1992, 55-71.
Konrad Schmid: "Die Josephsgeschichte im Pentateuch", in: J.C. Gertz & K. Schmid & M. Witte (Eds.): "Abschied vom Jahwisten" (BZAW 315), deGruyter: Berlin, New York, 2002, 83–118:
The Joseph narratives (Gen 37-50) are a testing ground for every hypothesis on the Yahwist as they serve as the transition from the book of Genesis to the book of Exodus in the final text of the Bible. It is clear that these narratives were not created for this purpose, but were rather modified for this purpose in the course of their literary history. The Joseph cycle seems to connect primarily to Gen 12-36. It was expanded later as a bridge to the events narrated in Exodus. The most recent discussion has raised the questions whether it ever existed independently of Gen 12-36, whether it ended originally in Gen 45, or whether the entire cycle must be dated after P. This study aims to show that it remains plausible to assume an independent, pre-priestly Joseph-narrative as contained in Gen *37-50. This original narrative was created as a critical response to Ex(ff.), especially to Sam, and connected to the book of Exodus after P.