Joshua cast lots for them in Shiloh before Yahweh. There Joshua divided the land to the children of Israel according to their divisions.
TSK
TSK · Nehemiah 11:1
Treasury of Scripture Knowledge references in WEB.
These were heads of fathers' [houses] throughout their generations, chief men: these lived in Jerusalem.
Now the first inhabitants who lived in their possessions in their cities were Israel, the priests, the Levites, and the Nethinim.
Likewise at the same time said I to the people, "Let everyone with his servant lodge within Jerusalem, that in the night they may be a guard to us, and may labor in the day."
We cast lots, the priests, the Levites, and the people, for the wood offering, to bring it into the house of our God, according to our fathers' houses, at times appointed, year by year, to burn on the altar of Yahweh our God, as it is written in the law;
For there are set thrones for judgment, the thrones of David's house.
The lot is cast into the lap, but its every decision is from Yahweh.
Awake, awake, put on your strength, Zion; put on your beautiful garments, Jerusalem, the holy city: for henceforth there shall no more come into you the uncircumcised and the unclean.
and coming out of the tombs after his resurrection, they entered into the holy city and appeared to many.