Sponsored Content
Top Forums Shell Programming and Scripting Find specific lines between two brackets after a word Post 302961152 by looney on Tuesday 24th of November 2015 12:39:43 PM
Old 11-24-2015
using grep
Code:
grep -o "node.*'\|include.*" infile

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

delete lines containing a specific word in afile

Hi, Please suggest how to write a shell script which delets all the lines containing the word unix in the files supplied as argument in the shell. (4 Replies)
Discussion started by: sireesha9
4 Replies

2. Shell Programming and Scripting

How to delete all lines before a specific word?

Let's say we have a file containing: alllllsadfsdasdf qwdDDDaassss ccxxcxc#2222 dssSSSSddDDDD D1Sqn2NYOHgTI Hello Alex ssS@3 Ok, and let's say we want to delete all words from D1Sqn2NYOHgTI and back, this means to delete the words (and the lines of them) : alllllsadfsdasdf... (2 Replies)
Discussion started by: hakermania
2 Replies

3. UNIX for Dummies Questions & Answers

How to print line starts with specific word and contains specific word using sed?

Hi, I have gone through may posts and dint find exact solution for my requirement. I have file which consists below data and same file have lot of other data. <MAPPING DESCRIPTION ='' ISVALID ='YES' NAME='m_TASK_UPDATE' OBJECTVERSION ='1'> <MAPPING DESCRIPTION ='' ISVALID ='NO'... (11 Replies)
Discussion started by: tmalik79
11 Replies

4. Shell Programming and Scripting

find a word and print n lines before and after the match

how to find a word and print n lines before and after the match until a blank line is encounterd (14 Replies)
Discussion started by: chidori
14 Replies

5. Shell Programming and Scripting

awk to find lines containing word that occur multiple times

i have a script that scans a log file every 10 minutes. this script remembers the last line of the log and then uses it to continue monitoring the log when it runs again 10 minutes later. the script searches the log for a string called MaxClients. now, how can i make it so that when the... (7 Replies)
Discussion started by: SkySmart
7 Replies

6. Shell Programming and Scripting

How to find a word and move it a specific location in xml file using perl?

Hi friends, I have one XML file having below structure :- INput XML file :- <?xml version="1.0" encoding="UTF-8"?> <START> <A=value1> <attr name1="a1"> </A> <B=value2> <attr name2="b1"> <attr name3="c1"> </B> </START> output xml file should be === (3 Replies)
Discussion started by: harpal singh
3 Replies

7. UNIX for Dummies Questions & Answers

Quick UNIX command to display specific lines in the middle of a file from/to specific word

This could be a really dummy question. I have a log text file. What unix command to extract line from specific string to another specific string. Is it something similar to?: more +/"string" file_name Thanks (4 Replies)
Discussion started by: aku
4 Replies

8. Shell Programming and Scripting

Deleting lines in a fixed length file where there is a word at specific location

I have a big file having 100 K lines. I have to read each line and see at 356 character position whethere there is a word "W" in it. If it is their then don't delete the line otherwise delete it. There are two lines as one Header and one trailer which should remain same. Can somebody... (5 Replies)
Discussion started by: mohit kanoongo
5 Replies

9. Shell Programming and Scripting

Shell Script @ Find a key word and If the key word matches then replace next 7 lines only

Hi All, I have a XML file which is looks like as below. <<please see the attachment >> <?xml version="1.0" encoding="UTF-8"?> <esites> <esite> <name>XXX.com</name> <storeId>10001</storeId> <module> ... (4 Replies)
Discussion started by: Rajeev_hbk
4 Replies

10. Shell Programming and Scripting

How to find files containing two specific lines and delate those lines?

Hi I need to find files in a specified folder where are two specified lines of text and delate that lines. It looks like this" 35. ?>NL 36. <iframe>.......</iframe>NLThe problem is that "?>" is in the other lines and id should not be removed if the next line is not like "<iframe>....." So... (4 Replies)
Discussion started by: androwida
4 Replies
PMDAVMWARE(1)						       Performance Co-Pilot						     PMDAVMWARE(1)

NAME
pmdavmware - VMware performance metrics domain agent (PMDA) DESCRIPTION
pmdavmware is a Performance Metrics Domain Agent (PMDA) which exports metric values from a (possibly remote) VMware virtualisation host. This implementation uses the VMare Perl API (refer to the online docs at http://www.vmware.com/support/developer/viperltoolkit). VIPerl is a prerequisite for this PMDA, it needs to be installed and configured before attempting to use this agent. It is highly recommended that you test your VIPerl installation using the demo programs that are shipped with VIPerl, before attempting to use this PMDA. INSTALLATION
In order to access performance data using the VIPerl API, it is necessary to be able to login to the metrics source. Hence, a valid VMware server name, user name and pass word are needed by the PMDA. These can be passed in on the command line (via the pmcd.conf file) or via a vmware.conf file in the PMDA directory. # cd $PCP_PMDAS_DIR/vmware # [ edit vmware.conf ] This file should contain three lines, such as: $server = 'vm.server.net'; $username = 'XXXX'; $password = 'YYYY'; Once this is setup, you can access the names and values for the vmware performance metrics by doing the following as root: # cd $PCP_PMDAS_DIR/vmware # ./Install If you want to undo the installation, do the following as root: # cd $PCP_PMDAS_DIR/vmware # ./Remove pmdavmware is launched by pmcd(1) and should never be executed directly. The Install and Remove scripts notify pmcd(1) when the agent is installed or removed. FILES
$PCP_PMDAS_DIR/vmware/vmware.conf configuration file for the pmdavmware agent $PCP_PMDAS_DIR/vmware/Install installation script for the pmdavmware agent $PCP_PMDAS_DIR/vmware/Remove undo installation script for the pmdavmware agent $PCP_LOG_DIR/pmcd/vmware.log default log file for error messages from pmdavmware SEE ALSO
pmcd(1). 3.8.10 Performance Co-Pilot PMDAVMWARE(1)
All times are GMT -4. The time now is 05:10 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy