Auxiliary Tools :: My jBPM Network Environment Configuration using VMware Workstation

 

General Information

Network Connections

VMware Workstation provides Bridged Networking (VMnet0), Network Address Translation (NAT; VMnet8), Host-only Networking (VMnet1,…, VMnet9), and custom networking options to configure a virtual machine for virtual networking.

Bridged Networking

With bridged networking, the virtual network adapter in the virtual machine connects to a physical network adapter in the host system. The host network adapter enables the virtual machine to connect to the LAN that the host system uses.

Network Address Translation (NAT)

NAT works by translating the IP addresses of virtual machines in the private network to the IP address of the host system. When a virtual machine sends a request to access a network resource, it appears to the network resource as if the request is coming from the host system.
DHCP server is automatically installed when you install VMware Workstation.
Virtual machines running on the network with the NAT device can dynamically obtain their IP addresses by sending out a DHCP request. The DHCP server on the NAT network, dynamically allocates IP addresses in the range of x.x.x.128 through x.x.x.254, where x.x.x is the network number assigned to your NAT network. IP addresses x.x.x.3 through x.x.x.127 can be used for static IP addresses. IP address x.x.x.1 is reserved for the host adapter; x.x.x.2 is reserved for the NAT device.

Host-only Network

Host-only networking is useful if you need to set up an isolated virtual network. In a host-only network, the virtual machine and the host virtual network adapter are connected to a private Ethernet network. The network is completely contained within the host system. The network connection between the virtual machine and the host system is provided by a virtual network adapter that is visible on the host operating system. The virtual DHCP server provides IP addresses on the host-only network.

DHCP Conventions for Assigning IP Addresses in Host-Only and NAT Networks

IP Address Use on a Host-Only Network:

IP Address Use on a NAT Network:

Virtual Network Structure for jBPM

Network Configuration

I use VMware Workstation 12.5.5 Pro on Windows 10.

VMware Workstation network configuration:

VMs Setup

VMs operating system: Fedora 25 (Fedora-MATE_Compiz-Live-x86_64-25-1.3.iso)

General plan:

pc-1-jboss-kie-server; IP=192.168.195.101

pc-2-jbpm-db; IP=192.168.195.102

pc-3-jbpm-client; IP=192.168.195.103

pc-4-dev; IP=192.168.195.104

For each VM add Host-Only adapter:

After install VM, for each VM:

  1. dnf update
  2. Disable firewall:
    systemctl disable firewalld
    systemctl stop firewalld
  3. Set IP:
    DHCP disabled
    IP from 192.168.195.2 to 192.168.195.127 (192.168.195.0 – the subnet I declared)
    pc-4-dev example (IP=192.168.195.104):
    reboot

Configure pc-1-jboss-kie-server (jboss on: IP=192.168.195.101)

  1. Download and unzip wildfly-10.0.0-Final
  2. Run: [root@pc-1 bin]#./standalone.sh
  3. Create user: [root@pc-1 bin]#./add-user.sh
  4. Modify standalone-full.xml:
    <interfaces>
    <interface name=”management”>
    <inet-address value=”${jboss.bind.address.management:192.168.195.101}”/>
    </interface>
    <interface name=”public”>
    <inet-address value=”${jboss.bind.address:192.168.195.101}”/>
    </interface>
    <interface name=”unsecure”>
    <inet-address value=”${jboss.bind.address.unsecure:192.168.195.101}”/>
    </interface>
    </interfaces>
  5. Run: [root@pc-1 bin]#./standalone.sh –server-config=standalone-full.xml
  6. For test, from 192.162.195.104, for example do: http://192.168.195.101:9990

Configure pc-2-jbpm-db (PostgreSQL 9.5.3 on: IP=192.168.195.102)

Server Installation:

  1. dnf install postgresql.service
  2. postgresql-setup initdb
  3. systemctl enable postgresql.service
  4. systemctl start postgresql.service

Configuration:

  1. pg_hba.conf:
    host all all 0.0.0.0/0 md5
  2. postgresql.conf:
    listen_addresses = ‘*’
  3. PgAdmin3 installation:
    dnf -y install pgadmin3

Test on pc-3-jbpm-client (IP=192.168.195.103):
dnf -y install pgadmin3

Shared Folders (on pc-4-dev example)

  1. I have on Windows shared folder: F:\Shared with file test-share.txt.
  2. VMware Workstation:

    and next:

  3. vmware-hgfsclient
  4. look at /mnt/hgfs (empty)
  5. vmhgfs-fuse -o allow_other -o nonempty .host:/Win_F_Shared /mnt/hgfs
  6. Mount Shared Folder at Startup: /etc/bashrc Add line: vmhgfs-fuse -o allow_other -o nonempty .host:/Win_F_Shared /mnt/hgfs

Backup / Restore

  1. Backup:
    1.1. Backup Virtual Mechines folder (with pc-1, pc-2, …)
    1.2. C:\WINDOWS\system32>cmd.exe
    1.3. vnetlib64.exe — export F:\tmp\net-configuration.txt
    vnetlib64.exe is in C:\Program Files (x86)\VMware\VMware Workstation
  2. Restore:
    2.1. Restore Virtual Mechines folder
    2.2. vnetlib64.exe — import F:\tmp\net-configuration.txt

 

Leave a Reply