Masters before Math PHD? I'm currently finishing up my last year of study as an undergraduate mathematics major at a top 2 public school.  I've been interested in getting a phD in mathematics for some time now, but my GPA and work in some classes in my 1st and 2nd years leaves a lot to be desired.   Let's just say I got pretty bad grades in important classes.  Since then, I've worked my but off and currently have around a 3.3 GPA.

Luckily, I was accepted into a Statistics/Computer Science related Masters program.  In this program, I will have the opportunity to take electives and plan to take some higher level math classes.  

My question is, will doing very well in my masters program next year override my poor performance as an undergrad? Also, should I be really trying to get a research position this summer?
Yes, high grades and excellent letters of recommendation from the master's program can help overcome poor grades from earlier. 

Remember you will apply for the PhD program a year in advance, so the professors you have the first two semesters in the master's program will be the ones you need to ask for letters. You need to be excellent from the start of the master's program. 

The other thing that can help overcome bad grades (to some extent) is a high score on the math subject GRE. You want to study thoroughly for that, unless you already have a high score. See e.g.  What is the median math GRE subject score for admission to a Group 2 or 3 PhD program in applied mathematics?