Update for stardog-server startup script

1 view
Skip to first unread message

Slava Kravchenko

unread,
Apr 29, 2016, 5:54:25 AM4/29/16
to Stardog
Hello!

Thought I'd share my small adjustment to "startdog-server" startup script. The issue I had with it was that it just wouldn't start "stardog-admin" part as "stardog" user.
The cause for that appeared to be the "homelessness" of "stardog" user - it wasn't created with its own home directory and everything else that this entails.

A couple of small adjustments to the startup script, which uses a dedicated "-s" option instead of specifying $BASH as a part of "-c" argument, fixes this:

start()
su $USERNAME - -c "$BASH ${STARDOG_BIN}/stardog-admin server start --home $STARDOG_HOME --port $PORT"
becomes:
su $USERNAME - -s $BASH -c "${STARDOG_BIN}/stardog-admin server start --home $STARDOG_HOME --port $PORT"

stop()
su $USERNAME - -c "$BASH ${STARDOG_BIN}/stardog-admin --server snarl://localhost:$PORT/ server stop"
becomes:
su $USERNAME - -s $BASH -c "${STARDOG_BIN}/stardog-admin --server snarl://localhost:$PORT/ server stop"

Additionally, I'd suggest replacing "localhost" with "127.0.0.1" since there are rare *NIX configurations that do not resolve "localhost" to the IP address.

Does that make sense?

Kendall Clark

unread,
May 2, 2016, 10:46:21 AM5/2/16
to Stardog
Slava,

Thanks for this. Someone here will take a look and see if we can include this in 4.1 release, which is upcoming.

Cheers,
Kendall

--
-- --
You received this message because you are subscribed to the C&P "Stardog" group.
To post to this group, send email to sta...@clarkparsia.com
To unsubscribe from this group, send email to
stardog+u...@clarkparsia.com
For more options, visit this group at
http://groups.google.com/a/clarkparsia.com/group/stardog?hl=en
Reply all
Reply to author
Forward
0 new messages