Could you please tell me how to fix this license error step by step?
Error in 'litsearch' command: Your Splunk license expired or you have exceeded your license limit too many times. Renew your Splunk license by visiting www.splunk.com/store or calling 866.GET.SPLUNK.
there is no step by step guidance. You have to call Support in order to get a reset license, if you have a valid enterprise license.
When you receive the reset license you install it like any other license and you're ready to go again.
If your on a free license, you will hardly get a reset license. But you can follow this answer: http://answers.splunk.com/answers/66786/free-license-reset.html and check the comment made by @Drainy.
Hope that helps ...