Comandi Moshell
Comandi Moshell
mom[tc] , enums and structs. lt/ltc[1-9] lc[1-9]/lcc pr/lpr Load MO tree (full or partial) and build proxy table. Load MO tree (full or partial) and build proxy table. Print MO LDNs and proxy ids for all or part of the MO tree Print description of MO classes, CM/FM attributes, actions
currently loaded in moshell. ma/lma mr/lmr Add MO(s) to an MO group. Remove an MO group or remove MOs from an MO group (MOs wil
l NOT be deleted, only the group). mp get/lget hget[c]/lhget[c] Print all defined MO groups. Read CM/FM attribute(s) from MO(s). Read CM/FM attribute(s) from MO(s), print horizontally one
line per MO (instead of one line per attribute). kget/lkget fro/lfro[m] Display CM/FM attributes in exportable printout format. Read MAO data of an MO and/or froid of the MO. Data read f
rom sql table modata_r2 instead of via MO service. st/lst te when applicable). prod lk/llk and opState). lko/llko MO classes. set[m]/lset[m] rset/lrset OFFLINE> bl[s]/lbl[s] deb/ldeb acl/lacl acc/lacc cr del/ldel rdel/lrdel u+[s]/u-/u?/u! Lock or soft-lock MO(s). Unlock MO(s). Lists available MO actions. Execute an MO action. Create an MO. Delete MO(s). Delete MO(s) together with children and reserving MOs. Handling of undo mode (for undo of del/rdel/set commands). Set an attribute value on one or several MO's. Set attribute value on a restricted attribute or change th The old lk. Messier than lk but supports a wider range of Print productData of MO(s). View all MO's linked to an MO, and their states (admState Print state of MOs (operationalState and administrativeSta
Can be used for generation of MO scripts as well. run trun[i] ctrl-z moshell session. pol[s] re[i] Poll the node until the CM service is up. Disconnect and reconnect to the CM service (mobrowser) and Run a command file in moshell format. Run a command file in EMAS/MoTester format. Abort an MO command or a "for" loop. Type "touch /tmp/;fg" to resume the
/or the PM service (pmtester). getmom parsemom flt/fltc ("Force" lt/ltc). ld fget/lfget get). sget/lsget Read CM/FM attributes from MO(s), one by one ("Slow" get). Load one MO from the tree and add to the proxy table. Read attributes that are not described in the MOM ("Force" Check the MOM version currently stored on the node. Parse an xml MOM file. Load proxys for an MO type that is not defined in the MOM.
-----------------------
cvls/cvmk/cvms/cvset/cvrm/cvcu/cvls1 inv[hr]
licensing, JVM, devices, XPs, etc. cab[slxradgtm] Display of miscellaneous COLI printouts relating to hw, sw
, restarts, leds, cpu load, errors, disk/ram usage stc[p][r] std ly). stv[b][r] channels. stt[r] hc diff/ldiff str[12ft] Display state and user of Physical Ports and Ds0Bundles. Run a general healthcheck on the node. Parameter auditing or MO dump comparisons. Print status of the IubLinks/AbisLinks and their associate Display state, user, and bandwidth usage for ATM ports and Display state and configuration of AtmCrossConnections. Display state and configuration of devices (RNC and MGW on
d Cells and Channels (RNC/BSC only). lki remod[u][2] tg[r][c][d] NC only). uer al[atk] lg[aevsmircdyuolh] y, system, etc) ----------------------------------- OTHER COMMANDS ------------------------Print UE context data for all active calls (RNC only). Print the list of active alarms. Fetching and processing of logs (alarm, event, availabilit Resource usage and configuration of IubLinks (RNC only). Remodule an IubLink (RNC only). Print Resource Object information for all MOs in LmCell (R
Open/close moshell logfiles. Send a COLI command to the node's OSE shell. Type "h ose"
for syntax help and "?" to view available commands. bo[r]/ba[swdp]/br[wd]/bp Manage board groups that can be used for running COLI
commands on multiple boards. lh mon/mon+/mon-/mon? Run COLI commands on all boards of a board group. Start/stop/check the target monitor server on the node and
/or start the monitor client for one or more board Group(s). sql+/sql-/sql? pgu[c][f] ftree "ls -lR" in unix). ftget[c]/ftput[c] Transfer files or directories to/from the node, using ftp. Start/stop/check the SQL client on the node (CXC1325608). Program Upgrade. For STP use only, eg, to load black LMs. Recursive listing on the node's file system (equivalent to
htget edit fclean[f|ff|d|e] directory on the node. hi nt session. lmid[c] r codes. p/w/pw/b prox command. col ul out. conf[bld] gs/gsg mmands. ip2d/d2ip
Transfer files from the node using http. Edit a file on the node. Removal of obsolete loadmodules OR recursive removal of a
Change moshell prompt and/or window title. Toggle display of proxy identities in printout of get
Toggle display of colors. Toggle display of userlabel in st/lst and pget/lpget print
Toggle confirmation on various MO commands. Toggle display of old/new attribute value in set/bl/deb co
database) or vice-versa. h2d/d2h h2b/b2h wait Convert an integer to hexadecimal or viceversa. Convert a binary to hexadecimal or viceversa. Specify a delay in hrs, mins, secs, or rops. Similar to th
e unix "sleep" command (scripting). return ipting). print alias/unalias q/by/exit/quit Print a line or variable (scripting). Print or define command aliases. Exit moshell. ------------------------Exit from a command file without exiting from moshell (scr
(lmom, CDMA only). pget/lpget hpget[c]/lhpget[c] Read PM attribute(s) from MO(s). Read PM attribute(s) from MO(s), print horizontally one li
ne per MO (instead of one line per attribute). pdiff/lpdiff pmx[hfdn] files. pmr[ag] Produce PM KPI reports, based on counter values in statist Print incrementation of PM attributes. Display counter values, extracted from the statistics ROP
ics ROP files and formulas in CPI documentation. pme[fd][cgu] pst pgets[n] pcr[cfd]/lpcr[cfd] pbl pdeb pdel emom sed scanner. pset[d] Set the contents of an event-based scanner (RNC/RBS only). Fetch/decode event ROP files (RNC/RBS only). List all PM scanners and their state. Print scanner contents. Create a statistics scanner. Suspend a scanner. Resume a scanner. Delete a scanner. Display list of events available for each kind of event-ba
-------------------------
0 1 2 3 4 5 6 7 8 9
Installation, security, and user settings Revision History Tutorial Command syntax, regular expressions Command descriptions Lazy Scripting Utilities Server Maintenance Offline Mode
Type: - h - h
- RDN (Relative Distinguished Name) This is used to identify an MO in relation to its nearest parent in the MO tree. The RDN contains MO Class (also called MO Type), the equal sign, and MO identity. Example: AtmPort=MS-24-1 ===> "AtmPort" is the MO Class, "MS-24-1" is the identity
- LDN (Local Distinguised Name) This is used to uniquely identify an MO within a node. The LDN shows the hierarchy above the MO, within the Managed Element's MO tree. Example: ManagedElement=1,TransportNetwork=1,AtmPort=MS-24-1 - FDN (Full Distinguished Name) This is used to uniquely identify an MO within a network (used by RANOS/CNOSS). Example: SubNetwork=AUS,SubNetwork=H2RG_0201,MeContext=St_Leonards_Station_2065010,ManagedElement=1,Tra nsportNetwork=1,AtmPort=MS-24-1
The first argument in the MO-related commands is usually used to specify the MOs that should be affected by the command. Six ways can be used to specify the MO(s): 1) all ===> all MOs in the proxy table will be affected Example: get all userlabel ====> get attribute "UserLabel" on all MOs Note: instead of "all", it is also possible a wildcard such as "." or "*". This has the same effect.
2) proxy id(s) ===> MO(s) with the given proxy id(s) will be affected. To specify several MO proxies, there are two ways: - Specify each proxy id with a space in between Example: pr 0 2 5 - Give a range Example: pr 4-10 pr 10-4 ===> print MO proxies from 4 to 10 ===> print MO proxies 0, 2, and 5
===> print MO proxies from 10 to 4 (reverse order, useful for deleting MOs)
3) link handler (for pluginunit and spm MOs only) Example: acc 001400 restart bl 001900/sp0.lnh ====> to restart the MO Subrack=MS,Slot=14,PlugInUnit=1 Subrack=MS,Slot=19,PlugInUnit=1,Spu=1,Spm=1
4) mo group ===> MO(s) belonging to the given MO group will be operated upon. MO groups can be created using the commands ma/lma and mr/lmr, as well as hget/lhget, lk/llk, st/lst. See command description for these commands.
Note: In RNC, running the "bo" command will automatically create a number of MO groups containing the cc/dc/pdr device MOs for each module.
5) board group ===> MOs (PlugInUnit or Spm) mapped onto the boards belonging to the given board group will be operated upon. Example1: baw sccp sccp the board group "sccp" bl sccp will be locked Example2:In RNC, using the default board groups created after running the bo command: acc mod10 restart pr dc10 acc dc10 bl dc10dev see paragraph 4. above) restart (the board group dc10 is mapped onto the Spm MOs) (in this case we are using the MO group containing the Device MOs, ====> all PlugInUnit or Spm MOs connected to boards of this board group ====> all boards with the swallocation matching "sccp" will go into
6) mo-filter ===> MO(s) whose LDN/RDN match the pattern will be operated upon. If the command starts with "l" then the pattern will match agains the LDN. If the command doesn't start with "l", then the pattern will match against the RDN. Example: =>=> pr ms-24-1 returns: TransportNetwork=1,AtmPort=MS-24-1
TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1,VclTp=vc32 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1,VclTp=vc33 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1,VclTp=vc337 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1,VclTp=vc332 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp2 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp2,VpcTp=1 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp2,VpcTp=1,VclTp=vc34 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp2,VpcTp=1,VclTp=vc35 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp2,VpcTp=1,VclTp=vc40 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp2,VpcTp=1,VclTp=vc64 When using the mo-filter, it is a good idea to test the pattern with "pr/lpr" command before issuing a get/set/acc/cr/del command, in order to see which MOs will be matched by the pattern.
Sometimes, a second or third argument can be given, which is usually a string matching the attribute or attribute value that you want to display.
The search string that is used in the filters is a Unix Regular Expression (like the patterns used in grep command). Therefore, special meta-characters such as . * [ ] ^ $ can be used. Short description of some meta-characters: "." ===> any single character "*" ===> 0 or more occurences of the previous character [] ===> matches a character or range of characters inside the brackets
[^] ===> NOT matching a character or range of characters inside the brackets | ^ $ ! % ===> OR ===> beginning of string ===> end of string ===> negation ===> reverse order
E.g: "a*" means a or aa or aaa, etc. ".*" is like a wildcard as it matches 0 or more occurences of any character "[a-z]" matches all letters from a to z "[abe]" matches letters a,b, and e "[^3]" 3|5|6 ^a.*4$ middle Regular expressions can be grouped using brackets, e.g: "cell(11|23|45) matches cell11 or cell23 or cell45 matches any character but not 3 matches 3 or 5 or 6 matches a string beginning with a and finishing with 4, with any character in the
lpr !loadmodule|program ===> all MOs except those matching "loadmodule" or "program" will be printed.
lpr =6.*prog.*=1 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=15 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=1 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=14 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=13 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=12 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=11 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=10 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=19 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=18 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=17 Equipment=1,Subrack=1,Slot=6,PlugInUnit=1,Program=16
lpr ms-24-1 TransportNetwork=1,AtmPort=MS-24-1 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1,VclTp=vc32 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1,VclTp=vc33 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1,VclTp=vc337 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp1,VpcTp=1,VclTp=vc332 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp2 TransportNetwork=1,AtmPort=MS-24-1,VplTp=vp2,VpcTp=1
a) For attributes of type Struct, use the following syntax: attr1=val1[,attr2=val2[,attr3=val3]]]... It is not necessary to specify all the struct members, only those that are required to change can be specified. Example: ===> set sid sib11 sib11repperiod=128 ===> set mtp3bspitu sppriority prioslt=2 ===> set mtp3bspitu sppriority prioslt=2,prioco=2
b) For attributes of type MoRef, just type the MO LDN (without "ManagedElement=1"). Eg: ===> lset AtmPort=1221,VplTp=vp1 atmTrafficDescriptor transportnetwork=1,atmtrafficdescriptor=C1P4500 It is also possible to skip the first parent (eg transportnetwork, swmanagement, etc). Eg: ===> cr rncfunction=1,utrancell=30451,utranrelation=30451to30521 Attribute 1 of 1, utrancellref (moRef:UtranCell): utrancell=30521 have to specify rncfunction=1 #in this case we don't
c) For attributes of type array of MoRefs, separate each element of the array with spaces. Eg: ===> set jvm admclasspath loadmodule=oms loadmodule=vbjorb loadmodule=asms_sharp
loadmodule=iaik loadmodule=cma loadmodule=roam ===> acc aal2pathdistributionunit=1 addPath Parameter 1 of 1, aal2PathVccTpId (sequence-moRef-Aal2PathVccTp): aal2pathvcctp=csa aal2pathvcctp=csb
d) For attributes of type array of Struct, separate each element of the array with semicolons. Eg: ===> set rncfunction aliasPlmnIdentities mcc=300,mnc=23,mnclength=2;mcc=345,mnc=32,mnclength=2;mcc=208,mnc=123,mnclength=3
e) For attributes of type array of integer/long/float/string/boolean, separate each element of the array with commas. Eg: ===> set antfeedercable=6 ulattenuation 10,10,10,10,10,10,10,10,10 ===> set jvm options -Xms65000k,-Dhttp.root=/c/public_html,-
Dse.ericsson.security.PropertyFileLocation=/c/java/SecurityManagement.prp ===> set cell=3041 ActiveOverlaidCDMAChannelList true,true,false,true ===> acc managedelementdata addDhcpServerAddress Parameter 1 of 1, ipAddressArray (sequence-string): 10.1.1.3,10.1.1.4
f) To input an empty value: * in set command, just leave the value field blank. Eg: ===> set 0 userlabel (# attribute type is string) (#attribute type is MoRef)
* in cr command, type "null" if it's an MoRef or "d" for other attributes. This is only supported for non-mandatory (restricted) attributes, because mandatory attributes must have a value * in acc command, type "null". This is only supported for parameters of type MoRef or String.
The command line uses the Readline library from bash. Here are some of the supported function keys: - right arrow or Ctrl-f : move forward one character - left arrow or Ctrl-b - up arrow - down arrow - backspace - Ctrl-d or "del" - Ctrl-a or "home" - Ctrl-e or "end" - Ctrl-u - Ctrl-k - Alt-f - Alt-b : move backward one character : previous command in history buffer : next command in history buffer : delete one character backward : delete one character forward : go to beginning of line : go to end of line : erase all characters backward : erase all characters forward : move forward one word : move backward one word
Note about command history: if you type the beginning of a command and then use the up/down arrow key, you will see all previous commands starting with this string
3.5- Piping
Some commands support piping, eg: OSE shell commands, lh, tg, str, etc. This is usually indicated in the menu and the help for that command. Examples: ===> te log read | grep ERROR
===> lh mp te log read | grep ERROR ===> str | grep cell=30456 For other commands that don't support piping (like MO commands), the workaround is to save the output to a logfile then run the unix command on that logfile by using the "l" or "!" command. Example: ===> l+ #open the logfile, an arbitrary name will be given #run the command
#close the logfile #run the unix command on the logfile. $logfile is a default variable
that stores the name of the latest log created ===> l grep -i basic $logfile
# prepare some counters set timeout 30 set timeoutacc 0 set maxtimeout 600
# there is no need to "eval" this # spawn works with a list of args spawn -noecho $MOSHELL $ip_address
# count the prompts that have been seen incr ::promptcnt # debug, .. puts stderr "$MOSHELL Prompt: $Prompt seen" if {$promptcnt < 2} { # this might be wrong exp_send -s "\r" # and continue with this call to expect exp_continue } } timeout { # expect goes here after $timeout seconds # bookkeeping how long you have been waiting incr ::timeoutacc $::timeout # debug every $timeout seconds puts stderr "1\tMoShell not responding! $::timemoutacc sec" # as long as your $maxtimeout is not reached resume the expect call if {$::timeoutacc < $::maxtimeout} { # restart this expect call exp_continue }
} eof { # if the spawnded process dies you go here: puts stderr "$MOSHELL died on me" } puts stderr "finished! $::promptcount" break }