Salvador (Bahia), 1849 - Petrópolis, 1923