The best way to relieve tooth pain is to combine two painkillers. The usual advice is to combine a non-steriodal anti-inflammatory drug (NSAID) such as Ibuprofen and to combine this with a simple pain killer such as Paracetamol (Acetemenophen). For an adult, take 400mg of Ibuprofen and 1000mg of Paracetamol and repeat every 8 hours. Take no more than 1200mg of Ibuprofen and no more than 4000mg of Paracetamol in any 24 hour period.
Many people are not aware that they can take both an NSAID and Paracetamol at the same can, but you can do so safely.
It is important to also see a dentist as the teeth may need to be removed.