The word gerrymandering was created whenever Elbridge Gerry drew the district lines for the state of Massachusetts. Some people thought the districts looked like a salamander, so they combined the two: creating gerrymander.
Gerrymandering has been around for so long (since 1812), you would think that there would be a solution by now. However, it is very hard to measure a degree of gerrymandering. Some plausible solutions include just getting rid of districts all together (and taking the population's votes), using math to determine the districts (the shortest split line method), and having a bipartisan committee decide the borders.
Districts
So why do we have districts in the first place? Originally the U.S. was divided into districts to make it easier for information to travel. Since we didn't have the speed of the internet, all the votes had to travel by horseback, and it made it easier to get all the votes together if a few people on horses, rather than everybody moving their vote. Now, we have districts because (in some people's opinion), it is better to group like minded people in one division.