Posts

Showing posts with the label csv

Splunk Creating eventtypes from csv to name VLANS

Image
Splunk Creating eventtypes from csv to name VLANS Everyone got the VLAN name lookup working from the last post? You did.. ? Really someone is listening? Next lets use the information in the internal_networks.csv file to create event types and really change the way we search in splunk. While researching this topic, I learned that you CAN NOT do subsearches in eventtypes.conf I was hoping to do something like (dont try it it doesnt work) eventtypes.conf [vlan:Guest]   search src_ip=172.30.21.0/24 |lookup vlan network AS src_ip OUTPUT name AS Src_VLAN So I had to find an easy way to parse our csv. I love trying to do all my heavy lifting on one line in linux. So I challenged myself.. can it be done? As a reminder here is our internal_networks.csv  I have cleaned it up to conform with the common information model the best I could.  No spaces in the names and no capital letters. network,name "192.168.1.0/24","corporate" "192.168.2.0/24","voice" "...

Store CSV Data on HEC DSSVUE DSS for HEC HMS Model Automation

Image
Store CSV Data on HEC DSSVUE DSS for HEC HMS Model Automation Recently I have encountered with a problem of automating the HEC-HMS model running with real-time weather data. If you are familiar with Hydrologic Modeling System HEC-HMS, you can design the model by running the program in UI mode. When setting the Data Source as Manual Entry  HEC-HMS 3.5 Data source set to Manual Entry   as shown in figure 1 , users can enter the value using the inbuilt Table tool as shown in figure 2. Figure 1: HEC-HMS 3.5 Data source set to Manual Entry Figure 2: HEC-HMS 3.5 Insert Timeseries using Table tool Before you are going to update the HEC-HMS data without Table tool, first you have to change the Data Source into Data Storage System (HEC-DSS)  as shown in the figure 3. Figure 3: HEC-HMS 3.5 Set Data Source into Data Storage System (HEC-DSS) According to your HEC-HMS model setup, the .gage  files content will change as shown below; Gage Manager: 2008_2_Events Version: 3.5 ...