Issue running remote command


(Revs) #1

Team,

I am trying to run simple remote ‘ls’ command and facing below issue. I think SSH keys for user is configured properly, updated the st2.conf file and restarted the service and still facing the issues. Could someone point me in right direction

and on another box a colleague(left organisation) configured this env and was able to run the ‘ls’ command but failing to do ‘scp’, what could be the issue here.

Also, what is the default password for postgressql when we use the below command
psql -U postgres

Appreciate all your help on this.

Thank you.


(W Chan) #2

Have you gone thru the section at Configure SSH to configure ssh on the remote system?


(Lindsay Hill) #3

Talk to whoever set your system up, or reset it using standard PostgreSQL procedures. There is a mistral user configured as part of the standard StackStorm install, but the installer does not change the postgres user password. That’s up to your local configuration.


(Revs) #4

Yes, gone through it and then raised this thread.


(Revs) #5

understood, I installed using the steps in the documentation and was able to configure mistral db by using a workaround. But not sure why I am unable to login directly using user ‘postgres’


(Lindsay Hill) #6

Yes, gone through it and then raised this thread.

Have you tried manually connecting via SSH using the right username and that key? That would be the first step to try.


(Lindsay Hill) #7

You’d have to look at your system configuration, and the PostgreSQL documentation. Most likely scenario is that there is no password set, and you’ll need to use sudo.


(Eugen C.) #8

For the second issue (screenshot), scp may fail while referring to /tmp/test.txt file, for which service might not have access due to systemd PrivateTmp setting.

Just place the file in any other directory location, outside of the /tmp and try again.


(Revs) #9

Thank you all for your inputs, I tried all your suggestions and still have the same original issues. Any other pointers would help. Also, is there any detailed logs to refer and get more understanding.

Appreciate all your help. Thanks.


(Lindsay Hill) #10

Start with the basics. Test that your SSH key is working. Do that by manually trying to SSH using that combination of username + SSH key to the remote host. Does that work?


(Revs) #11

Hi,

Agree, I was able to test ssh connectivity but failing to run the st2 commands

ssh connectivity result

st2 command result

Any pointers would be much helpful.

Thank you.


(Lindsay Hill) #12

Which key are you using for that manual test? The same key that ST2 is using? You’ve obfuscated too much, and I can’t tell what you’re doing.

Also: reading screenshots of text is hard. Just copy and paste the text to here, and change hostnames if you must.


(Revs) #13

Hi All,

This issue is resolved. For scp command we have to use core.local not core.remote as I pasted in the 1st screenshot.

Thanks everyone for your inputs.