Skip to content
DataMiner DoJo

More results...

Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Search in posts
Search in pages
Search in posts
Search in pages
Log in
Menu
  • Blog
  • Questions
  • Learning
    • E-learning Courses
    • Open Classroom Training
    • Certification
      • DataMiner Fundamentals
      • DataMiner Configurator
      • DataMiner Automation
      • Scripts & Connectors Developer: HTTP Basics
      • Scripts & Connectors Developer: SNMP Basics
      • Visual Overview – Level 1
      • Verify a certificate
    • Tutorials
    • Video Library
    • Books We Like
    • >> Go to DataMiner Docs
  • Expert Center
    • Solutions & Use Cases
      • Solutions
      • Use Case Library
    • Markets & Industries
      • Media production
      • Government & defense
      • Content distribution
      • Service providers
      • Partners
      • OSS/BSS
    • DataMiner Insights
      • Security
      • Integration Studio
      • System Architecture
      • DataMiner Releases & Updates
      • DataMiner Apps
    • Agile
      • Agile Webspace
      • Everything Agile
        • The Agile Manifesto
        • Best Practices
        • Retro Recipes
      • Methodologies
        • The Scrum Framework
        • Kanban
        • Extreme Programming
      • Roles
        • The Product Owner
        • The Agile Coach
        • The Quality & UX Coach (QX)
    • DataMiner DevOps Professional Program
  • Downloads
  • More
    • Feature Suggestions
    • Climb the leaderboard!
    • Swag Shop
    • Contact
      • General Inquiries
      • DataMiner DevOps Support
      • Commercial Requests
    • Global Feedback Survey
  • PARTNERS
    • All Partners
    • Technology Partners
    • Strategic Partner Program
    • Deal Registration
  • >> Go to dataminer.services

Script to edit timeout settings on multiple elements

Solved1.66K views7th July 2023elements timeout
4
Arunkrishna Shreeder [SLC] [DevOps Advocate]4.00K 13th January 2023 0 Comments

Hello,

Aside from editing the timeout value directly as shown below, is any other option to do the requested in bulk ? For e.g., using a script ? Thank you.

Marieke Goethals [SLC] [DevOps Catalyst] Selected answer as best 7th July 2023

4 Answers

  • Active
  • Voted
  • Newest
  • Oldest
10
Bruno Dias [SLC] [DevOps Member]2.36K Posted 13th January 2023 0 Comments

Another alternative, instead of using an automation script, is to use the element export/import to CSV function.

This allows you to export your element settings to a CSV file, you can change the file to update different settings from several elements and import the file. DataMiner will process this and update all elements from the CSV accordingly.

Looking at the CSV data exported, you will find the time settings you asked for:

Further details can be found: Importing and exporting elements | DataMiner Docs

In this video, there's a step-by-step explanation of this: Rui’s Rapid Recap - Bulk editing via CSV import - DataMiner Dojo

Marieke Goethals [SLC] [DevOps Catalyst] Selected answer as best 7th July 2023
6
Jorge Dias [SLC] [DevOps Enabler]4.76K Posted 13th January 2023 0 Comments

Hi,

Please find below an example of changing the primary connection timeout when is SNMPV2. If your element is different just change accordingly.

using System;
using System.Linq;
using Skyline.DataMiner.Automation;
using Skyline.DataMiner.Library.Automation;
using Skyline.DataMiner.Library.Common;

/// <summary>
/// DataMiner Script Class.
/// </summary>
public class Script
{
/// <summary>
/// The Script entry point.
/// </summary>
/// <param name="engine">Link with SLAutomation process.</param>
public void Run(Engine engine)
{
var dms = engine.GetDms();
var element = dms.GetElement("cn-lab-340-1");

var connection = element.Connections.FirstOrDefault() as SnmpV2Connection;
connection.Timeout = TimeSpan.FromMilliseconds(1500);

element.Update();
}
}

You need the following references/nuget packages:

<Param type="ref">C:\Skyline DataMiner\ProtocolScripts\DllImport\slc.lib.automation\1.3.0.2\lib\net462\SLC.Lib.Automation.dll</Param>
<Param type="ref">C:\Skyline DataMiner\ProtocolScripts\DllImport\slc.lib.common\1.3.0.2\lib\net462\SLC.Lib.Common.dll</Param>

