Terminal Troubleshooting

Some tips in case you are having trouble using the Terminal feature in JFrog Connect.

If the JFrog Connect's Terminal feature is not working with your devices, you can try the tips below.

  1. Ensure that the root user exists and is enabled. If it is locked, enable it as follows:

    • Set root password sudo passwd root

    • Activate root user sudo passwd -u root

  2. Ensure that openssh-server is installed, or install it by running apt-get -y install openssh-server

  3. Ensure that network port 443 is OPEN in the device firewall or on the router (OUTPUT table) when opening a remote control session.

  4. Ensure that you have a valid DNS record. You can add a DNS record by running the command: echo "nameserver 8.8.8.8" >> /etc/resolv.conf

  5. If the device firewall is in DROP mode, run the following commands to enable the Connect Agent,I using iptables:

    • iptables -I INPUT 1 -i lo -j ACCEPT

    • iptables -A INPUT -s 127.0.0.1 -p tcp --sport 442 -j ACCEPT

    • iptables -A INPUT -s 127.0.0.1 -p tcp --dport 442 -j ACCEPT

    • iptables -A OUTPUT -s 127.0.0.1 -p tcp --sport 442 -j ACCEPT

    • iptables -A OUTPUT -s 127.0.0.1 -p tcp --dport 442 -j ACCEPT

    • iptables -A OUTPUT -p tcp -d api.connect.jfrog.io --dport 443 -j ACCEPT

    • iptables -A OUTPUT -p tcp -d remote.connect.jfrog.io --dport 443 -j ACCEPT

    • iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT

If the Terminal is not working and you do not have other access to the device's terminal, you can run the script below using the Micro-update tool. This will set and enable the root user. Complete the steps below the script.

#!/bin/sh

username="root"
password="ENTER_SOME_PASSWORD"

passwd ${username} << EOD
${password}
${password}
EOD

sudo passwd -u root

To run the script:

  1. Create a new Micro update and choose the relevant device.

  2. Enter a version number. You can enter anything here.

  3. In the section Before Update, upload the bash script above.

    1. Save the script with .sh extension (for example: enable_user.sh).

    2. Change ENTER_SOME_PASSWORD to a password you will remember.

  4. To deploy the micro-update on the device, click Deploy.

Once deployed, the root user will be set and enabled. You can now try to open Terminal on that device.

If none of the tips above solves the issue, check your device and Internet connection stability.

CentOS/Red Hat - SELinux Permission Issue

If you are having this issue, complete the steps in the Device Registration page.

Last updated

Was this helpful?