The above photo was taken at DeSoto Falls near Mentone, AL at sunrise. I shot this with a very small aperture, like mentioned. This one was at an aperture of F/22.
These are the short answers...Use a small aperture and this is much easier achieved at a wider angle.
This happens because of light "bending" around the aperture blades of your lens. This is where knowing your lens comes in super handy! How many "points" you obtain coming off of your sun star depends on how many aperture blades your lens has. If your lens has an odd number of aperture blades, like 7 or 9, your lens will double that and you should end up with a 14 or 18 point star. If your lens has an even number of aperture blades, like 6, then your lens will yield a star with the same number of points as you have aperture blades. So a lens with 6 aperture blades will give you a star with 6 main points on your star...there are chances that those "points" may be split, but there will still be 6 main points.
The image above was taken with my Tamron 24-70mm F/2.8 Di VC USD Lens, which has 9 aperture blades. If there was a full star there, and it wasn't partially blocked, you would see 18 points on that star. For the record, I enlarged the image and I was able to count about 13 that were unobstructed.
Thanks to depth of field, using a smaller aperture allows you to pick up much sharper, well defined points of the star, which is why F/16-F/22 is usually recommended.
If you want a full sun star, then you would not want the sun obstructed, or diffracted, by anything. However, these stars are typically much more interesting in compositions when the sun is diffracted by something like the horizon of the earth, a mountain, trees, etc.
Hearing that a small aperture creates a nice star burst, I would not suggest you try this at say, F/32. The main reason I wouldn't suggest that is most lenses aren't at their very sharpest point at that small of an aperture (remember that a large depth of field will mean everything is in focus, not that everything will be at it's sharpest). This, of course, is based on your lens. The more experience you have with a particular lens, the more you will learn things like its' sharpest aperture...that comes with field time.