A Commentary, Critical, Practical, and Explanatory on the Old and New Testaments, by Robert Jamieson, A.R. Fausset and David Brown  at sacred-texts.com
jos 18:1THE TABERNACLE SET UP AT SHILOH. (Jos 18:1)
the whole congregation . . . assembled together at Shiloh--The main body of the Israelites had been diminished by the separation of the three tribes, Judah, Ephraim, and Manasseh into their respective allotments; and the country having been in a great measure subdued, the camp was removed to Shiloh (now Seilun). It was twenty or twenty-five miles north of Jerusalem, twelve north of Beth-el, and ten south of Shechem, and embosomed in a rugged and romantic glen. This sequestered spot in the heart of the country might have been recommended by the dictates of convenience. There the allotment of the territory could be most conveniently made, north, south, east, and west, to the different tribes. But "the tabernacle of the congregation was also set up there," and its removal therefore must have been made or sanctioned by divine intimation (Deu 12:11). It remained in Shiloh for more than three hundred years (Sa1 4:1-11).
jos 18:2THE REMAINDER OF THE LAND DESCRIBED. (Jos 18:2-9)
there remained . . . seven tribes, which had not yet received their inheritance--The selection of Shiloh for the seat of worship, together with the consequent removal of the camp thither, had necessarily interrupted the casting of lots, which was commenced by fixing localities for the tribes of Judah and Joseph. Various causes led to a long delay in resuming it. The satisfaction of the people with their change to so pleasant and fertile a district, their preference of a nomad life, a love of ease, and reluctance to renew the war, seem to have made them indifferent to the possession of a settled inheritance. But Joshua was too much alive to the duty laid on him by the Lord to let matters continue in that state; and accordingly, since a general conquest of the land had been made, he resolved to proceed immediately with the lot, believing that when each tribe should receive its inheritance, a new motive would arise to lead them to exert themselves in securing the full possession.
jos 18:3How long are ye slack to go to possess the land, which the Lord God of your fathers hath given you--This reproof conveys an impression that the seven tribes were dilatory to a criminal extent.
jos 18:4Give out from among you three men for each tribe--Though the lot determined the part of the country where each tribe was to be located, it could not determine the extent of territory which might be required; and the dissatisfaction of the children of Joseph with the alleged smallness of their possession gave reason to fear that complaints might arise from other quarters, unless precautions were taken to make a proper distribution of the land. For this purpose a commission was given to twenty-one persons--three chosen from each of the seven tribes which had not yet received their inheritance, to make an accurate survey of the country.
jos 18:9The men went and passed through the land, and described it by cities into seven parts in a book--dividing the land according to its value, and the worth of the cities which it contained, into seven equal portions. This was no light task to undertake. It required learning and intelligence which they or their instructors had, in all probability, brought with them out of Egypt. Accordingly, JOSEPHUS says that the survey was performed by men expert in geometry. And, in fact, the circumstantial account which is given of the boundaries of each tribe and its situation, well proves it to have been the work of no mean or incompetent hands.
jos 18:10DIVIDED BY LOT. (Jos 18:10)
Joshua cast lots for them in Shiloh before the Lord--before the tabernacle, where the divine presence was manifested, and which associated with the lot the idea of divine sanction.
jos 18:11the lot of . . . Benjamin came up--It has been supposed that there were two urns or vessels, from which the lots were drawn: one containing the names of the tribes, the other containing those of the seven portions; and that the two were drawn out simultaneously.
the coast of their lot came forth between the children of Judah and the children of Joseph--Thus the prophecy of Moses respecting the inheritance of Benjamin was remarkably accomplished. (See on Deu 33:12).