Jorge Dias [SLC] [DevOps Enabler] Answered question 13th January 2023
1
Jens Vandewalle [SLC] [DevOps Enabler]9.44K Posted 13th January 2023 0 Comments

Hi Arunkrishna,

In addition to the answer from Jarno, below you can find an example by using the Class Library.

private void ConfigureHubGateway(IDmsElement hubGatewayElement)
{
foreach (var connection in hubGatewayElement.Connections)
{
if (connection is HttpConnection http)
{
http.Timeout = TimeSpan.FromSeconds(5);
}
}

hubGatewayElement.Update();
}

Jens Vandewalle [SLC] [DevOps Enabler] Answered question 13th January 2023
-2
Jarno Lernou [SLC] [DevOps Enabler]5.00K Posted 13th January 2023 0 Comments

Hi Arun,

Yes, this is possible through an SLNET call, however, I think it should also be possible to do it in the Class Library which is prefered. I don't have an off-the-shelf example though with the Class Library.

Example with SLNET call:

public void ChangeNimbraCommunity(Engine engine, Element myElement, int timeoutTime)
{
LiteElementInfoEvent leimyElement = GetElementLiteInfo(engine, myElement);

if(!string.IsNullOrWhiteSpace(leimyElement.Name))
{
if (leimyElement.PortInfo.Length == 2)
{
leimyElement.PortInfo[0].TimeoutTime = timeoutTime;
}

AddElementMessage aemRequest = new AddElementMessage
{
AlarmTemplate = leimyElement.AlarmTemplate,
CreateDVEs = leimyElement.CreateDVEs,
DataMinerID = leimyElement.DataMinerID,
Description = leimyElement.Description,
ElementID = leimyElement.ElementID,
ElementName = leimyElement.Name,
HostingDataMinerID = leimyElement.HostingAgentID,
IsHidden = leimyElement.Hidden,
IsReadOnly = leimyElement.IsReadOnly,
IsReplicationActive = leimyElement.IsReplicated,
KeepOnline = leimyElement.KeepOnline,
Ports = leimyElement.PortInfo,
ProtocolName = leimyElement.Protocol,
ProtocolVersion = leimyElement.ProtocolVersion,
State = leimyElement.State,
TrendTemplate = leimyElement.TrendTemplate,
Type = leimyElement.Type,
};

engine.SendSLNetSingleResponseMessage(aemRequest);
}
}

Jarno Lernou [SLC] [DevOps Enabler] Answered question 13th January 2023
Please login to be able to comment or post an answer.

My DevOps rank

DevOps Members get more insights on their profile page.

My user earnings

0 Dojo credits

Spend your credits in our swag shop.

0 Reputation points

Boost your reputation, climb the leaderboard.

Promo banner DataMiner DevOps Professiona Program
DataMiner Integration Studio (DIS)
Empower Katas

Recent questions

Web Applications exception in Cube due to invalid certificate 0 Answers | 0 Votes
Redundancy Groups and Alarming – Duplicate Alarms 0 Answers | 0 Votes
Correlation Engine: “Test rule” doesn’t result in a hit, despite functional rule 1 Answer | 3 Votes

Question Tags

adl2099 (115) alarm (62) Alarm Console (82) alarms (100) alarm template (83) Automation (223) automation scipt (111) Automation script (167) backup (71) Cassandra (180) Connector (109) Correlation (69) Correlation rule (52) Cube (151) Dashboard (194) Dashboards (188) database (83) DataMiner Cube (57) DIS (81) DMS (71) DOM (140) driver (65) DVE (56) Elastic (83) Elasticsearch (115) elements (80) Failover (104) GQI (159) HTTP (76) IDP (74) LCA (152) low code app (166) low code apps (93) lowcodeapps (75) MySQL (53) protocol (203) QAction (83) security (88) SNMP (86) SRM (337) table (54) trending (87) upgrade (62) Visio (539) Visual Overview (345)
Privacy Policy • Terms & Conditions • Contact

© 2025 Skyline Communications. All rights reserved.

DOJO Q&A widget

Can't find what you need?

? Explore the Q&A DataMiner Docs

[ Placeholder content for popup link ] WordPress Download Manager - Best Download Management Plugin