MOP - Yarnman u18 Migration
- 1.1 CORE MIGRATION:
- 1.2 Prerequisites:
- 1.2.1 Script with Remote:
- 1.2.2 Script with Local:
- 1.3 ARM MIGRATION:
- 1.4 Prerequisites:
- 1.4.1 Script with Remote:
- 1.4.2 Script with Local:
- 1.4.3 Manual:
- 2 Troubleshooting
CORE MIGRATION:
Prerequisites:
Install yarnman via the OVA, with the normal install script https://yarnlab.atlassian.net/wiki/spaces/YSP/pages/2916941825/Yarnman+Photon+Powered+YM-PH+-+Installation+and+Upgrade+Guide?atlOrigin=eyJpIjoiN2ZkYmI4YzFiOWEzNGIwYTgxMWU4ZWE0ZTQ4ZjliZmMiLCJwIjoiYyJ9
Script with Remote:
This should be done as root user or with sudo
the admin password set field isn’t migrated with the migration, you either need to
Login to yarnman first on the new install and set a password (the existing password from the remote system will be restored after successful migration);
or after the restore it will prompt you to update the password, and will overwrite the restored password, you can set the same password again.
Enable local Couchdb access by running -
ym-edit-config.sh enable-local-couchdb-access
Local Redis access should only be enabled if a remote arm is being used.
Enable local Redis access by running -
ym-edit-config.sh enable-local-redis-accessas root Run ym-migrate-u18 remote. The script will ask you to enter yarnman IP to copy from, and the username and password
root@yarnman-core-2614 [ /var/home/yarnman ]# ym-migrate-u18.sh remote
Local system configured, continuing...
Starting Remote Mig
Using remote migration
Enter yarnman IP to copy from: 10.101.205.120
Enter yarnman user to copy from: yarnman
Enter yarnman password to copy from:
test connection failed, Exiting... echo If you get 'test connection failed, Exiting...' for new host, you will need to manually add ssh host key by testing connection, scp yarnman@10.101.205.120:/opt/yarnlab/yarnman/config/local.yaml ./It will fail when trying to connect to a new host for the first time, so
run ssh USERNAME@IP_ADDRESSeither login and exit, or abort the connection, so you are back to the new target host again.
root@yarnman-core-2614 [ /var/home/yarnman ]# ssh yarnman@10.101.205.120
The authenticity of host '10.101.205.120 (10.101.205.120)' can't be established.
ED25519 key fingerprint is SHA256:KI+dpSgTvQ0GaI2oHV5xruiZd++1+MDaqxlb7t0duOw.
This key is not known by any other names
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '10.101.205.120' (ED25519) to the list of known hosts.
Run ym-migrate-u18 remote again and fill in IP, username and password. The script will ask you if you want to wipe existing database, type 'y'
root@yarnman-core-2614 [ /var/home/yarnman ]# ym-migrate-u18.sh remote
Local system configured, continuing...
Starting Remote Mig
Using remote migration
Enter yarnman IP to copy from: 10.101.205.120
Enter yarnman user to copy from: yarnman
Enter yarnman password to copy from: test connection OK
Do you want to wipe existing database and migrate Y or NyIt will now run through the migration
Script with Local:
This should be done as root user or with sudo
Prerequisites is to create the tar file on the ubuntu host, make sure to mkdir /opt/yarnlab/backup if it doesn’t already exist on the host.
Check for available space in the mounted path / , this will need to be about the same amount or more then the current size of /var/lib/couchdb . the backup will be compressed slightly so may use less space
df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg0-root 37G 28G 6.9G 81% /
/dev/mapper/vg0-var--lib--couchdb 41G 7.2G 32G 19% /var/lib/couchdbrun the following to backup the database and config ready to transfer to the new node
DATESTAMP=$(date +%F); cd /opt/yarnlab/yarnman && node ./scripts/compactdb.js; tar --exclude=/opt/couchdb/data/lost+found -cvzf /opt/yarnlab/backup/yarnman-u18-export-$DATESTAMP.tar.gz /opt/yarnlab/yarnman/config/* /opt/couchdb/data/* /opt/couchdb/etc/*; echo filename is /opt/yarnlab/backup/yarnman-u18-$DATESTAMP.tar.gzOn the new target
Enable local Couchdb access by running -
ym-edit-config.sh enable-local-couchdb-access
Local Redis access should only be enabled if a remote arm is being used.
Enable local Redis access by running -
ym-edit-config.sh enable-local-redis-accessRun ym-migrate-u18.sh local -
root@yarnman-core-2614 [ /var/home/yarnman ]# ym-migrate-u18.sh local Local system configured, continuing... Starting Local Mig Using local migration Yarnman Migration name provided is in wrong format, Exiting... The format for the filename should be, 'yarnman-u18-export-<date>.tar.gz' located at /var/opt/yarnlab/backup Run the following command on the source yarnman node to extract configuration: DATESTAMP=2025-04-03; cd /opt/yarnlab/yarnman && node ./scripts/compactdb.js; tar --exclude=/opt/couchdb/data/lost+found -cvzf /opt/yarnlab/backup/yarnman-u18-export-$DATESTAMP.tar.gz /opt/yarnlab/yarnman/config/* /opt/couchdb/data/* /opt/couchdb/etc/*; echo filename is /opt/yarnlab/backup/yarnman-u18-$DATESTAMP.tar.gz Then copy the file from source at /opt/yarnlab/backup/yarnman-u18-export-<date>.tar.gz to the target at /var/opt/yarnlab/backup via scp/sftp If the source server is acessible you can run the following command scp yarnman@10.101.205.120:/opt/yarnlab/backup/yarnman-u18-export-<date>.tar.gz /var/opt/yarnlab/backupThe script will tell you to run a specific command on the source yarnman core node as seen above ^ So on the source system for example, run -
yarnman@yarnman-democore-new:~$ DATESTAMP=2025-04-03; cd /opt/yarnlab/yarnman && node ./scripts/compactdb.js; tar --exclude=/opt/couchdb/data/lost+found -cvzf /opt/yarnlab/backup/yarnman-u18-export-$DATESTAMP.tar.gz /opt/yarnlab/yarnman/config/* /opt/couchdb/data/* /opt/couchdb/etc/*; echo filename is /opt/yarnlab/backup/yarnman-u18-$DATESTAMP.tar.gz 1743648931717 INFO Database compaction is starting. ...Once the command finishes, it will create a tar file which is echoed on the source system - this needs to be copied to the target system. The scp command copies the tar file to /var/opt/yarnlab/backup
filename is /opt/yarnlab/backup/yarnman-u18-2025-04-03.tar.gzroot@yarnman-core-2614 [ /var/home/yarnman ]# scp yarnman@10.101.205.120:/opt/yarnlab/backup/yarnman-u18-export-2025-04-03.tar.gz /var/opt/yarnlab/backup Authorized uses only. All activity may be monitored and reported. yarnman@10.101.205.120's password: yarnman-u18-export-2025-04-03.tar.gz
If you have run out of space and it failed to create the tar file, you can try this alternative , to create the backup on the database partition
DATESTAMP=$(date +%F); mkdir /opt/couchdb/data/backup; cd /opt/yarnlab/yarnman; tar --exclude=/opt/couchdb/data/lost+found --exclude=/opt/couchdb/data/backup -cvzf /var/lib/couchdb/backup/yarnman-u18-export-$DATESTAMP.tar.gz /opt/yarnlab/yarnman/config/* /opt/couchdb/data/* /opt/couchdb/etc/* Once completed modify the permissions to allow the yarnman user to read the file
chmod 655 /var/lib/couchdb/backup
chmod 644 /var/lib/couchdb/backup/* You can ssh from the remote system to get the backup file now
root@ym-ci-auto-yarnman-core [ /var/opt/yarnlab/backup ]# cd /var/opt/yarnlab/backup
root@ym-ci-auto-yarnman-core [ /var/opt/yarnlab/backup ]# scp yarnman@10.101.10.86:/var/lib/couchdb/backup/* .It may ask for host key verification if connecting to the host for the first time, type ‘yes’ when prompted
The authenticity of host '10.101.205.120 (10.101.205.120)' can't be established.
ED25519 key fingerprint is SHA256:KI+dpSgTvQ0GaI2oHV5xruiZd++1+MDaqxlb7t0duOw.
This key is not known by any other names
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '10.101.205.120' (ED25519) to the list of known hosts.
Authorized uses only. All activity may be monitored and reported. If you get a permission error trying to retrive the file, set the permission of the file on the ubuntu host
chmod 644 /path/to/backup.tar.gzOnce the tar file has been copied over, run ym-migrate-u18.sh local yarnman-u18-export-<DATE>.tar.gz to start the migration. Type 'y' when prompted to wipe existing database and migrate.
root@yarnman-core-2614 [ /var/home/yarnman ]# ym-migrate-u18.sh local yarnman-u18-export-2025-04-03.tar.gz Local system configured, continuing... Starting Local Mig Using local migration Migration file name format is correct U18 Migration file found: /var/opt/yarnlab/backup/yarnman-u18-export-2025-04-03.tar.gz Do you want to wipe existing database and migrate Y or NyThis will now run through the migration.
ARM MIGRATION:
Prerequisites:
Install yarnman via the OVA, with the normal install script https://yarnlab.atlassian.net/wiki/spaces/YSP/pages/2916941825/Yarnman+Photon+Powered+YM-PH+-+Installation+and+Upgrade+Guide?atlOrigin=eyJpIjoiN2ZkYmI4YzFiOWEzNGIwYTgxMWU4ZWE0ZTQ4ZjliZmMiLCJwIjoiYyJ9
Redis should be protected with a firewall rule on both arm and core, this is done slightly different in photon compared to using UFW in 2.5.x This should be allowed to both Arm(s) and Core
## WARNING! ##any syntax errors could block all traffic into the server, and you will need to connect via the vshphere console to revert the rules
Make a backup of the existing ip4save
cp /etc/systemd/scripts/ip4save /etc/systemd/scripts/ip4save.backup Modify the existing /etc/systemd/scripts/ip4save and add :DOCKER-USER - [0:0] under :OUTPUT DROP [0:0]
then add the follow rules above the COMMIT line , change to the ip address’s
nano /etc/systemd/scripts/ip4save
-A DOCKER-USER -i eth0 -p tcp -s ip.address.of.core,ip.address.of.arm --dport 6379 -m comment --comment "Allow yarnman Redis Traffic - " -j RETURN
-A DOCKER-USER -i eth0 -p tcp -s 0.0.0.0/0 --dport 6379 -m comment --comment "block Redis - " -m limit --limit 2/min -j LOG --log-prefix "REDIS DROP-"
-A DOCKER-USER -i eth0 -p tcp -s 0.0.0.0/0 --dport 6379 -m comment --comment "block Redis Traffic - " -j DROP
-A DOCKER-USER -i eth0 -p tcp -s ip.address.of.core,ip.address.of.arm --dport 6984 -m comment --comment "Allow yarnman couchdb Traffic - " -j RETURN
-A DOCKER-USER -i eth0 -p tcp -s 0.0.0.0/0 --dport 6984 -m comment --comment "block Couchdb - " -m limit --limit 2/min -j LOG --log-prefix "COUCHDB DROP-"
-A DOCKER-USER -i eth0 -p tcp -s 0.0.0.0/0 --dport 6984 -m comment --comment "block Couchdb Traffic - " -j DROPFinal file should look like
nano /etc/systemd/scripts/ip4save
# init
*filter
:INPUT DROP [0:0]
:FORWARD DROP [0:0]
:OUTPUT DROP [0:0]
:DOCKER-USER - [0:0]
# Allow local-only connections
-A INPUT -i lo -j ACCEPT
-A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
#keep commented till upgrade issues are sorted
#-A INPUT -j LOG --log-prefix "FIREWALL:INPUT "
-A INPUT -p tcp -m tcp --dport 22 -j ACCEPT
-A OUTPUT -j ACCEPT
-A DOCKER-USER -i eth0 -p tcp -s 10.101.10.160,10.101.10.161 --dport 6379 -m comment --comment "Allow yarnman Redis Traffic - " -j RETURN
-A DOCKER-USER -i eth0 -p tcp -s 0.0.0.0/0 --dport 6379 -m comment --comment "block Redis - " -m limit --limit 2/min -j LOG --log-prefix "REDIS DROP-"
-A DOCKER-USER -i eth0 -p tcp -s 0.0.0.0/0 --dport 6379 -m comment --comment "block Redis Traffic - " -j DROP
-A DOCKER-USER -i eth0 -p tcp -s 10.101.10.160,10.101.10.161 --dport 6984 -m comment --comment "Allow yarnman Couchdb Traffic - " -j RETURN
-A DOCKER-USER -i eth0 -p tcp -s 0.0.0.0/0 --dport 6984 -m comment --comment "block Couchdb - " -m limit --limit 2/min -j LOG --log-prefix "COUCHDB DROP-"
-A DOCKER-USER -i eth0 -p tcp -s 0.0.0.0/0 --dport 6984 -m comment --comment "block Couchdb Traffic - " -j DROP
COMMITTest the file for any syntax errors, no errors should be reported
iptables-restore --test /etc/systemd/scripts/ip4save
Example if there is any error
iptables-restore --test /etc/systemd/scripts/ip4save
iptables-restore: line 14 failedonly once confirmed no syntax errors, reboot the server to apply the rules
rules can be verified with
iptables -L -v -n
Chain DOCKER-USER (1 references)
pkts bytes target prot opt in out source destination
0 0 RETURN 6 -- eth0 * 10.101.10.160 0.0.0.0/0 tcp dpt:6379 /* Allow yarnman Redis Traffic - */
429 73716 RETURN 6 -- eth0 * 10.101.10.161 0.0.0.0/0 tcp dpt:6379 /* Allow yarnman Redis Traffic - */
0 0 LOG 6 -- eth0 * 0.0.0.0/0 0.0.0.0/0 tcp dpt:6379 /* block Redis - */ limit: avg 2/min burst 5 LOG flags 0 level 4 prefix "REDIS DROP-"
0 0 DROP 6 -- eth0 * 0.0.0.0/0 0.0.0.0/0 tcp dpt:6379 /* block Redis Traffic - */
0 0 RETURN 6 -- eth0 * 10.101.10.160 0.0.0.0/0 tcp dpt:6984 /* Allow yarnman Couchdb Traffic - */
287 36840 RETURN 6 -- eth0 * 10.101.10.161 0.0.0.0/0 tcp dpt:6984 /* Allow yarnman Couchdb Traffic - */
0 0 LOG 6 -- eth0 * 0.0.0.0/0 0.0.0.0/0 tcp dpt:6984 /* block Couchdb - */ limit: avg 2/min burst 5 LOG flags 0 level 4 prefix "COUCHDB DROP-"
0 0 DROP 6 -- eth0 * 0.0.0.0/0 0.0.0.0/0 tcp dpt:6984 /* block Couchdb Traffic - */
739 251K RETURN 0 -- * * 0.0.0.0/0 0.0.0.0/0 Check for any drops
root@ym-ci-auto-yarnman-core [ /var/home/yarnman ]# journalctl --since today | grep DROP-IN
May 16 05:17:34 ym-ci-auto-yarnman-core kernel: COUCHDB DROP-IN=eth0 OUT=br-a81ccc2e94fa MAC=00:50:56:9f:b4:0a:00:50:56:9f:95:fa:08:00 SRC=10.202.30.221 DST=10.222.1.4 LEN=64 TOS=0x00 PREC=0x00 TTL=61 ID=0 DF PROTO=TCP SPT=56081 DPT=6984 WINDOW=65535 RES=0x00 SYN URGP=0
May 16 05:18:23 ym-ci-auto-yarnman-core kernel: REDIS DROP-IN=eth0 OUT=br-a81ccc2e94fa MAC=00:50:56:9f:b4:0a:00:50:56:9f:95:fa:08:00 SRC=10.202.30.221 DST=10.222.1.6 LEN=64 TOS=0x00 PREC=0x00 TTL=61 ID=0 DF PROTO=TCP SPT=56142 DPT=6379 WINDOW=65535 RES=0x00 SYN URGP=0 Fore more information refer to https://yarnlab.atlassian.net/wiki/spaces/YSP/pages/2915991850/Yarnman+Photon+Powered+YM-PH+-+Advanced+Platform+Configuration#Photon-iptables
Script with Remote:
contact yarnlab for a copy of the arm migration script if required, recommendation is to use the manual method. reference YMN-5793
This should be done as root user
Run ssh to the old arm-
ssh yarnman@10.101.205.121 accecpt the fingerprintRun ./ym-arm-migration.sh remote -
[ /var/home/yarnman ]# ym-arm-migration.sh remote Starting Remote Arm Mig Using remote migration Enter yarnman IP to copy from: 10.101.205.121 Enter yarnman user to copy from: yarnman Enter yarnman password to copy from: test connection OKwipe and accecpt keys/cert copy -
Do you want to wipe existing local.yaml and yarnman keys/certificates Y or Ny Wiping... Stopping services and wiping existing configuration Starting copying yarnman configOnce the command finishes, the network copy will start
Starting copying yarnman config Authorized uses only. All activity may be monitored and reported. Authorized uses only. All activity may be monitored and reported. Authorized uses only. All activity may be monitored and reported. Authorized uses only. All activity may be monitored and reported. Remote migration files copied Resetting Permissions...
It may ask for host key verification if connecting to the host for the first time, type ‘yes’ when prompted
The script will ask you to enter the CORE IP addresses for Couchdb and Redis, as well as the CORE username and password for Couchdb - for example
Enter Core System Couchdb IP in this format, 'https://IP_ADDRESS:6984': https://10.101.10.160:6984 Enter Core System Redis IP in this format, 'redis://IP_ADDRESS:6379: redis://10.101.10.160:6379 Enter Core System Couchdb Username: architect Enter Core System Couchdb Password: xxxxx Updating local.yaml Updating docker-compose-override.yml Starting yarnman... Arm migration now complete.This will now run through the migration, you may need to reboot the arm if you don’t see the connection come up after verifying core node has correct firewall and service(s) running.
Script with Local:
contact yarnlab for a copy of the arm migration script if required, recommendation is to use the manual method. reference YMN-5793
This should be done as root user
Run -
chmod +x ym-arm-migration.shRun ./ym-arm-migration.sh local -
root@yarnman-arm-2614 [ /var/home/yarnman ]# ./ym-arm-migration.sh local Local system configured, continuing... Starting Local Arm Mig Using local migration Yarnman Migration name provided is in wrong format, Exiting... The format for the filename should be, 'yarnman-arm-export-<date>.tar.gz' located at /var/opt/yarnlab/backup Run the following command on the source yarnman node to extract configuration: DATESTAMP=2025-04-04; tar -cvzf /opt/yarnlab/backup/yarnman-arm-export-$DATESTAMP.tar.gz /opt/yarnlab/yarnman/config/local.yaml /opt/yarnlab/yarnman/config/*.pem /opt/yarnlab/yarnman/config/public-encryption-key.pub /opt/yarnlab/yarnman/config/ssl-cert.cert; echo filename is /opt/yarnlab/backup/yarnman-arm-export-$DATESTAMP.tar.gz Then copy the file from source at /opt/yarnlab/backup/yarnman-arm-export-<date>.tar.gz to the target at /var/opt/yarnlab/backup via scp/sftp If the source server is acessible you can run the following command scp yarnman@10.101.205.120:/opt/yarnlab/backup/yarnman-arm-export-<date>.tar.gz /var/opt/yarnlab/backupThe script will tell you to run a specific command on the source yarnman arm node as seen above ^ So on the source system for example, run -
yarnman@yarnman-demoarm2-new:~$ DATESTAMP=2025-04-04; tar -cvzf /opt/yarnlab/backup/yarnman-arm-export-$DATESTAMP.tar.gz /opt/yarnlab/yarnman/config/local.yaml /opt/yarnlab/yarnman/config/*.pem /opt/yarnlab/yarnman/config/public-encryption-key.pub /opt/yarnlab/yarnman/config/ssl-cert.cert; echo filename is /opt/yarnlab/backup/yarnman-arm-export-$DATESTAMP.tar.gz tar: Removing leading `/' from member names /opt/yarnlab/yarnman/config/local.yaml /opt/yarnlab/yarnman/config/private-encryption-key.pem /opt/yarnlab/yarnman/config/ssl-key.pem /opt/yarnlab/yarnman/config/public-encryption-key.pub /opt/yarnlab/yarnman/config/ssl-cert.cert filename is /opt/yarnlab/backup/yarnman-arm-export-2025-04-04.tar.gzOnce the command finishes, it will create a tar file which is echoed on the source system - this needs to be copied to the target system. The scp command copies the tar file to /var/opt/yarnlab/backup
filename is /opt/yarnlab/backup/yarnman-arm-export-2025-04-04.tar.gzroot@yarnman-arm-2614 [ /var/home/yarnman ]# scp yarnman@10.101.205.121:/opt/yarnlab/backup/yarnman-arm-export-2025-04-04.tar.gz /var/opt/yarnlab/backup Authorized uses only. All activity may be monitored and reported. yarnman@10.101.205.121's password: yarnman-arm-export-2025-04-04.tar.gz 100% 4626 6.7MB/s 00:00
It may ask for host key verification if connecting to the host for the first time, type ‘yes’ when prompted
The authenticity of host '10.101.205.121 (10.101.205.121)' can't be established.
ED25519 key fingerprint is SHA256:KI+dpSgTvQ0GaI2oHV5xruiZd++1+MDaqxlb7t0duOw.
This key is not known by any other names
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '10.101.205.121' (ED25519) to the list of known hosts.
Authorized uses only. All activity may be monitored and reported.Once the tar file has been copied over, run ./ym-arm-migration.sh local yarnman-arm-export-<DATE>.tar.gz to start the migration. Type 'y' when prompted to wipe existing configuration and start the migration
root@yarnman-arm-2614 [ /var/home/yarnman ]# ./ym-arm-migration.sh local yarnman-arm-export-2025-04-04.tar.gz Local system configured, continuing... Starting Local Arm Mig Using local migration Arm migration file name format is correct Arm migration file found: /var/opt/yarnlab/backup/yarnman-arm-export-2025-04-04.tar.gz Do you want to wipe existing local.yaml and yarnman keys/certificates Y or NyThe script will ask you to enter the CORE IP addresses for Couchdb and Redis, as well as the CORE username and password for Couchdb - for example
Enter Core System Couchdb IP in this format, 'https://IP_ADDRESS:6984': https://10.101.225.72:6984 Enter Core System Redis IP in this format, 'redis://IP_ADDRESS:6379: redis://10.101.225.72:6379 Enter Core System Couchdb Username: architect Enter Core System Couchdb Password: xxxxThis will now run through the migration.
Manual:
This should be done as root user
First need to remove local.yaml, keys and certificates from /var/opt/yarnlab/yarnman/config on the target system, and then copy local.yaml, keys and certificates from the source system to the target system.
To do this, run these commands:
On target system:
systemctl stop yarnman
mv /var/opt/yarnlab/yarnman/config/local.yaml /var/opt/yarnlab/yarnman/config/local.yaml.old
rm -f /var/opt/yarnlab/yarnman/config/*.pem
rm -f /var/opt/yarnlab/yarnman/config/public-encryption-key.pub
rm -f /var/opt/yarnlab/yarnman/config/ssl-cert.cert
#Make sure to change user and IP addresses for these commands
scp -rp yarnman@10.101.205.121:/opt/yarnlab/yarnman/config/local.yaml /var/opt/yarnlab/yarnman/config/
scp -rp yarnman@10.101.205.121:/opt/yarnlab/yarnman/config/*.pem /var/opt/yarnlab/yarnman/config/
scp -rp yarnman@10.101.205.121:/opt/yarnlab/yarnman/config/public-encryption-key.pub /var/opt/yarnlab/yarnman/config/
scp -rp yarnman@10.101.205.121:/opt/yarnlab/yarnman/config/ssl-cert.cert /var/opt/yarnlab/yarnman/config/you may need to accept the fingerprint when connecting to the old arm
Edit with
nano /var/opt/yarnlab/yarnman/config/local.yaml
Need to change Couchdb address (make sure to modify to https), username, and password to match the Core address, username and password
Need to change Redis address to match the Core address.
For example:
nodeId: arm_4b72761cb3f743109db95932813cdae9
couchdb:
address: 'https://10.101.225.72:6984' - Core Couchdb address
username: 'architect' - Core Couchdb username
password: 'xxxx' - Core Couchdb password
isAdmin: false
redis:
address: 'redis://10.101.225.72:6379' - Core Redis address
graylog2:
target: null
debugging:
interfaces:
jtapi:
useFileTrace: true
useJavaConsoleTrace: true
showRedisLogs: true
logging:
console: debug
developmentMode: false
Edit
nano /var/opt/yarnlab/yarnman/docker-compose-override.yml
Need to make sure only yarnman container runs, add to docker-compose-override:
services:
yarnman:
hostname: ym-testarm
depends_on: !reset []
healthcheck:
disable: true
couchdb:
profiles:
- donotstart-arm
redis:
profiles:
- donotstart-arm
tang:
profiles:
- donotstart-armFor example:
root@yarnman-arm-2614 [ /var/home/yarnman ]# yq eval /var/opt/yarnlab/yarnman/docker-compose-override.yml
services:
yarnman:
hostname: ym-yarnman-arm-2614
depends_on: !reset []
healthcheck:
disable: true
couchdb:
profiles:
- donotstart-arm
redis:
profiles:
- donotstart-arm
tang:
profiles:
- donotstart-armyq can be used to validate syntax errors with yaml files , which will advise the line that has an issues. most likely it will be a missing space or too many spaces.
example error
Error: bad file '/var/opt/yarnlab/yarnman/docker-compose-override.yml': yaml: line 4: mapping values are not allowed in this context
Reset permissions, run -
root@yarnman-arm-2614 [ /var/home/yarnman ]# ansible-playbook /usr/share/ansible/yarnlab/ym-permissions.yml ... lots of text will come back ... PLAY RECAP **************************************************************************************************************************************************************************************** localhost : ok=64 changed=16 unreachable=0 failed=0 skipped=4 rescued=0 ignored=0 root@yarnman-arm-2614 [ /var/home/yarnman ]#Start yarnman -
root@yarnman-arm-2614 [ /var/home/yarnman ]# systemctl start yarnman
Troubleshooting
Q:Can’t connect to database on 6984
A:The migration to the later versions of couchdb require the use of https for the database connection. Hence the port number has changed to 6984 . Depending on the environment 5984 may only be opened on the corp/boundary firewalls. To allow Secure over the existing port number of 5984. Add the port number to the core node. either via the yq command below, or manually editing the file via nano. Restart yarnman for the changes to be applied
root@yarnman-arm-2614 [ /var/home/yarnman ]# yq eval '.services.couchdb.ports += ["5984:6984"]' -i /var/opt/yarnlab/yarnman/docker-compose-override.yml The override file should look similar to this. You can also edit this file via nano , make sure to get the correct spaces
yarnman@ym-ci-auto-yarnman-core [ ~ ]$ more /var/opt/yarnlab/yarnman/docker-compose-override.yml
services:
yarnman:
hostname: yarnman-arm-2614
couchdb:
ports:
- 5984:6984
- 6984:6984
redis:
ports:
- 6379:6379restart yarman
sudo ym-service-commands.sh restartYou may need to adjust the firewall rules in /etc/systemd/scripts/ip4saveto change the port to 5984 or add the additional port https://yarnlab.atlassian.net/wiki/spaces/YMN/pages/3428548614/MOP+-+Yarnman+Migration#Prerequisites%3A.1