Being familiar with the three dimensions of colour can be helpful.
If you use several colours, they should ideally differ on several of those dimensions, not just one.
Value. The graph should remain readable even in black and white.
This simple rule should account for colour blindness, low-quality printers
and bad lighting conditions.
Even if you use different hues, make sure that the values are sufficiently different.
In particular, the plots should be dark on a light background (or the opposite),
but not grey on a grey value.
The worst example would be a blue plot of a red background -- both are middle values,
i.e., would give very similar greys after conversion in black and white.
Saturation should be used with moderation: a pure red line may be fine, but a thicker,
less saturated red line will be more readable
(the increased thickness helps distinguish colours and allows you to reduce saturation).
On the other hand, a pure red area is painful to look at: do not use saturated colours to fill areas.
The Brewer colour palettes
(designed for maps, not line plots) give examples of low-saturation colour choices.
The worst example would be, again, a saturated background (blue on red or red on blue).
As mentioned by @gung, avoid the red/green (traffic lights) combination:
there are much more colour-blind people than you think.
Especially with hue, less is more. For instance, to plot "diverging" values
(i.e., quantities that can be positive or negative), only use two hues
(for positive and negative values),
so that the reader can immediately distinguish what is high and what is low.
Using a discrete gradient can result in a much more readable plot:
the boundaries between the colours become visible and form a contour plot.
You may want to read S. Few's
Practical Rules for Using Color in Charts
or refer to any material about "Colour Theory" for art or design students.