# My journey to install NaturalOne CE on Win11 with Docker Desktop in 2023

**URL:** <https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290>\
**Category:** Forum\
**Tags:** Adabas-Natural, Adabas, Natural, NaturalONE, docker\
**Created:** [August 20, 2023, 2:00am UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290 "2023-08-20T02:00:43Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![sr.generoso](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/sr.generoso/32/29240_2.png) [@sr.generoso](https://techcommunity.softwareag.com/u/sr.generoso)\
**Post date:** [August 20, 2023, 2:00am UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/1 "2023-08-20T02:00:43Z")

</div>

#### \ ***Product/components** used and **version/fix** level:

[Guide](https://softwareag-usa.s3.amazonaws.com/Adanat_Docker/AN+Community+Edition+Guide.pdf) Adabas & Natural Commuinity Edition for Docker Oct2022 V2.5

## Pre:

I know about Natural because a friend use it at work. They need programmers so I’m trying to learn it. I had the topics “[Natural](https://en.wikipedia.org/wiki/ADABAS#Natural_(4GL))” and “[Adabas](https://en.wikipedia.org/wiki/ADABAS)” which led me to “[SoftwareAG](https://en.wikipedia.org/wiki/Software_AG)”  
And, here is my first challenge. The company my friend work with use Natural, not NaturalOne, although there is movement and most probably they start using NaturalOne in the near future (maybe), but… what are the [differences](https://techcommunity.softwareag.com/t/differences-of-the-natural-for-windows-and-naturalone/100917)?  
In any case, I went to discover what [SoftwareAG](https://www.softwareag.com/en_corporate.html) had available and I was quite impressed. In one hand I had this forum([TechCommunity](https://techcommunity.softwareag.com/)) but in the other I had the [resources center](https://developer.softwareag.com/en/learning-resources.html) with an awesome [learn](https://learn.softwareag.com/totara/catalog/index.php) platform.  
So many courses and levels, inmediatly I went to [Adabas & Natural](https://learn.softwareag.com/totara/catalog/index.php?cfp_multiselect_platformplatfor_8daf9%5B%5D=Adabas%20%26%20Natural&cfp_multiselect_coursetypecours_1cd30%5B%5D=1.%20Basic&orderbykey=time&itemstyle=wide) and filter by basics courses and enroll in the  
[NaturalONE Basic (E310A-75E)](https://learn.softwareag.com/course/view.php?id=1470) course.  
But here is the problem, I don’t have Adabas or Natural installed. Mmm, let’s check the [free trial](https://techcommunity.softwareag.com/en_en/downloads.html) section of the web. Hey! [here](https://techcommunity.softwareag.com/t/adabas-natural-community-edition-for-docker-download/235228) it is. I would like to know wich means being a trial. Is time limited? Are some functionalities removed? You can find that in the readme of the [dockerhub](https://hub.docker.com/u/softwareag)  
For Adabas

> The container does not contain any licenses for Adabas. The restrictions of an Adabas community edition are:
> 
> - No Adabas PLOG usage
> - Restrictions in an Adabas in Enterprise environment with a huge number of CPUs
> - Restrictions in the Adabas container size

For Natural

> To agree to the Software AG copyright EULA, you need to set the environment variable ACCEPT\_EULA during Natural container startup.

For Adabas Manager

> - No Adabas PLOG usage. To start a database, you need to set the PLOG to ‘NO’ from the Database Parameter page.

Anyway. Let’s get rolling.  
Alright, I fill the form and redirects me to this “[What’s next](https://techcommunity.softwareag.com/pub/thank-you-for-downloading-adabas-natural-community-edition-for-docker)” article. Ok…, it has links to enroll in the course I’ve already sign up for, links to [examples](https://github.com/SoftwareAG/adabas-natural-code-samples) on github, cool…, Oh, here it is, a [guide](https://softwareag-usa.s3.amazonaws.com/Adanat_Docker/AN+Community+Edition+Guide.pdf) for installing it…, but install what? ooohhhh, nvm, [here](https://softwareag-usa.s3.amazonaws.com/Adanat_Docker/ONE.9.2.1.CE.zip) is the link for downloading it. Is the version 9.2.1. Alright. I think I have it. Now to the guide.

## Install of NaturalOne 9.2.1

### 1 Welcome

Ok, it tells me that I’ll install the IDE app based on eclipse, and 3 docker containers.

### 2 Architecture Overview

Ok, the dev enviroment is NaturalOne Which connects over TCP/IP to Natural in docker, which then connects to Adabas in another container and finally there is Adabas Manager that connects to Adabas directly. So… we as developers only can connect to Natural throgh NaturalOne and to Adabas through Adabas Manager.

### 3 Getting Started.

> For NaturalONE, Natural, Adabas and Adabas Manager, an installation in the classical sense is not  
> required.
> 
> 1. Install the Docker Community Edition or Podman.
> 2. Start Adabas in a Docker container.
> 3. Start Natural in a Docker container.
> 4. Download and unpack NaturalONE.
> 5. Start Adabas Manager in a Docker container.

### 4 Installing the Docker Community Edition

Jump to 4.2, windows 10/11  
Install [docker desktop](https://docs.docker.com/desktop/install/windows-install/) I already have it.  
Now run `ipconfig` on powershell and look for the IPv4 address of your main adapter. I’m on wifi,so should I copy that one?  
There are also `Ethernet adapter vEthernet` which is the adapter for Hyper-V and `Ethernet adapter vEthernet (WSL)` which is used for well, WSL. I’ll copy the main one as the guide says. This IP is very important as we need it later to connect to the dev enviroment and the database.

### 5 Login to Docker Hub / Software AG Registry

Alright, we need to pull 3 images.  
`docker pull softwareag/natural-ce:9.2.1`  
`docker pull softwareag/adabas-ce:7.1.1`  
`docker pull softwareag/adabasmanager-ce:9.1.0.1`  
Done.  
The guide shows also how to use an empower account to download images from their repository but I’m not a client yet, so omit that.

### 6 Starting Adabas in a Docker Container

Here we go, first it tolds as that the database is not persisted but there is more info in the readme in [dockerhub](https://hub.docker.com/r/softwareag/adabas-ce).

Now the good part. This is the command to run Adabas in docker

`docker run -d -p 60001:60001 -p 8190:8190 -e ACCEPT_EULA=Y -e ADADBID=12 -e "ADA_DB_CREATION=demodb" --name adabas-db softwareag/adabas-ce:7.1.1`

alright, is running and logs are looking ok. Since I use Docker Desktop I can see the logs, otherwise, `docker logs adabas-db`

We can also check if the database is working properly with  
`docker exec -it adabas-db adainfo.sh`, and… everything looks fine as shown in the guide.

### 7 Starting Natural in a Docker Container

Round 2, let’s see if Natural goes smooth as well.  
`docker run -d -p 2700:2700 --add-host adabas-db:<OWN-IP> -e ACCEPT_EULA=Y --name natural-ce softwareag/natural-ce:9.2.1`

mmm, be careful, now we have to remember to set our own IP in that command. Since it’s a local ip I think is not a security issue to share it here. I’ll choose the one of my main adapter, I’ll see later if that’s correct.

`docker run -d -p 2700:2700 --add-host adabas-db:192.168.1.36 -e ACCEPT_EULA=Y --name natural-ce softwareag/natural-ce:9.2.1`

Alright. It’s up and running. Let’s continue.

### 9 Quick Start Guide for NaturalONE

Is time now to unzip the [NaturalONE](https://softwareag-usa.s3.amazonaws.com/Adanat_Docker/ONE.9.2.1.CE.zip) IDE and run it using the `Start_ONE_9.2.1.CE` shortcut. I’ll use the default workspace for now. It says it uses Software AG Designer v10.15

### 10 Establishing the Connection between NaturalONE and the Natural Container

Now I loaded the Hello World example but I need to connect to the natural container. Let’s see, Right click on the natural navigator view (selecting the main folder) and then `Natural/Runtime`  
Here we have to change the host which is defaulted to localhost. Is the same IP we used to connect to the database? I hope so.  
It says that we have the natural demo application in the container so we should be able to run it as shown in the guides. And…, error. well, it says `NAT0082 Invalid command, or Object HELLO-P does not exist in library.` but it seems like is connecting to the container. I’ll look in that later.

### 11 Starting Adabas Manager in a Docker Container

Again, let’s see if this container works.  
`docker run -d -p 4990:4990 -e ACCEPT_EULA=Y --name adabas-manager softwareag/adabasmanager-ce:9.1.0.1`  
Up and runnings, logs are there and I should be able to access it through. `https://localhost:4990/` Important to make use of the https. Now I can login using admin:manage as credentials. And it works.  
Now we can add our Adabas instance to manage it. I follow the screenshots and use again admin:manage to enter that db

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/2/8/28fc0c5213a3d4c6d125bfa26b84914814bb0ccd.png)  
(I didn’t know the pass was that) and apparently there is a database whit some files which includes employes, vehicles… it seems that connections is working.

So, that’s the guide.

Now let’s try find what was that error.

## Troubleshotting

I can connect from eclipse to natural. The thing is, I understand that adabas manager is able to connect to adabas since it run in the same docker vm, but I need to see how natural-ce is exposed to the computer.  
First, in powershell. `docker ps` I can see there 3 containers are running and their ids. I copy the one from natural-ce.  
Next, `docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' 212ec3ec3b33` being `212ec3ec3b33` the id taken from the ps command.

Wait, it gives me IP `172.17.0.3` but I try it ine the runtime config and doesn’t work.  
Let’s see if something is running on that port  
`Get-NetTCPConnection | where Localport -eq 5000| Select-Object Localport,@{'Name' = 'ProcessName';'Expression'={(Get-Process -Id $_.OwningProcess).Name}}`  
it outputs  
`Localport ProcessName

* * *

```
 2700 wslrelay
 2700 com.docker.backend`

```

Mmm, is something.  
I run `netstat -aon` and I see there is something listening on 0.0.0.0:2700  
It may be ok, apparently is similar to localhost and 127.0.0.1 but still I’m going to change it on eclipse runtime configuration to see if it works. Again error `NAT0082 Invalid command, or Object HELLO-P does not exist in library.`

## Getting there

May be an error on the hello-p.nsp? It says in the guide that the container should have this library already loaded.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/1/1/11008cb99edc1951d37635614f9c585f76be1bd9.png)  
I’m going to build the project and upload it to the server to see any change.

* * *

Hey, another error, but it’s different, that’s progress.  
`SEVERE PROBLEM: The JS-Iibraries required by this page could not be loaded. This problem typically occurs when not having regenerated the layout definitions.`  
At least there is already a topic in this forum about [this](https://techcommunity.softwareag.com/t/naturalone-community-edition-error-when-running-hello-world-sample-application/274851)  
Ok, rebuild the sample component…

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/a/4/a4ae8275d412a1512b2210cabb7a9396df8132ae.png)  
run it again and…  
 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/2/8/28b3c83a3b90d7f62a36cda8bb96a524241c67d9.png)  
Hello world… and Adabas as well!  
 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/8/2/820979f2689d466ce2c8ebcdefcf06728ba35c53.png)

# Stepping back

so, I’ll go back to the runtime configuration and change it to localhost as that doesn’t seem to be the problem.  
Also, I’m going to redo the steps to launch the containers, but this time I’m going to change the docker commands to see if localhost would have work instead of the ip copied from the ethernet adapter.

So, first adabas  
`docker run -d -p 60001:60001 -p 8190:8190 -e ACCEPT_EULA=Y -e ADADBID=12 -e "ADA_DB_CREATION=demodb" --name adabas-db softwareag/adabas-ce:7.1.1`  
then natural with the localhost ip  
`docker run -d -p 2700:2700 --add-host adabas-db:<YOUR-IP> -e ACCEPT_EULA=Y --name natural-ce softwareag/natural-ce:9.2.1`  
and finally the manager  
`docker run -d -p 4990:4990 -e ACCEPT_EULA=Y --name adabas-manager softwareag/adabasmanager-ce:9.1.0.1`

Unpack the NaturalONE Eclipse IDE, change the runtime

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/6/6/666e46b95d4f3bffc4ad32af1c65ee9fe3521b0d.png)

Since I’ve deleted the containers I have to build and upload it first

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/c/9/c93098c656fdd3abbf4da839e25fee8e03e7ad26.png)  
and for good measure I’ll rebuild the user interface  
 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/d/4/d433999204cd6c1b8226ab7a9a98412d465a9355.png)

And there you have it. A ready to use dev enviroment.  
One last thing. I’m going to create a docker-compose.yml to be able to run everything at the same time with `docker compose up`

#### \*Spoiler from the future - a couple of post down I show you don’t need extra-hosts.

> **docker-compose.yml**
>
> version: ‘3.3’  
> services:  
> adabas-ce:  
> ports:  
> - ‘60001:60001’  
> - ‘8190:8190’  
> environment:  
> - ACCEPT\_EULA=Y  
> - ADADBID=12  
> - ADA\_DB\_CREATION=demodb  
> container\_name: adabas-db  
> image: ‘softwareag/adabas-ce:7.1.1’  
> natural-ce:  
> ports:  
> - ‘2700:2700’  
> extra\_hosts:  
> - ‘adabas-db:’  
> environment:  
> - ACCEPT\_EULA=Y  
> container\_name: natural-ce  
> image: ‘softwareag/natural-ce:9.2.1’  
> adabasmanager-ce:  
> ports:  
> - ‘4990:4990’  
> environment:  
> - ACCEPT\_EULA=Y  
> container\_name: adabas-manager  
> image: ‘softwareag/adabasmanager-ce:9.1.0.1’

And it works!!, kind of. First think I noticed. You can setup the runtime in eclipse to localhost, but, be sure the user ID is not admin.  
Second, in the adabas manager you need the real ip of the container, I mean, the one used internally by docker. One way to find it is using Portainer in Docker Desktop.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/a/7/a7b090a27f0f420163115a1efa612150de0f01e7.png)  
With that you can run all containers and use the IDE.  
Time to follow the course!!

### Final Thoughts.

Please don’t follow this guide step by step, it was my journey, a conflicted one, I’ll leave it as may help others, please report if you see any errors or feel like I should add something.

---

<div class="post-metadata">

**Author:** ![Eugene.Miklovich](https://avatars.discourse-cdn.com/v4/letter/e/ce73a5/32.png) [@Eugene.Miklovich](https://techcommunity.softwareag.com/u/Eugene.Miklovich)\
**Post date:** [August 20, 2023, 2:53pm UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/2 "2023-08-20T14:53:06Z")

</div>

In simple terms NATURAL ONE and NATURAL are the same with respect to the language statements.

What is different is the development environment.

NATURAL is an IDE (Integrated Development Environment), so while the language statements are the same to build programs the tools are different.

NATURAL ONE development tools are under ECLIPSE, whereas NATURAL tools (like the editors) are primarily character based under appropriate OS (e.g. zOS or LINUX).

Hope that helps…

Eugene (Gene) Miklovich

ADABAS/NATURAL Systems Support and DBA

Cell: 916-202-7047

Normal Hours: 8am-4pm E.T.

Please call or text if assistance needed outside these hours.

---

<div class="post-metadata">

**Author:** ![Eli\_Cohen1](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/eli_cohen1/32/39733_2.png) [@Eli\_Cohen1](https://techcommunity.softwareag.com/u/Eli_Cohen1)\
**Post date:** [August 21, 2023, 12:42pm UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/3 "2023-08-21T12:42:17Z")

</div>

Hello Alfonso,

This is very interesting research you did.  
Our developers portal for all resources is available on this link.  
[Software AG Developer Center](https://developer.softwareag.com/en.html#adabas-natural)  
Feel free to use our platforms for any questions / challenges you will have.

Good Luck with your journey!

Eli

---

<div class="post-metadata">

**Author:** ![sr.generoso](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/sr.generoso/32/29240_2.png) [@sr.generoso](https://techcommunity.softwareag.com/u/sr.generoso)\
**Post date:** [August 21, 2023, 2:10pm UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/4 "2023-08-21T14:10:50Z")

</div>

## PART 2: Creating a new database

> **TLDR**
>
> There are some parameters that had to be changed.  
> Pools and Queues  
> → Number of threads - NT = 3  
> → User Queue Size - NU = 5  
> -\>Length of Adabas Work Pool - LWP = 1  
> Logging  
> -\>Protection Logging - PLOG = NO  
> Remote Database Access  
> → TCP/IP receiver Port Number - PORTNUMBER = 60001

I’ve finished the [Natural Programming Basic](https://learn.softwareag.com/course/view.php?id=1467) and I’m now in the [Adabas Basic](https://learn.softwareag.com/course/view.php?id=1562) course.

In Part 1 there is a practice part where you have to create a database in Adabas Manager.

I create the database as shown in the video (although they use a VM with everything pre-installed)

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/d/b/dba58f5cdcac007bd74609fe203bf0297fa3e619.png)

and is created correctly, but it fails to start up

```auto
[db] [400_ADA_REST_ERR] Fail to start Database 24.: AIF00651
Failed to launch ADASTART for /api/adabas/database/24:start: 400 Bad Request

```

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/4/5/455fc4771d61b372e96f12893399dd14875d8d22.png)

I check both database, the one originally created during the container startup and the one I just created.  
Everything has the same values, but apparently the TCP/IP receiver port number is `49152` by default in the new database

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/1/1/113097ee06362dc40a5987e2f0d73bd2e4b1ed30.png)

Easy peasy, let’s change that. Click on the parameter `PORTNUMBER` highlighted in blue and change it to 60001, then save.

Let’s try again… No dice.

Maybe that port is already in use? I’ll try to stop the other db and try again.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/7/f/7f0c1dfdfe789458cc0dd2b950705b684037bf1c.png)  
Mmmm, different error this time. Wait a minute, the docker container has stopped! I started again and try to start the original db. Ok, that one starts up. But my db doesn’t start.

Let’s look around. The logs in Adabas-ce container tells me that ADASTART fails to launch. Also, if you read the logs carefully, you can see that during the container startup it creates the demo db but then applies restrictions due to license

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/3/9/391a54636d3cefee277ed23e748bca5ea5d1b441.png)

and looking into the parameters of both databases the parameters are the same, let’s change that.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/9/1/917775c940019c6290d465db5cbb5a349992369e.png)

Numbers of threads - NT and User Queue Size - NU are straightforward.  
Change those values to 3 and 5 respectivly, but, Length of Adabas Work Pool - LWP doesn’t match directly. It says 16 in the manager but 167216 in the logs… The paramater in the manager is shown in MB while the logs shows the binary value. So…, 16MB is allow for the demo DB but new ones should be restricted to 10MB, let’s try that.

Close, but fails again. Let’s check the logs.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/0/0/00e796ab7d944898d955d38565d581854552b262.png)

🤦🏻ok, it’s not 10mb, it’s 1mb… Let’s change that and try again.

We’re getting there! Still failed but we have correctly passed the LWP.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/2/4/244fc70804e322c0b04311150fad641d7d9c2601.png)

Now it’s about PLOG - Protecction Logging. Let’s disable that

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/2/4/244fc70804e322c0b04311150fad641d7d9c2601.png)

