Try removing the port number at the end if you are using Splunk Cloud. This was the issue in my case. The documentation does not reflect this issue as of this writing.
... View more
Try using single quotes for each parameter. This is how I fixed my error. Example: >./splunk add monitor /var/log -index 'main' -sourcetype 'linux'
... View more