When his son-in-law Konstanty Ostrogski was captured in the Battle of Vedrosha in July 1500, Olshanski became the Great Hetman (commander of the army) of the Grand Duchy of Lithuania. Grand Duke brokered alliances with the Livonian Order and Great Horde, but the Lithuanian army did not organize more active defense and Olshanski was replaced by Stanislovas Kęsgaila in 1501 or 1502.