And… Let’s go!! up and running!!

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/8/d/8dea40deddbbb9f5614e9d03086a5893c68cd23a.png)

Ok, this part maybe should be a new post, but since this limitations are related to the community edition I leave it here. Please let me know if I should post it in a new topic.

---

<div class="post-metadata">

**Author:** ![sr.generoso](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/sr.generoso/32/29240_2.png) [@sr.generoso](https://techcommunity.softwareag.com/u/sr.generoso)\
**Post date:** [August 22, 2023, 1:06am UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/5 "2023-08-22T01:06:46Z")

</div>

## Round 2

So here I am again. Problem 1. I restarted a couple of times since instalation but now adabas-ce container can’t start.

```auto
Error invoking remote method 'docker-start-container': Error: (HTTP code 500) server error - Ports are not available: exposing port TCP 0.0.0.0:60001 -> 0.0.0.0:0: listen tcp 0.0.0.0:60001: bind: An attempt was made to access a socket in a way forbidden by its access permissions.

```

Easy fix, first find if something is using it. In powershell or cmd, `netstat`, but I’ve used [TCPVIEW](https://learn.microsoft.com/en-us/sysinternals/downloads/tcpview) which is easier and cooler. Anyway, port was free. Then I found this [post](https://blog.deanosim.net/windows-10-winnat-and-why-your-programs-cant-listen-on-certain-ports/) and used this command  
`net stop winnat`, then try to run the container, yep, cool,  
and then `net start winnat`  
So, that’s solved. (the article also says to add another command to exclude the port, before running the service again. I’ll keep it in mind if it happens again.)

Second problem. This is related to the Adabas course. So… I checked Natural was working and indeed it works, but the hello world example related to database can’t connect to Adabas, it says

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/a/d/ad7b1ed0fa2c3f2acfe6b3f4085ef5209e4de6be.png)  
`EMP-GET 0046 NAT3148 Database 12 not active. Subc O.`  
This means the database is running but not working…  
I change the values of NT / NU / PLOG / LWP as did in the previous post I made, but still not working.  
The logs, still give me some info

```auto
2023-08-22 00:18:04 %ADANUC-I-MISLIC, License file not found - Restrictions for Community Edition apply.
2023-08-22 00:18:04 %ADANUC-I-HAENA, HA synchronisation check enabled
2023-08-22 00:18:04 %ADANUC-I-HANUC, Adabas database 12 request HA access ...
2023-08-22 00:18:04 %ADANUC-I-HASTATE, Sync High availability state: O.K.
2023-08-22 00:18:04 %ADANUC-I-CREATED, dataset NUCTMP1, file /data/db012/NUCTMP1.012 created
2023-08-22 00:18:04 %ADANUC-W-ADATCPLICENSE, WCP license file not found
2023-08-22 00:18:04 %ADANUC-W-ADATCPRECVLIC, Parameter TCPRECEIVER restricted by licensing, changed from 2 to 1
2023-08-22 00:18:04 %ADANUC-W-ADATCPATBLIC, Parameter TCPATB restricted by licensing, changed from 20971520 to 1048576
2023-08-22 00:18:04 %ADANUC-W-ADATCPCONLIC, Parameter TCPCONNECTIONS restricted by licensing, changed from 4294967295 to 4
2023-08-22 00:18:04 %ADANUC-I-ADATCPENAB, Adatcp enabled, listening on port: 60001
2023-08-22 00:18:04 %ADANUC-I-DBSTART, Database 12, session 7 started, 22-AUG-2023 00:18:04

```

May I need to change TCPRECEIVER / ADATCPATBLIC and the others?  
I’m going to experiment a little more. I’ve found this

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/5/0/50e8fa0b482d7b4c2e46c77ea89d9a9b1f40d1b8.png)  
Tools & Utilities. Let’s see if I have something there that could help me.

