Sonar(1) Sonar(1) NNAAMMEE sonar - display a sonar scope SSYYNNOOPPSSIISS ssoonnaarr [-background _c_o_l_o_r] [-sweep-color _c_o_l_o_r] [-low-color _c_o_l_o_r] [-scope-color _c_o_l_o_r] [-grid-color _c_o_l_o_r] [-text-color _c_o_l_o_r] [-ttl _i_n_t_e_g_e_r] [-mode ping] [-font _f_o_n_t] [-ping-timeout _i_n_t] [-ping-source list | file | sub- net ] [-ping-file _h_o_s_t_s_-_f_i_l_e] [-ping-list _h_o_s_t_-_n_a_m_e_-_l_i_s_t] [-team-a-name _s_t_r_i_n_g] [-team-b-name _s_t_r_i_n_g] [-team-a-count _i_n_t] [-team-b-count _i_n_t] DDEESSCCRRIIPPTTIIOONN The _s_o_n_a_r program displays a sonar scope on the computer's screen. This scope polls a sensor as the sweep goes around the scope and displays what it finds as bogies on the screen. The program is designed to support different modes representing different types of sensors. Currently the only implemented sensors are a simulator, and a net- work ping function that pings hosts and plots the results on the scope. OOPPTTIIOONNSS _s_o_n_a_r understands the following options: --bbaacckkggrroouunndd _C_o_l_o_r The background Color of the screen not covered by the scope. --sswweeeepp--ccoolloorr _C_o_l_o_r The color of the brightest part of the sweep. --ssccooppee--ccoolloorr _C_o_l_o_r The color of the circular part of the scope. --ggrriidd--ccoolloorr _C_o_l_o_r The color to the grid lines overlaying the scope. --tteexxtt--ccoolloorr _C_o_l_o_r The color of the text identifying bogies on the scope. --ttttll _i_n_t_e_g_e_r "Time to live": visible time of a Bogie. Try val- ues between 10 (very short) and 100. --mmooddee _s_i_m_u_l_a_t_i_o_n _| _p_i_n_g The sensor mode to use, the currently supported modes _s_i_m_u_l_a_t_e (the default) and _p_i_n_g. --ffoonntt _f_o_n_t The font used to display text on the scope. Default "fixed". X Version 11 3-Nov-98 1 Sonar(1) Sonar(1) --ppiinngg--ttiimmeeoouutt _i_n_t The amount of time in milliseconds the program will wait for an answer to a ping. --ppiinngg--ssoouurrccee lliisstt || ffiillee || ssuubbnneett Th source of the list of hosts to ping. Valid val- ues are: _l_i_s_t, _f_i_l_e, _s_u_b_n_e_t. The first two values are described below; and _s_u_b_n_e_t indicates that the sonar should ping all hosts in the same subnet as the current machine. (All addresses are treated as class C nets, therefore this will at most ping 254 hosts.) --ppiinngg--ffiillee _f_i_l_e_n_a_m_e The path to a file listing the hosts to ping. This file can be in the format used by _/_e_t_c_/_h_o_s_t_s, or it can be any file that has host names as the first element on each line. If you use ssh, try this: sonar -mode ping -ping-file $HOME/.ssh/known_hosts This is used only used when _p_i_n_g_S_o_u_r_c_e is set to ffiillee. --ppiinngg--lliisstt _l_i_s_t A comma separated list of hostnames, eg _"_p_i_n_k_y_,_b_r_a_i_n_,_d_o_t_". Only used when _p_i_n_g_S_o_u_r_c_e is set to lliisstt. --tteeaamm--aa--nnaammee _s_t_r_i_n_g The name of team A, in simulation-mode. --tteeaamm--bb--nnaammee _s_t_r_i_n_g The name of team B, in simulation-mode. --tteeaamm--aa--ccoouunntt _i_n_t The number of bogies on team A, in simulation- mode. --tteeaamm--bb--ccoouunntt _i_n_t The number of bogies on team B, in simulation- mode. RREESSOOUURRCCEESS Configuration of the targets to ping is best done by set- ting X Resources. bbaacckkggrroouunndd _(_C_o_l_o_r_) See option -background, above; default value is _b_l_a_c_k. X Version 11 3-Nov-98 2 Sonar(1) Sonar(1) sswweeeeppCCoolloorr _(_C_o_l_o_r_) See option -sweep-color, above; default value is _#_0_0_f_f_0_0. ssccooppeeCCoolloorr _(_C_o_l_o_r_) See option -scope-color, above; default value is _#_0_0_3_3_0_0. ggrriiddCCoolloorr _(_C_o_l_o_r_) See option -grid-color, above; default value is _#_0_0_a_a_0_0. tteexxttCCoolloorr _(_C_o_l_o_r_) See option -text-color, above; default value is _#_f_f_f_f_0_0. ttttll _(_i_n_t_e_g_e_r_) See option -ttl, above; default value is _9_0 or one sweep. mmooddee _(_p_i_n_g_) See option -mode, above. If set to ddeeffaauulltt, it will ping hosts if possible, otherwise, will run in simulation-mode. ffoonntt _(_f_o_n_t_) See option -font, above; default value is _f_i_x_e_d. ppiinnggTTiimmeeoouutt _(_I_n_t_e_g_e_r_) See option -pingtimeout, above; default value is 3000. ppiinnggSSoouurrccee _l_i_s_t _| _f_i_l_e _| _s_u_b_n_e_t See option -ping-source, above. Default value is _f_i_l_e. ppiinnggFFiillee _p_a_t_h_n_a_m_e See option -ping-file, above. Default value is _/_e_t_c_/_h_o_s_t_s. ppiinnggLLiisstt _h_o_s_t_,_h_o_s_t_,_h_o_s_t_._._. See option -ping-list, above; default value is llooccaallhhoosstt. tteeaammAANNaammee _s_t_r_i_n_g See option -team-a-name, above. Default value is FF1188. tteeaammBBNNaammee _s_t_r_i_n_g See option -teamBName, above. Default value is MMIIGG. tteeaammAACCoouunntt _i_n_t See option -teamACount, above. Default value is X Version 11 3-Nov-98 3 Sonar(1) Sonar(1) 4. tteeaammBBCCoouunntt _i_n_t See option -teamBCount, above. Default value is 4. NNOOTTEESS In order to use the ping sensor, this program must be installed as setuid root, so that it can create an ICMP socket. SSEEEE AALLSSOO XX(1), xxssccrreeeennssaavveerr(1), ppiinngg(8) CCOOPPYYRRIIGGHHTT Copyright (C) 1998 by Stephen Martin. (smartin@canada.com) Permission to use, copy, modify, distribute, and sell this software and its documentation for any purpose is hereby granted without fee, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation. No representations are made about the suitability of this software for any purpose. It is pro- vided "as is" without express or implied warranty. AAUUTTHHOORRSS Stephen Martin , 3-nov-98. Thanks to Tom Kelly for suggesting a modular approach to the sensor amoung other things. Thomas Bahls hacked the "ttl" option, 12-jul-98. X Version 11 3-Nov-98 4