Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Files: Update to latest rabbitmq #75

Open
scblack321 opened this issue Feb 10, 2023 · 0 comments
Open

Files: Update to latest rabbitmq #75

scblack321 opened this issue Feb 10, 2023 · 0 comments
Assignees
Labels

Comments

@scblack321
Copy link
Contributor

Task: Update to latest rabbitmq. Currently Files uses 3.8. Latest version currently is 3.11.
Make sure that rabbitmq is using a fixed data directory, e.g. /var/lib/rabbitmq/mnesia/rabbit@files-rabbitmq

History:

Files is currently setup to use to use rabbitmq 3.8.11-management.
Note that this configuration is in the deployment files in repo tapis-project/tapis-deployer under directlory templates/files.

Recently it was discovered that for files rabbitmq would create a new data directory each time it was re-deployed in kubernetes. This leads to the possibility that the pvc volume could fill up.
This is unlike the Jobs service, where the rabbitmq data directory is always the same. This turned out to be (at least in part) because Jobs sets the env variable HOSTNAME and Files did not. In kubernetes pods the HOSTNAME by default can change with each deployment.
Just before this issue was created the Files k8s template deploy rabbitmq files were updated to match those of Jobs, so Files is also using a fixed rabbitmq data dir.

Another discovery was that when moving to rabbitmq 3.11.7 setting the HOSTNAME in the environment was not enough to result in a fixed data dir. Explicitly setting certain rabbitmq env variables did work:

 RABBITMQ_NODENAME=tapis-files
 RABBITMQ_MNESIA_DIR=/var/lib/rabbitmq/mnesia/tapis-files
 RABBITMQ_PLUGINS_EXPAND_DIR=/var/lib/rabbitmq/mnesia/tapis-files-plugins-expand
 RABBITMQ_PID_FILE=/var/lib/rabbitmq/mnesia/[email protected]
 RABBITMQ_FEATURE_FLAGS_FILE=/var/lib/rabbitmq/mnesia/tapis-files@localhost-feature_flags

Note that although it is undesirable that these have hard coded absolute paths we already have this entry in the rabbitmq deployment files:

         volumeMounts:
            - name: files-rabbitmq-data
              mountPath: "/var/lib/rabbitmq/mnesia"

@scblack321 scblack321 self-assigned this Feb 10, 2023
@scblack321 scblack321 moved this from To Do to In Progress in Tapis Project Beta Board Feb 14, 2023
@scblack321 scblack321 moved this from In Progress to To Do in Tapis Project Beta Board Feb 14, 2023
@scblack321 scblack321 moved this from To Do to In Progress in Tapis Project Beta Board Mar 10, 2023
@scblack321 scblack321 moved this from In Progress to To Do in Tapis Project Beta Board Mar 10, 2023
@dvernon-tacc dvernon-tacc moved this from To Do to On Hold in Tapis Project Beta Board May 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants