The inner core is mostly iron with some other elements mixed in, similar to the outer core, but because the pressure is so much higher near the center of the Earth, the inner core is solidish. As with the outer core, the inner core is made of mostly iron with some other stuff mixed in. We can't drill all the way through the Earth and take samples of the material and determine the structure. The deepest drill hole that I'm aware of is about 12 km deep, which doesn't even make it past the bottom of the crust. Certain volcanic eruptions can bring up material from deeper, but still less than 1000 km deep.
Seismology is the study of earthquakes.
When earthquakes happen, the ground shakes and seismic waves travel outward from the earthquake. If the earthquake is big enough, then the seismic waves can be detected all the way on the other side of the earth. Knowing when and where the earthquake hit, and when and where we record the seismic waves, we can figure out how fast the waves traveled through the Earth. In some sense, it's like taking an X-ray or MRI of Earth. We can also use Earth's gravity to find out more about Earth's internals.