Heat 2 teaspoons oil in a skillet; cook the eggs in the hot oil until set, 3 to 5 minutes. Cool and slice into thin ribbons; set aside.
Heat 2 more teaspoons oil in a large skillet; fry the garlic in the oil, mashing it while frying until light brown and almost crispy, about 5 minutes. Add the rice and mix thoroughly until it is well blended with the garlic. Add the soy sauce and mix again; cook for 2 minutes. Stir the ham into the mixture; cook and stir another 5 minutes. Fold the sliced egg into the mixture and cook until hot, about 3 minutes.