There are many matching blocks of text in one file that need to be deleted. This example below is one block that needs to be either deleted or replaced with an empty line.
This text below is the input file. The ouput file should be empty
Searching Checks. Based on search criteria
name: Value : CPU
name: Value : Memory
name: Value : RX_Errors
name: Value : RX_Errors1
name: Value : TX_Errors
name: Value : TX_Errors1
name: Value : ACE thresholds - Access List Limit
name: Value : ACI Fabric - DVS has been deleted
name: Value : ACI LAS-F01 - IS-IS Route Adjacencies Lost
name: Value : IVR Hours Of Operation
name: Value : IVR Hours Of Operation -
name: Value : Glance Cobrowse Waiting Check
name: Value : Glance Video Check
name: Value : DP_GLUSTER_DISK_IO_STAT
name: Value : Carbon_CPU
I want to remove the entire block. Here are some examples I have tested but am unable to remove the block of text. Any ideas?
#!/bin/bash -x
#The below line works
sed '/two/,/nine/d' newnumber > 1number
#This line works
#sed -i 's/Searching Checks.*name: Value : Carbon_CPU//g' test1 > 3test
#name: Value : TX_Errors1
#sed -i 's/Searching Checks.*name: Value : TX_Errors1//g' test1 > 3test
sed '/Searching Checks.\ Based\ a\ search\ criteria/,/name:\ Value\ :\ Carbon_CPU/d' test1 >> 4test
#These may not work
#sed '/Searching Checks. Based a search criteria/,/name: Value : Carbon_CPU/d' test1