LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-08-2013, 01:34 PM   #1
ShevyRoots
LQ Newbie
 
Registered: Dec 2013
Posts: 5

Rep: Reputation: Disabled
Shell Script to parse system performance.


Need help with creating a shell script to parse and display performance stat to the screen.
cd to /stats/ and they are many performance related state under the stats dir. How do I view call related stats? Example, I have three nodes reporting wireless call related stats and would like a script that can parse the stats/sysgrp files that are created every 15mins and report which node experienced wireless call failures.

Thanks in advance!!
ShevyRoots
 
Old 12-08-2013, 02:11 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,332
Blog Entries: 55

Rep: Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533
Welcome to LQ. Hope you like it here.


Quote:
Originally Posted by ShevyRoots View Post
Need help with creating a shell script
Then do show what (pseudo) code you already have and where you're stuck.

OTOH if you've never created a script then these might help:
http://www.gnu.org/software/bash/man...ode/index.html
http://www.tldp.org/HOWTO/Bash-Prog-Intro-HOWTO.html
http://www.tldp.org/LDP/Bash-Beginne...tml/index.html
 
Old 12-08-2013, 03:13 PM   #3
ShevyRoots
LQ Newbie
 
Registered: Dec 2013
Posts: 5

Original Poster
Rep: Reputation: Disabled
Shell Script to parse system performance

Hey unSpawn, thanks for the reply. I do appreciate your links. Really, I was looking for a sample scripts to retrieve/pull and display call related stats concerning three different nodes/systems that's providing VoIp calls stats. The /stats dir create files every 15 minutes and have fields like, TotalInvites, TotalFailedCalls, Total Sip500Errorcode and so on. Anyhow, I'll dig into the information within the links you sent me.

Thanks
ShevyRoots
 
Old 12-08-2013, 04:18 PM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,332
Blog Entries: 55

Rep: Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533
Before you dig into the nfo best search for common SIP / VoIP commands and related tools. Should be a tool already providing statistics...
 
Old 12-08-2013, 10:15 PM   #5
grail
LQ Guru
 
Registered: Sep 2009
Location: Perth
Distribution: Manjaro
Posts: 9,424

Rep: Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823
If the statistics are for the individual user you may wish to have a look at conky and see if it can display what you need (why re-create the wheel if someone has done it for you )
 
Old 12-08-2013, 10:19 PM   #6
grail
LQ Guru
 
Registered: Sep 2009
Location: Perth
Distribution: Manjaro
Posts: 9,424

Rep: Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823Reputation: 2823
If the statistics are for the individual user you may wish to have a look at conky and see if it can display what you need (why re-create the wheel if someone has done it for you )
 
Old 12-10-2013, 10:03 AM   #7
schneidz
LQ Guru
 
Registered: May 2005
Location: boston, usa
Distribution: fc-15/ fc-20-live-usb/ aix
Posts: 5,051

Rep: Reputation: 852Reputation: 852Reputation: 852Reputation: 852Reputation: 852Reputation: 852Reputation: 852
Quote:
Originally Posted by ShevyRoots View Post
Hey unSpawn, thanks for the reply. I do appreciate your links. Really, I was looking for a sample scripts to retrieve/pull and display call related stats concerning three different nodes/systems that's providing VoIp calls stats. The /stats dir create files every 15 minutes and have fields like, TotalInvites, TotalFailedCalls, Total Sip500Errorcode and so on. Anyhow, I'll dig into the information within the links you sent me.

Thanks
ShevyRoots
not really sure the format of your stats file but perhaps this is a start:
Code:
egrep "(TotalInvites|TotalFailedCalls|Total Sip500Errorcode)" stats.txt
 
Old 12-10-2013, 10:19 AM   #8
ShevyRoots
LQ Newbie
 
Registered: Dec 2013
Posts: 5

Original Poster
Rep: Reputation: Disabled
Hey, thanks schneidz!! I'll try that.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Need Shell Script to parse Zimbra Sync.log rlug Linux - General 1 01-08-2012 09:29 AM
How can I configure a shell script which will parse ldap data in for each dn: vikki Linux - Server 2 12-28-2011 08:38 AM
[SOLVED] How do I make an AWK script parse a Shell Variable Nerdio Linux - Newbie 4 11-16-2011 02:16 PM
[SOLVED] How to parse and modify these keywords using shell script? corone Programming 17 04-26-2011 08:33 AM
[shell script] execute command and parse output stoiss Programming 2 01-26-2009 02:49 AM


All times are GMT -5. The time now is 09:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration