The Master Sword, Link's trusty weapon, though powerful, can get even stronger through the course of the game by collecting four pieces of Master Ore. Each upgrade will cost two Master Ores.
These precious items can be found in Large Chests located in various dungeons around Lorule. This is where you get them.
This piece of Ore can only be obtained after Link has freed the captured Thief Girl from her prison. When in the room filled with water, the southwest corner of the room houses two switches which will open the wall nearby. Enter the new area and open the chest to reveal another Master Ore.
Lorule Cemetary Dungeon
When in the Cemetary, you'll gain access to the dungeon by using the Titan Glove to uncover a hidden set of stairs in the right corner. This is one of the easier pieces to acquire since it only requires you to get through the dungeon, which will reward Link with a Large Chest containing the Master Ore.
Skull Woods Dungeon
The Master Ore can be found near the end of the dungeon which has Link getting the eyeballs. Near the south part of the room, there will be an eyeball located on a high ledge. Just above this eyeball is a chest containing the Master Ore. Merge along the wall and obtain your prize.
Palace of Darkness
On the second floor, north of the room with a lot of windows will be a smaller room with a treasure chest. You'll notice two switches that operate both the wall and platforms. The key is to place a bomb next to the switch that opens the wall. Have link step on the platform and activate the switch to move the platform. The bomb you placed by the other switch should explode after you moved on the platform, exposing the hidden room that houses the chest with the last remaining Master Ore.