Preheat oven to 350°F (175°C). Grease and flour two 9-inch round baking pans.
In a large bowl, whisk together flour, sugar, baking powder, baking soda, and salt.
Add coconut and pecans to the dry ingredients and mix well.
In a separate bowl, whisk together buttermilk, oil, eggs, and vanilla extract.
Add the wet ingredients to the dry ingredients and mix until just combined.
Divide the batter evenly between the prepared pans.
Bake for 30-35 minutes, or until a wooden skewer inserted into the center comes out clean.
Let the cakes cool in the pans for 10 minutes before inverting them onto a wire rack to cool completely.
While the cakes are cooling, prepare the frosting: Beat cream cheese and butter together until smooth. Gradually add powdered sugar and vanilla extract, beating until light and fluffy.
Once the cakes are completely cool, frost the top of one layer with half of the frosting. Top with the second cake layer and frost the entire cake.
Notes
Store leftover cake in an airtight container in the refrigerator for up to 3 days.