Grind the grated coconut, shallots, garlic and cumin seeds together.
Heat oil in a saucepan and splutter the mustard and fenugreek seeds. Then add the sliced shallots, curry leaves and dry chilies. When the shallots have turned transparent, add the coconut paste. Sauté the coconut paste for sometime. Switch off the stove and add the chili powder and mix it well.
Take another pan, add the slit green chilies and cook it along with the ginger slices in water, to which turmeric powder and salt is added. Boil it on a high flame and when the water mixture is reduced to half the quantity, reduce the flame and add the buttermilk. Make sure that the mixture is not brought to a boil. Otherwise, the buttermilk could get curdled. Add the coconut paste and stir for a while. If the buttermilk is sour, you may add some sugar to it. Take it off the stove and serve it with steamed rice.