Script to extract data -

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I would like to write a script to extract two numbers from the following 
xml file:

        <graph caption="Customer: bobgoodwin@xxxxxxxxxxxx"
        xaxisname="Figures Shown Reflect Data Usage in the Last 30 Days"
        yAxisName="Data Usage" bgColor="E3ECF6" showGridBg="1"
        showCanvas="1" numdivlines="4" decimalPrecision="0"
        zeroPlaneColor="CCCCCC" zeroPlaneAlpha="40" numberSuffix="MB">
        <set name="Actual Usage Upload" value="1088" color="007CC2"/>
        <set name="Usage Threshold Upload" value="5000" color="9CA279"/>
        <set name="Actual Usage Download" value="12667" color="007CC2"/>
        <set name="Usage Threshold Download" value="17000" color="9CA279"/>
        </graph>

The two values I need are in this case the 1988 and the 12667.

        <set name="Actual Usage Download" value="12667" color="007CC2"/>

        <set name="Actual Usage Upload" value="1088" color="007CC2"/>


I need to create a script I can run daily to check and record our usage 
in order to stay within our allocation. I can muddle through the rest 
but it would save me a lot of struggling if someone could show me how to 
do this part. My effort so far has not been productive!

Thank you.

Bob


-- 


-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines

[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux