# Is it possible for two OneAgents to coexist on one host?

**URL:** <https://community.dynatrace.com/t/is-it-possible-for-two-oneagents-to-coexist-on-one-host/39815>\
**Category:** Open Q&A\
**Tags:** installation, oneagent, hosts-classic\
**Created:** [May 18, 2023, 9:37pm UTC](https://community.dynatrace.com/t/is-it-possible-for-two-oneagents-to-coexist-on-one-host/39815 "2023-05-18T21:37:27Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![soportetr](https://avatars.discourse-cdn.com/v4/letter/s/c6cbf5/32.png) [@soportetr](https://community.dynatrace.com/u/soportetr)\
**Post date:** [May 18, 2023, 9:37pm UTC](https://community.dynatrace.com/t/is-it-possible-for-two-oneagents-to-coexist-on-one-host/39815/1 "2023-05-18T21:37:27Z")

</div>

Is it possible for two OneAgents to coexist on one host?

We have a customer that has Tenant A and a Tenant B was created for them.

The customer requires that the servers that are viewed on Tenant A, be viewed on Tenant B.

Is it possible to install a second agent on those servers, or is there an alternative to migrate all that data to the other tenant?

Thanks in advance

---

<div class="post-metadata">

**Author:** ![AntonioSousa](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/antoniosousa/32/50_2.png) [@AntonioSousa](https://community.dynatrace.com/u/AntonioSousa)\
**Post date:** [May 18, 2023, 10:00pm UTC](https://community.dynatrace.com/t/is-it-possible-for-two-oneagents-to-coexist-on-one-host/39815/2 "2023-05-18T22:00:25Z")

</div>

Two OneAgents on one host is not possible.

---

<div class="post-metadata">

**Author:** ![Mohamed\_Hamdy](https://avatars.discourse-cdn.com/v4/letter/m/7ab992/32.png) [@Mohamed\_Hamdy](https://community.dynatrace.com/u/Mohamed_Hamdy)\
**Post date:** [May 18, 2023, 10:08pm UTC](https://community.dynatrace.com/t/is-it-possible-for-two-oneagents-to-coexist-on-one-host/39815/3 "2023-05-18T22:08:04Z")

</div>

Hi&nbsp;[@soportetr](https://community.dynatrace.com/user/41008),

it’s not possible to install two&nbsp;OneAgents on the same host, however, you can use [oneagentctl](https://www.dynatrace.com/support/help/shortlink/oneagentctl)

and in your case, you will be using [OneAgent communication settings](https://www.dynatrace.com/support/help/shortlink/oneagentctl#set-oneagent-communication-settings)

the following is an example:

Linux or AIX:  
./oneagentctl --set-server=[https://my-server.com:443](https://my-server.com:443) --set-tenant=abc123456 --set-tenant-token=abcdefg123456790 --set-network-zone=\<network-zone\> --set-host-group=\<host-group\> --restart-service

Windows:  
.\oneagentctl.exe --set-server=[https://my-server.com:443](https://my-server.com:443) --set-tenant=abc123456 --set-tenant-token=abcdefg123456790 --set-network-zone=\<network-zone\> --set-host-group=\<host-group\> --restart-service

note: you need to restart the monitored processes and based on a case that I have faced, I think it will be recommended to restart the server.

---

<div class="post-metadata">

**Author:** ![SureshThakur](https://avatars.discourse-cdn.com/v4/letter/s/7c8e57/32.png) [@SureshThakur](https://community.dynatrace.com/u/SureshThakur)\
**Post date:** [May 19, 2023, 1:29pm UTC](https://community.dynatrace.com/t/is-it-possible-for-two-oneagents-to-coexist-on-one-host/39815/4 "2023-05-19T13:29:32Z")

</div>

Hi,

I agree with&nbsp;[@Mohamed\_Hamdy](https://community.dynatrace.com/user/4007)&nbsp;last comment of restart of server. I too faced this; and recommend restarting the server.

note: you need to restart the monitored processes and based on a case that I have faced, I think it will be recommended to restart the server.

---

<div class="post-metadata">

**Author:** ![fstekelenburg](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/fstekelenburg/32/22029_2.png) [@fstekelenburg](https://community.dynatrace.com/u/fstekelenburg)\
**Post date:** [September 26, 2023, 8:44am UTC](https://community.dynatrace.com/t/is-it-possible-for-two-oneagents-to-coexist-on-one-host/39815/5 "2023-09-26T08:44:42Z")

</div>

I (and&nbsp;[@MartijnA](https://community.dynatrace.com/user/59430)) wonder: on Linux (where suchs things are possible), what will happen if you install a second agent in another path. My hypothesis (not tested) is, that the 2nd install does not spot the 1st install nor its configuration, and will come a long way. It’s the things like service (start) name configuration and watchdog part where things will become complicated.

Bottom line, kids do no try this at home 🙂
