The Legend of Zelda: Ocarina of Time 3D Tips

Safe Way To Defeat Morpha
First of all jump to the walkway with all the spikes. Run to a corner and stand as far back as you can with you back against the wall. It won't be able to get you at all.

The boss will start out with the core going up into the tentacle when it tries to get you. Grab it with your longshot and attack it with your sword, but don't chase after it as you might get thrown across the room.

Then the core will start to move around the tentacle in a circle. Z-target it with your longshot. When it is on its way up shoot your longshot, which should connect as its on its way back down. If you miss be patient and try again or try without targeting.