This article explains how to find the username that was used to discover a device on a Junos Space platform.
Follow these steps to discover the username associated with a device. Junos Space uses the 'username' to connect to a device.
[root@space-005000000200 ~]# mysql -ujboss -p$(grep mysql.jboss /etc/sysconfig/JunosSpace/pwd | awk -F= '{print $2}') build_db -e "SELECT ld.name, dcm.adminname FROM LogicalDevice ld INNER JOIN DeviceConnectionManagement dcm ON ld.id=dcm.device_id_id;"
[root@space-005000000200 ~]#
mysql -ujboss -p$(grep mysql.jboss /etc/sysconfig/JunosSpace/pwd | awk -F= '{print $2}') build_db -e "SELECT ld.name, dcm.adminname FROM LogicalDevice ld INNER JOIN DeviceConnectionManagement dcm ON ld.id=dcm.device_id_id;"
Warning: Using a password on the command line interface can be insecure. +-----------------------+-----------+ | name | adminname | +-----------------------+-----------+ | DeviceHostname | root | +-----------------------+-----------+ In the example above, "root" user is used to discover the device where "DeviceHostname" is the name of the device shown in the DeviceManagement page within the Junos Space WebUI .
Warning: Using a password on the command line interface can be insecure. +-----------------------+-----------+ | name | adminname | +-----------------------+-----------+ | DeviceHostname | root | +-----------------------+-----------+
2019/02/07 - Changed the command which can be used for all Space version, also added for Public view.