[dns-stats-users] Adding nodes to hedgehog

John Dickinson jad at sinodun.com
Wed May 20 14:48:03 UTC 2015


Hi,

You need to set the current month in the call to /usr/local/bin/hedgehog_database_manage_partitions.sh. Like this

/usr/local/bin/hedgehog_database_manage_partitions.sh -p 2015-05

By default that script is designed to run from cron to create next months tables before the end of the current month.

John


> 
> On 20 May 2015, at 15:41, matt singh <matt.singh at centralnic.com> wrote:
> 
> Hello,
> 
> I have one node graphing ok.  I am looking to add another.
> 
> Into /usr/local/etc/hedgehog/nodes.csv I have added.
> 
> ns-6,Node-2,Region-1
> 
> Then run,
> sudo -u hedgehog /usr/local/bin/hedgehog_database_update_nodes.sh
> sudo -u hedgehog /usr/local/bin/hedgehog_database_manage_partitions.sh
> 
> sudo -u hedgehog /usr/local/bin/refile_and_grok.sh
> 
> But in the file I see an error;
> 
> /usr/local/var/hedgehog/data/ns-6/Node-2/dsc-extractor-xml-db.out
> 
> ----------------------- 2015-05-20 15:08:12 BST ----------------------
> *** Database connected
> *** Processing server: ns_6
> *** Processing node:   Node-2
> *** Found:             107 .xml files to process.
> 
> 2015-05-20 15:08:12 BST: Starting:  ./incoming/1432123500.dscdata.xml
> Format 2 runtime error: ERROR:  relation "dsc.data_ns_6_pcap_stats_2015_05" does not exist
> LINE 1: INSERT INTO dsc."data_ns_6_pcap_stats_2015_05" (server_id, n...
> 
> PostgreSQL log;
> 
> May 20 15:10:43 localhost postgres[30790]: [12-1] < 2015-05-20 15:10:43.137 BST >ERROR:  relation "dsc.data_ns_6_pcap_stats_2015_05" does not exist at character 13
> 
> May 20 15:10:43 localhost postgres[30790]: [12-2] < 2015-05-20 15:10:43.137 BST >STATEMENT:  INSERT INTO dsc."data_ns_6_pcap_stats_2015_05" (server_id, node_id, plot_id, starttime, key1, key2, value) values (3, 3, 20, timestamptz 'epoch' + 1432123440 * interval '1 second', 'filter_received','bond0', 24916), (3, 3, 20, timestamptz 'epoch' + 1432123440 * interval '1 second', 'pkts_captured','bond0', 22875), (3, 3, 20, timestamptz 'epoch' + 1432123440 * interval '1 second', 'kernel_dropped','bond0', 2039);
> 
> I can see "data_ns_6_pcap_stats_2015_05" is not in the database, but "data_ns_6_pcap_stats_2015_06" is.
> 
> I can get around this problem by dropping the entire hedgehog database and then initializing it again
> 
> sudo -u hedgehog /usr/local/bin/hedgehog_database_init.sh
> 
> and re-importing the data, but ideally am trying to avoid this.
> 
> I have tried running
> sudo -u hedgehog /usr/local/bin/refile_and_grok.sh -s 2015-05-18T, but still no joy.
> 
> Any ideas what I'm overlooking here?
> 
> thanks,
> matt
> 
> _______________________________________________
> dns-stats-users mailing list
> dns-stats-users at dns-stats.org
> https://mm.dns-stats.org/mailman/listinfo/dns-stats-users



More information about the dns-stats-users mailing list