Because Luke is going in for a strike strong enough to cut off Vader's hand
OK, so I've gone back to this scene a couple times. Things to note:
- Previous to this part, Vader destroys a bit of a catwalk Luke has jumped on. Considering this is Vader we are talking about, it is probably safe to assume he is using the power of the Force to give the strike the extra damage needed to bring down the catwalk.
- The rail is not hit once, but actually three times. Luke is advancing, Vader is stepping back and Luke's swings are aggressive. It doesn't seem like Luke is intentionally pulling any punches or that the lightsaber strikes are "glancing". They hit the rail, sparks fly, Luke keeps swinging. This shows the railing is sturdy stuff.
- For his last strike though, you can see Luke is really giving it his all. His arms are all the way back and his eyes are focused... on Vader's hand. Vader's right hand.
It is difficult to tell how much Luke knows about Vader's armor, but it is probably good to note here that the hand itself is nearly indestructible:
The Glove of Darth Vader was a Mandalorian Crushgaunt fitted around one of Lord Skere Kaan's indestructible Sith amulets. The gauntlet was worn by Lord Vader upon his right hand. Although both gloves for Darth Vader's armor contained micronized Mandalorian armor as a means to deflect direct hits from blaster bolts (a feature made redundant due to his Force abilities)
At the very least, Luke probably assumes that cutting off his dad's hand is not going to be as easy as making a one armed Ponda Baba - so he is really going for the kill on this strike, hence giving it the extra inertia/intent to cut through both Vader's armor and rail itself.
As for the question as to why the saber doesn't slice through the rail easily - there are various metals in the Star Wars universe (Mandalarion Iron is a good example) which are resistant. While that might seem convenient... if any room on the Death Star had some saber-proofing, it was probably this one.
tvtropes.org/pmwiki/pmwiki.php/Main/RailingKill