mahmud also was already planning reforms borrowed from the west, and muhammad ali, who had had plenty of opportunity of observing the superiority of european methods of warfare, was determined to anticipate the sultan in the creation of a fleet and an army on european lines, partly as a measure of precaution, partly as an instrument for the realization of yet wider schemes of ambition. before the outbreak of the war of greek independence in 1821, he had already expended much time and energy in organizing a fleet and in training, under the supervision of french instructors, native officers and artificers; though it was not till 1829 that the opening of a dockyard and arsenal at alexandria enabled him to build and equip his own vessels. by 1823, moreover, he had succeeded in carrying out the reorganization of his army on european lines, the turbulent turkish and albanian elements being replaced by sudanese and "fellahin". the effectiveness of the new force was demonstrated in the suppression of an 1823 revolt of the albanians in cairo by six disciplined sudanese regiments; after which mehemet ali was no more troubled with military mutinies.