The tail program is available on Unix operating systems and is used to view the tail end of  a text file or piped data. Once tail is running for a particular log file, and as the log file get populated with new data, the newly populated content is displayed on the screen real-time. This saves a step from having to use more or cat after the fact where a user would have to scroll all the way through the log file to the end in order to view the newly added data (and more data may continuously be added making it even more inconvenient).

In the case of the Acme Packet SBC, retrieving log files for viewing typically requires downloading them via FTP/SFTP. The Acme Packet SBC now supports tail from ACLI.

In the following example I want to see what dialog is happening when trying to register a SIP phone through the SBC.  It is possible to tail different log files.

NNOS-VM# notify sipd siplog

NNOS-VM# tail-logfile-open sipd sipmsg.log

waiting 1200 for response to request
completed

14:44.154 On [0:0]72.12.135.250:5060 received from 72.12.135.2:56883
REGISTER sip:acmepacket.local SIP/2.0
Via: SIP/2.0/UDP 172.20.10.4:56883;rport;branch=z9hG4bKPjjWHgcYsrr-T9bPbaZ1-hzFTE-U70g.F2
Route: <sip:acmepacket.local;lr>
Max-Forwards: 70
From: “Mark Holloway-8001” <sip:7818018001@acmepacket.local>;tag=q.wbz5RZXd30uc7RwV2IP4GmSCGKDTwl
To: “Mark Holloway-8001” <sip:7818018001@acmepacket.local>
Call-ID: VV5Yro3MQmi7fXX1CDeDax79zDnR.5jN
CSeq: 55540 REGISTER
User-Agent: Telephone 1.1.4
Contact: “Mark Holloway-8001” <sip:7818018001@172.20.10.4:56883;ob>
Expires: 300
Allow: PRACK, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONS
Content-Length: 0

—————————————-

14:44.158 On [0:0]72.12.135.250:5060 sent to 72.12.135.2:56883
SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 172.20.10.4:56883;received=72.12.135.2;branch=z9hG4bKPjjWHgcYsrr-T9bPbaZ1-hzFTE-U70g.F2;rport=56883
From: “Mark Holloway-8001” <sip:7818018001@acmepacket.local>;tag=q.wbz5RZXd30uc7RwV2IP4GmSCGKDTwl
To: “Mark Holloway-8001” <sip:7818018001@acmepacket.local>;tag=aprqngfrt-ejkv9p0000m9f
Call-ID: VV5Yro3MQmi7fXX1CDeDax79zDnR.5jN
CSeq: 55540 REGISTER

—————————————-

NNOS-VM# notify sipd nosiplog

NNOS-VM# tail-logfile-close sipd sipmsg.log

  1. Mark Natale says:

    This is excellent. I had never known this existed until now. Thank you so much for posting about it. Ashame there is no string filtering (grep, findstr, etc) like feature though but still tailing will be useful.

  2. Ryan says:

    I tired this and it worked great but i couldnt get it to stop tailing,

    I tried ctrl-c and pasting the tail-logfile-close sipd sipmsg.log and/or notify sipd nosiplog but it didnt stop the tail print out, is there a better way to stop it?

  3. Pablo says:

    To stop tailing you run tail-logfile-close

  4. Njeri Matathia says:

    Can I use wild card to pull information from a Broadworks Network Server.
    For example can i use bwcli (NS_CLI/Policy/Profile> get *L) to pull all profiles that end with “L”. I love your blog and have been of great help,

  5. nick says:

    mark,

    why does the show interface brief and show interface show different ip addresses for media interfaces m00 and m10… shouldn’t they be the same.

    nick

  6. Sim Singh says:

    we cannot run these commands on SD7.x 9200 so want to know if someone can help with what can be done on 9200
    basically we have routing is using multiple LRT files and during making test calls, want to check what LRT file is used or what LRT file got hit to complete that call

    we can manually check by show lrt route-entry but is it possible to do real time trace/capture on the SBC running SD.7.x code on 9200

  7. nick says:

    mark,

    when i issue a tail-logfile-open sipd sipmsg.log command from cli on a busy SBC. i cannot issue the command to stop the tail. the data is flying by to quickly. is there a break command that will stop the log so i can use the- tail-logfile-close sipd sipmsg.log. afraid the SBC will run out of CPU processor