Alright, there is a tool for showing messages

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/3/7/37b14f4174e4f5e2e878c345c7618b8e9c09a519.png)  
Which is basicly the same as [this docs](https://documentation.softwareag.com/natural/nat426dmf/mc_mf/mcERRN_3101.htm).

Mmm, is a database problem then. It seems like it can’t find it.  
The adabas manager is working properly, but I’ve set it up manually using the ip I got from portainer…  
It may possibly be that, I’m running the containers using docker compose, and I decided to ignore the [guide](https://softwareag-usa.s3.amazonaws.com/Adanat_Docker/AN+Community+Edition+Guide.pdf), in part 4.2 where it says I have to use the ip of my computer instead of localhost.  
Let’s change that.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/a/3/a39ff6eb4f413d63dcc100048429af91b7881e54.png)  
Got the local ip, updated the docker-compose.yaml and… is working.😑  
Always follow the guide… but why… Should I set the ip staticly? I’ll give it some though, meanwhile I’m going to edit the original post to not confuse newcomers.

---

<div class="post-metadata">

**Author:** ![sr.generoso](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/sr.generoso/32/29240_2.png) [@sr.generoso](https://techcommunity.softwareag.com/u/sr.generoso)\
**Post date:** [August 22, 2023, 2:24am UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/6 "2023-08-22T02:24:13Z")

</div>

## Learning about docker networking

I’m reading this [guide](https://www.tutorialworks.com/container-networking/)  
My goal is to create a network connection between the natural-CE container and the adabas-ce container whitout having to set it up manually.  
Right now we do it telling the natural container to add an extra-host when running the container which literally add `192.168.1.36 adabas-db` to the `/etc/hosts/` in the container during initialization. That means, that if we put adabas-db in a browser inside that container we would be able to access the database…, right?

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/8/4/8489b6b24e6e32cc16738d62eda396f3e403d074.png)  
actually it does (forget the 0.0.0.0 adabas-db, is the config I used during this container run (which doesn’t work), it should be the IP I got earlier)  
So, how do I fix it. Let’s go back to the guide.

Apparently docker creates a bridge when it creates container, and every container can see each other, but you need the ip. In adabas manager I can tell him which IP to use because they are already running and I can check for that, but how can I do it programaticly?  
The guide mentions a user-defined bridge. Let’s check the [docs](https://docs.docker.com/network/drivers/bridge/)

Alright, so we can create a new network  
`docker network create my-docker-net`  
and use that network when creating the containers.

```auto
docker run -d -p 60001:60001 -p 8190:8190 -e ACCEPT_EULA=Y -e ADADBID=12 -e "ADA_DB_CREATION=demodb" --name adabas-db --network my-docker-net softwareag/adabas-ce:7.1.1

```

Or connect a running container to that network, I’ll try adabas-manager to test the functionality. To do that I have to add both adabas-db and adabas-manager to the same network  
`docker network connect my-docker-net adabas-db`  
and  
`docker network connect my-docker-net adabas-manager`

Now in theory I should be able to connect adabas manager to adabas using the name of the container as the hostname

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/d/0/d0ae3ddb9d0a0a98d092da3655ae26e0e29a705a.png)  
It worked!!  
 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/d/c/dc924faed0020586890894fcc56742af70b7f350.png)

Alright… let’s think the next step. I should be able to remove the extra host from the natural-ce container and connect it to the same network, right?  
Let’s see how to do that in the docker compose to make it easier.  
Mmm, the docs are [interesting](https://docs.docker.com/compose/networking/)… when you use compose it creates a network by default called the same as the folder where the docker-compose.yaml file is located. Does that mean that I don’t have to add the extra-host in it? Well, that’s should be right if the container name is the same as the host we are adding which is true in this case. Let me check it.  
My theory is… Eclipse connects to natural-ce container through localhost, and natural should be configured to connect to adabas-db using that as a host…

Natural is working…

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/a/2/a259a7bc70b4d815e43e7055a49eade8cb6b6892.png)

and adabas is working too!!!

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/2/7/273eff0e8d22fc680ec8f13e89105e8e6f02c7d7.png)

