Most astronomical positioning - e.g. positioning of spacecraft to "phone home" and to take photographs is done using the stars as reference points. Indeed with Rosetta - the main reason they couldn't fly low to make contact with Philae during perihelion was because if it flew through the denser comet material it's star tracker would get confused and it would go into a safe mode for a while.
The ISS uses GPS - military grade so that it can work above the atmosphere and while traveling at high velocity, see Does GPS work on the ISS?
On Apollo they used a method called Unified S-band - Ranging which let them track the spacecraft all the way to the Moon with a distance measurement accurate to 15 meters. It was similar to GPS in some ways.