Authentication Failed for CLI commands

I am having authentication issues for stardog-admin commands on the server. Our server uses a shell script to start. I followed the steps on this related support ticket Authentication failed - Changing admin password - #7 by stephen in an attempt to set a password file for all stardog-admin commands. The relevant pieces of the shell script are included below:

export STARDOG_JAVA_ARGS="-... -Dstardog.passwd.file=/path/to/.sdpass"
cd /stardog/stardog-7.8.2/
./bin/stardog-admin server start --enable-ssl

I am still running into 'Authentication Failed' errors when running stardog-admin commands. The sdpass file does not seem to be recognized. Any thoughts?

Hi,

It all depends on how you're running the stardog-admin commands, but your issues could stem from one of the following:

  • Your password file doesn't have an entry with localhost as the host and 5820 as the port, which is the default used by stardog-admin when no other server is specified
  • You have another password file at ~/.sdpass, the existence of which causes Stardog to ignore the one specified in the java args

Hi Stephen, thank you for the quick response. To the first point: the password file content was set up as follows: *:*:*:admin:secret. This would cover the localhost entry with 5820 as the port or am I mistaken in that thought?

To the second point: when you mention password file at ~/.sdpass do you mean the top most directory of the server (using Linux) or another location?

Hi Nick,

~ specifies the home directory of the user running the command, wherever that may be. Linux would normally have it at /home/myUser, osx at /Users/myUser, etc.

As for your password file content, yes that would cover localhost:5820 just fine