11-09-2017
02:34 AM
- last edited on
03-14-2019
02:18 PM
by
NIadmin
Hello,
I have two cRIO-9030 connected in two different subnets. They are connected with a mobile network via openVPN.
When I open the web server, it manages to find both controllers but when I press "Add Selected" it just says on the status bar "Adding system" and it stays there.
I have tried to add them manually and I get the same problem.
There are no fail messages or anything, just waiting...
Any suggestions on how to troubleshoot this?
Solved! Go to Solution.
11-09-2017 07:55 AM - edited 11-09-2017 07:57 AM
When you try to add a target we are trying to connect to the target via SSH, but it is possible something is blocking the connection.
You can try to download Putty (http://www.putty.org/) an SSH client for Windows and see if you can figure out what is blocking SSH (port 22).
The other option would be to SSH into the target from some other local system or just use the console and modify the /etc/salt/minion.d/master.conf file by hand on the target. It should contain the following.
master: <hostname or IP address of your server>
Then just reboot your target and it should show up as a Pending Approval system in SystemLink. Once approved it will show up under Managed Systems.
Note we are working on improving our error handling in the next release to timeout or return an error in these cases where it is blocked. We are also looking to make it easier to manually set the master for a target from MAX.
11-10-2017 01:58 AM - edited 11-10-2017 03:24 AM
How do I check if something is blocking the SSH port? I do not really know what to look for here.
I am able to connect to the controller with Putty using port 22 via openVPN.(Does this mean nothing is blocking the SSH port?)
But when I tried accessing the /etc/salt/minion.d/master.conf file but I keep getting the message: "-bash: /etc/salt/minion.d/master.conf: Permission denied".
I am logged as the admin so i do not understand why it is not granting me permission.
How can I get the permission?
Edit 1:
I tried accessing the file via System configuration (NI web based configuration & monitoring) and it allowed me to view and edit the file. It looks like the file contains all the IP of interest.
This is the exact sequence of events:
-Click "add by address" button
-Write IP of controller
- Window that says "Requesting"
-Window that says "Add System" and I am asked to write the username and the password for the controller
-Window that says "Requesting"
-Window with hostname, IP address, model name, serial number, master and comments of the controller.
-Press Add.
-On status it says "Adding System" and it stays there.
If I go back to the dashboard there are 0 managed systems,0 active jobs, 0 discovered systems and 0 pending approvals.
PS: Could this have anything to do with how the web server is setup?
I have chosen the "Disable HTTPS (insecure)" for now. I am not sure how to setup a certificate yet.
11-10-2017 07:03 AM - edited 11-10-2017 08:44 AM
Sounds like SSH is working fine and not blocked, which is great. That means the server can contact the target. Next, we need to determine if the target can contact the server.
Is your server running on a virtual or physical machine? If a VM make sure you have the network settings configured for Bridge mode (not NAT).
Another thing you you can try is from the targets console via Putty try pinging the various IP addresses listed in the master conf. If they don’t work you can remove them. If none of them work you probably have something blocking incoming traffic to your server. We open the ports in the Windows firewall at install time, but you could have a physical firewall blocking incoming traffic.
11-29-2017 07:56 AM
It seems it was the windows firewall that was blocking something.
I have disabled it and now I can see the three units I have online.
I still cannot access the master.conf though...
"admin@Halo-000010:~# /etc/salt/minion.d/master.conf
-bash: /etc/salt/minion.d/master.conf: Permission denied"
11-30-2017 08:11 AM - edited 11-30-2017 08:14 AM
Did you log into the target using the "admin" user?
Also, the file itself isn't executable, so you will have to use some utility like "more" or "vi" to view and edit it. To view the master.conf you can do something simple like the following to view it.
more /etc/salt/minion.d/master.conf
To edit the file, I would suggest learning how to use vi.
vi /etc/salt/minion.d/master.conf
11-30-2017 08:34 AM
Thank you!
It was My lack of experience with linux that did not allow me to access the file.
It worked by using "more" or "vi"