I'm trying to use my Linux VM to ssh to a Drone (running Linux 16.4) and perform command roscore to start the Drone. The command is:
So I do, for example, ssh drone@192.168.1.1 'roscore', and I actually got:
ngocdp@ngocdp-VirtualBox:~$ ssh drone@192.168.1.1 'uptime;bash' drone@192.168.1.1's password: bash: roscore: command not found If I just run ssh on my Terminal ssh drone@192.168.1.1 and then manually run roscore, I can start it successfully:
ngocdp@ngocdp-VirtualBox:~$ ssh drone@192.168.1.1 drone@192.168.1.1's password: Welcome to Ubuntu 16.04.6 LTS (GNU/Linux 4.15.0-45-generic x86_64) * Documentation: * Management: * Support: 211 packages can be updated. 136 updates are security updates. Last login: Sun Jul 7 17:04:59 2019 from 192.168.1.100 drone@drone-Drone:~$ roscore WARNING: unable to configure logging. No log files will be generated Checking log directory for disk usage. This may take awhile. Press Ctrl-C to interrupt Done checking log file disk usage. Usage is <1GB. I would expect the command ssh drone@192.168.1.1 'roscore' would get into the root directory drone@drone-Drone:~$ first, then execute the command roscore.
When I try pwd, by ssh drone@192.168.1.1 'pwd', it give home\drone, which is the root directory. But I don't know why I cannot execute the command.