Uipath Platform Environment setup

orchestrator
how-to

#1

Hi Folks,

         I don't have a much knowledge on UiPath environment setup, please could you help me regarding the Orchestrator server. We are installing the UiPath orchestrator on Aws environment, so how the auto-scaling works on this cloud. Does it supports ?

#2

Maybe someone else could speak to it in more detail.

A few months back I set up a simple infrastructure for UiPath using AWS Cloudformation.

It consists of RDS for the SQL Server, an EC2 instance for Orchestrator (2018.3.1) Platform, and multiple EC2 instances for each robot, with a partially built custom AMIs for Orchestrator and Robot and a bit of Cfn-Init scripting for some of the software installation and environmental configuration changes.

Originally I did have a Network Load balancer in front of Orchestrator with the eventual plan to have a balanced node with Redis to keep the master and slaves in sync, but this complicated the deployment with Cloudformation due to the installation steps of Orchestrator and the changes required to make to set up the additional slave instances.

As we don’t currently have a need for additional nodes (Running very minimal robots at the moment), I removed the NLB and Redis from the design to meet timelines.

Out of curiosity, what is your scenario where you would want to have auto-scaling for the Orchestrator nodes and/or Robots?

From what I’ve learned so far, it would be a matter of creating some deployment/build scripts, probably prepare some custom AMIs (Either one for Master and one for the slaves, or a common AMI that would make the required configuration changes programmatically) to minimize the bootup time required by the auto-scaling group.


#3

Thanks for your response.

We would like to use EC2 auto scaling for Orchestrator and Robots both, for robots it will work i know, but for orchestrator i don’t know if it will work or not. I want to auto scaling for HA.

I have one more query if you can help that will be great which is related to ElasticSearch (ES).
Suppose during the initial installation i don’t use ES, but can we transfer logs from SQL server to ES later. I think that is possible to do it using scripting (bulk upload) but not sure.


#4

I think technically it would be possible the challenges that I see (and this may be from the little time I’ve spent thinking about it) are:

Depending on how you want to prepare an EC2, create custom AMI manually or using something like Packer.io to configure as much as possible to reduce the initialisation of a new instance when it matters

Robots

  • Dynamically Add/Remove Machines/Robots on provisioning and terminating instances, straight forward, and a few ways to go about it
  • Still, need to add the robot to an Environment. Different scaling groups per environment perhaps? With a Minimum of 1 and increase the maximum as you need more.
  • I’ve thought about a job schedule monitor to scale down to 0 and spin something up 10-30 minutes before the scheduled job and shortly after a period of non-schedules, would be neat, mostly from a cost-saving perspective, if you’re running jobs 24/7, this would matter.

Orchestrator

  • Configuration differences between the master and slave would need to have separate AMIs for this or script the init to account for it depending on what is needed.
  • If cost isn’t a concern would it be worth placing in an auto-scaling group? Could spin up multiple instances in a cluster behind a load-balancer or separate clusters in a primary/secondary setup behind the LBs.
  • We only have 10 unattended robots, and not all of them are in use at this time, so having multiple nodes isn’t an immediate concern in the near future.

Re: Loading past logs into ES, I imagine is possible, haven’t used ES myself before but I don’t see why not! We use Splunk in its place as we already use Splunk across the organization.

We send out logs Robot > Orchestrator, NLog is configured to direct to SQL and a file (JSON format), CloudWatch monitors the logs (File, and Event Viewer), which in turn is subscribed to Firehose. Firehose sends the logs over to a Lambda (Node.js) which transforms the events into a format accepted by a Splunk HEC, sends it back to Firehose which then sends it over to Splunk.

There is an NLog plugin for Splunk that would simplify this, but I haven’t tested it and by using Firehose if we ever decide to move away from Splunk, it would be a simple adjustment at one point in the chain to make.

+-------+    +------------+
| Robot +--->+Orchestrator|
+-------+    +------------+  +------+       +----------+
                     |NLog+->+ FILE <------->CloudWatch|
                     +-+--+  +------+       +-----+----+
                       |                          |
                       |                          |
                       |                     +----v---+          +------+
                       v                     |Firehose+---------->Splunk|
               +----------+                  +----^---+          |  HEC |
               |SQL Server|                       |              +------+
               |   RDS    |                       |
               +----------+                   +---v--+
                                              |Lambda|
                                              +------+

#5

@twhitehead - Thanks for these details. I had a question on how the robot licensing works when the robots are auto-scaled? How do you register/deregister the bots from Orchestrator so that the available licenses are used appropriately?


#6

I would defer to the documentation or support to talk about licensing. But there is no difference between manually spinning up a Robot or using Auto-scaling in terms of licensing, it just how you’re turning up the host and managing your robot service.

We leverage the Orchestrator API, so far have only implemented the Registration of a machine and robot upon creation of a new host. So it’s a two-part process, one is running the uirobot.exe with the connectstring parameter which we handle during the cfn-init step of our Cloudformation, and the other piece is to call the API to create a machine and create a robot record which we have worked into the pipeline via Powershell during the Robot stack creation.

We still need to work out the deregistration process, which includes removing the Robot and Machine record from Orchestrator as well as the host from the domain upon termination, but it’s not a priority at the moment and we’ve only had to do it once manually.

https://orchestrator.uipath.com/v2018.4/reference#api-references
https://platform.uipath.com/swagger/


#7

Hi Twhitehead,

Can you please help me in configuring splunk with orchestrator.
How we can monitor real time logs of orchestrator using splunk?


#8

Hi @shweta_B,

I’m happy to try and answer any questions that you may have, but I would ask that you post a new question/thread so not to be off-topic to the original post of this one.

Feel free to ping or PM me the new post.

Cheers,
Tim