You don’t need to set the extra-host in docker compose!! So nice!  
But, if you are running the container by themselves you have to create a network and set the network for each container.  
But if you use Docker compose (which looks better and better every time) you can omit a lot and just use the container names as host for connectivity.  
Here is my docker-compose.yaml now

> **docker-compose.yaml**
>
> version: ‘3.3’  
> services:  
> adabas-ce:  
> ports:  
> - ‘60001:60001’  
> - ‘8190:8190’  
> environment:  
> - ACCEPT\_EULA=Y  
> - ADADBID=12  
> - ADA\_DB\_CREATION=demodb  
> container\_name: adabas-db  
> image: ‘softwareag/adabas-ce:7.1.1’  
> natural-ce:  
> ports:  
> - ‘2700:2700’  
> environment:  
> - ACCEPT\_EULA=Y  
> container\_name: natural-ce  
> image: ‘softwareag/natural-ce:9.2.1’  
> adabasmanager-ce:  
> ports:  
> - ‘4990:4990’  
> environment:  
> - ACCEPT\_EULA=Y  
> container\_name: adabas-manager  
> image: ‘softwareag/adabasmanager-ce:9.1.0.1’

Also, for those interested, you can check the configuration of natural in

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/9/2/920688e04334165f138ca185e4f023ffd0c80519.png)

