# Setting regions is not working

**URL:** <https://forums.foundationdb.org/t/setting-regions-is-not-working/4688>\
**Category:** Using FoundationDB\
**Created:** [November 8, 2024, 7:45am UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688 "2024-11-08T07:45:45Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![peroket](https://avatars.discourse-cdn.com/v4/letter/p/3be4f8/32.png) [@peroket](https://forums.foundationdb.org/u/peroket)\
**Post date:** [November 8, 2024, 7:45am UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/1 "2024-11-08T07:45:45Z")

</div>

Hello,

I am running a FoundationDB cluster from scratch with version 7.3.43. I am trying to set up regions, but it seems there is a bug, and it doesn’t work, or at least I can’t understand what I am missing. I followed the steps described in the doc [Configuration — FoundationDB OFF documentation](https://apple.github.io/foundationdb/configuration.html?highlight=regions#configuring-regions), but when I try to set the first region configuration, I keep getting a `ERROR: Unknown option`.

Here is the full file I am giving to the `fileconfigure` command (enough to trigger the error):

```auto
{
"regions":[{
    "datacenters":[{
        "id":"dca",
        "priority":1
    }]
}]
}

```

All my processes have the dcid set, I really can’t see anything I’m doing wrong.  
Any help is appreciated.

Regards.

---

<div class="post-metadata">

**Author:** ![peroket](https://avatars.discourse-cdn.com/v4/letter/p/3be4f8/32.png) [@peroket](https://forums.foundationdb.org/u/peroket)\
**Post date:** [November 8, 2024, 9:17am UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/2 "2024-11-08T09:17:03Z")

</div>

Trying with the `configure` command in fdbcli to two regions, it accepts the new configuration, and says it was applied, but it then tells me that to increase `usable_regions` would result in an invalid config, and when typing `status json` there is no field for “regions” at all.

So it’s not behaving as expected even this way.

---

<div class="post-metadata">

**Author:** ![peroket](https://avatars.discourse-cdn.com/v4/letter/p/3be4f8/32.png) [@peroket](https://forums.foundationdb.org/u/peroket)\
**Post date:** [November 8, 2024, 3:15pm UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/3 "2024-11-08T15:15:17Z")

</div>

Tried to reproduce on 7.1.61, but there it seems to work as expected

---

<div class="post-metadata">

**Author:** ![4ac513ed5cc72111d641](https://avatars.discourse-cdn.com/v4/letter/4/3d9bf3/32.png) [@4ac513ed5cc72111d641](https://forums.foundationdb.org/u/4ac513ed5cc72111d641)\
**Post date:** [November 18, 2024, 3:02pm UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/4 "2024-11-18T15:02:38Z")

</div>

Hey, i just want to say im observing the exact same behavior as you did.  
My plan next was to try when 7.3 was officially declared stable.

---

<div class="post-metadata">

**Author:** ![peroket](https://avatars.discourse-cdn.com/v4/letter/p/3be4f8/32.png) [@peroket](https://forums.foundationdb.org/u/peroket)\
**Post date:** [November 18, 2024, 3:17pm UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/5 "2024-11-18T15:17:53Z")

</div>

Isn’t it stable already? 7.3.43 is the recommended version on their GitHub.

---

<div class="post-metadata">

**Author:** ![4ac513ed5cc72111d641](https://avatars.discourse-cdn.com/v4/letter/4/3d9bf3/32.png) [@4ac513ed5cc72111d641](https://forums.foundationdb.org/u/4ac513ed5cc72111d641)\
**Post date:** [November 19, 2024, 12:17am UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/6 "2024-11-19T00:17:24Z")

</div>

I think the official stable is still 7.1 , this is what the documentation defaults to when you access the documentation site. Im not 100% sure though.

---

<div class="post-metadata">

**Author:** ![MarkSh1](https://sea1.discourse-cdn.com/foundationdb/user_avatar/forums.foundationdb.org/marksh1/32/1789_2.png) [@MarkSh1](https://forums.foundationdb.org/u/MarkSh1)\
**Post date:** [November 27, 2024, 2:59pm UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/7 "2024-11-27T14:59:31Z")

</div>

I fixed it in

> <https://github.com/apple/foundationdb/pull/11806>
>
> When executing the command "fdbcli --exec 'fileconfigure..." the error message "…ERROR: unknown parameter" is displayed.
> The error occurred in
> ConfigurationResult buildConfiguration(std::vector const& modeTokens, std::map\<std::string, std::string\>& outConf);
> since the vector of modeTokens included reference to an empty string that got into the vector in the function
> ConfigurationResult buildConfiguration(std::string const& configMode, std::map\<std::string, std::string\>& outConf);
> since the configMode begins from empty string which added in
> std::string DatabaseConfiguration::configureStringFromJSON(const StatusObject& json)

---

<div class="post-metadata">

**Author:** ![dgulino](https://avatars.discourse-cdn.com/v4/letter/d/b3f665/32.png) [@dgulino](https://forums.foundationdb.org/u/dgulino)\
**Post date:** [July 28, 2025, 2:39pm UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/8 "2025-07-28T14:39:04Z")

</div>

Running 7.3.69, I get `ERROR: Unknown option` when I run `fdbcli --exec 'fileconfigure region.json'` - it seems no matter what I put in region.json (as long as it’s valid json - invalid json will output a different error). I downgraded to 7.1.57 and the same region.json file loads without error.

Here’s an example region.json:

```auto
{
  "regions": [
    {
      "datacenters": [
        {
          "id": "dc1",
          "priority": 1
        }
      ]
    }
  ]
}
```

---

<div class="post-metadata">

**Author:** ![MarkSh1](https://sea1.discourse-cdn.com/foundationdb/user_avatar/forums.foundationdb.org/marksh1/32/1789_2.png) [@MarkSh1](https://forums.foundationdb.org/u/MarkSh1)\
**Post date:** [August 19, 2025, 12:30pm UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/9 "2025-08-19T12:30:58Z")

</div>

Fix is only uploaded to the main branch

---

<div class="post-metadata">

**Author:** ![mjurkus](https://sea1.discourse-cdn.com/foundationdb/user_avatar/forums.foundationdb.org/mjurkus/32/2062_2.png) [@mjurkus](https://forums.foundationdb.org/u/mjurkus)\
**Post date:** [November 28, 2025, 12:33pm UTC](https://forums.foundationdb.org/t/setting-regions-is-not-working/4688/10 "2025-11-28T12:33:59Z")

</div>

I encountered the same issue in 7.3.71, but not in 7.4.5  
Even though I see that it had to be included in the release. Am I missing something?  
Cherry-pick to 7.3 release - [fix "Unknown error" when configuring regions (#11806) [release-7.3] by MarkSh1 · Pull Request #12313 · apple/foundationdb · GitHub](https://github.com/apple/foundationdb/pull/12313)

Cherry pick to 7.4 release - [fix "Unknown error" when configuring regions (#11806) [release-7.4] by MarkSh1 · Pull Request #12314 · apple/foundationdb · GitHub](https://github.com/apple/foundationdb/pull/12314)