You can see it is preconfigured to map db 12, which is the one loaded with examples and 11, which doesn’t exist at this moment, to the host ADABAS-DB:60001.

I have to keep this in mind for when I create my own database for learning. How can I edit files in UNIX when I don’t have vi installed? Maybe through sh? In any case, case closed for now. Hope it helped somebody. Sorry for being so chaotic, as I said I’m documenting while I’m learning.

---

<div class="post-metadata">

**Author:** ![PA\_Baines](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/pa_baines/32/27977_2.png) [@PA\_Baines](https://techcommunity.softwareag.com/u/PA_Baines)\
**Post date:** [August 22, 2023, 6:52am UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/7 "2023-08-22T06:52:20Z")

</div>

Hi Alfonso.

Thanks for posting your journey. I just wish I’d had this available while I installed NaturalOne on my home pc. The guides and forums aren’t especially helpful but I (finally) got it working.

My problem now is defining a WORK file in my program. Seems simple enough but I keep getting a NAT1599 error. I’m followed the softwareag tutorial here ([Education Community](https://education.softwareag.com/adabas-and-natural/tutorials/work-files-and-string-processing)) which describes a Windows work file, but it can’t find it from the Docker environment. I’ve found various comments on this topic in the forums, but nothing I have tried works.

If you have any advice in regard to file-handling in NaturalOne, I would be grateful if you could provide any help/guidance.

Cheers, Paul

---

<div class="post-metadata">

**Author:** ![sr.generoso](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/sr.generoso/32/29240_2.png) [@sr.generoso](https://techcommunity.softwareag.com/u/sr.generoso)\
**Post date:** [August 22, 2023, 7:11pm UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/8 "2023-08-22T19:11:04Z")

</div>

Hi Paul, I haven’t reached that part yet, but since I’ll stomp on this in the future and I have docker fresh I’m giving it a shot.  
First of all, I’m assuming that in the tutorial they are using Natural installed on windows and therefor there is not much complication to read files.  
Now, using natural-ce in docker, we need to allow the container to read data from an external folder… in the past I’ve used “volumes” to allow that behavior.  
Let’s see if that works.  
Before that, I’m going to try to run the program without changing anything to try to replicate your problem.  
I’ll download the `cruise.csv` into a new folder in `C:\my-files` and edit the program accordingly, build the project, upload it and run it…

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/0/7/079b3e0b0bf74057bc86880fefb47d26627714e6.png)

Ok, that was expected. Then, how do I tell docker where my files are? There are a [few mechanism](https://docs.docker.com/storage/) in docker but I think [Volumes](https://docs.docker.com/storage/volumes/) might be the right choice.  
I’ll try to achieve it with [docker compose](https://docs.docker.com/compose/compose-file/07-volumes/) first as I think is the easiest, but maybe I’ll try later to do it running a single container.  
Please note, and this might be important, there may be differences if you don’t use WSL (Windows Subsystem for Linux) and Docker Desktop.  
I use WSL, I think is an amazing development experience but it has some caveats, mainly configuration and wrapping your head around being a virtual machine as it not feels like one. In any case, I’ll try to make it work on my machine first.

So, what I’m going to do is to add a `Volume` tag to the compose file and reference the path on my machine and the path where I want those files in the filesystem of the container.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/c/6/c60e4eb2eadaba3eea5a1c191a305b4ac8dae575.png)

Ok, easy enough, I had to delete the containers and recreate them, but it seems to work.

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/0/e/0efb022990e1e9099101a20d31643d8453daa43b.png)

Now, the question is, will Natural be able to load that file?  
Since I’ve deleted the containers I have to rebuild and upload the project again.

I’ve check the hello world and both HELLO-P and GET-Em programs are working… 🫠 I had to rebuild a couple times but seems like is working. Anyway, now to check the WORKFPGN program and try to make it work.

The file referenced in the program

```auto
DEFINE WORK FILE 1 'C:\my-files\CRUISE.CSV' TYPE 'CSV'

```

doesn’t makes sense in the container, but, as shown previously, is in `/home` folder, so let’s try that. just change that line.

```auto
DEFINE WORK FILE 1 '/home/CRUISE.CSV' TYPE 'CSV'

```

build, upload and… it’s working!!!

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/0/3/03aeb2e6f761cf2f5f4dd78527c6e517e6dfc273.png)

Now let’s check if I can make changes to the CSV on windows and see those reflected in natural output.

I open the csv on my editor and change the first line

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/5/2/52a2a7fb8b96813bbb51a6e3ee6c97f7d28c90bb.png)

Rerun the program in natural…

 ![image](https://global.discourse-cdn.com/techcommunity/original/3X/1/5/15dc5742b2cf708923af6cd85c93fe8680005112.png)  
and it works as well.

### So… what’s the deal?

Docker Is really sophisticated but not intuitive. A lot of his magic happens in the shadows and sometimes is hard to grasp. This solution may be half baked and probably doesn’t follow best practice, but it works and most probably, if you work in a company somebody with better understanding than me will be the responsible of setting up your dev enviroment.

Also, this solution rely on Docker Desktop and WSL2, which if you think about it is frankly scary (My system is windows, but it has a virtual machine that runs linux (wsl), and then docker run some containers on that virtual machine, to virtualize 3 unix instances which needs to access the files on the original windows system 🤯 ) So much complexity totally abstracted to us.

Now, I hope you understand you have to change the paths to suit your filesystem. Also, if you are not using docker-compose (you probably don’t as the guide don’t mention it at all) you can create those volumes with the -v flag such us

```auto
docker run -d -p 2700:2700 -v /c/my-files:/home --add-host adabas-db:<YOUR-IP> -e ACCEPT_EULA=Y --name natural-ce softwareag/natural-ce:9.2.1

```

haven’t tried that yet, so luck with that.

Also, if you are not using WSL, you may need to reference your local path as you do normally on windows.

```auto
docker run -d -p 2700:2700 -v C:\my-files:/Home --add-host adabas-db:<YOUR-IP> -e ACCEPT_EULA=Y --name natural-ce softwareag/natural-ce:9.2.1

```

I haven’t tried that one either. In fact I’m really scared of changing many configurations in my system since Natural+Adabas is quite the pain to make it work.

Anyway, let me know if you make it work.

---

<div class="post-metadata">

**Author:** ![PA\_Baines](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/pa_baines/32/27977_2.png) [@PA\_Baines](https://techcommunity.softwareag.com/u/PA_Baines)\
**Post date:** [August 23, 2023, 7:48am UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/9 "2023-08-23T07:48:57Z")

</div>

Hi Alfonso,  
This is really helpful, thanks!  
It is my first time using Docker so still getting to grips with it. I don’t have docker compose installed yet so I’ll be trying that next I think.  
I will report back soon if/when I’ve got compose set up and the volumes sorted.  
Cheers, Paul

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [February 19, 2024, 7:49am UTC](https://techcommunity.softwareag.com/t/my-journey-to-install-naturalone-ce-on-win11-with-docker-desktop-in-2023/282290/10 "2024-02-19T07:49:41Z")

</div>

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
