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

NC | Online Upgrade | Config directory restructure upgrade script #8486

Merged

Conversation

romayalon
Copy link
Contributor

@romayalon romayalon commented Oct 29, 2024

Explain the changes

  1. Added config directory restructure upgrade script based on the following algorithm -
1. Creation of the identities/ directory.
2. Creation of accounts_by_name/ directory.
3. Iterate all accounts under accounts/  directory
  3.1. Creation identity
    3.1.1. Create config_dir/identities/111/ directory
    3.1.2. Create a hard link from accounts/account_name.json to config_dir/identities/111/identity.json
    If failed add to failed_account array and continue the loop
  3.2. Account Name symlink -  Symlink accounts_by_name/account_name.symlink → config_dir/identities/111/identity.json
    If failed add to failed_account array and continue the loop
  3.3. Account access key symlink - 
     3.3.1. link tmp_access_key symlink→ config_dir/identities/111/identity.json
     3.3.2. on GPFS - Linkat() - tmp_access_key -> config_dir/access_keys/access_key.symlink
     3.3.3. On POSIX - Rename() - tmp_access_key -> config_dir/access_keys/access_key.symlink
     If failed add to failed_account array and continue the loop
4. Delete accounts/ to a different directory

Issues: Fixed #xxx / Gap #xxx

  1. Automated tests -
    1.1. unit tests
    1.2. test on a GPFS cluster.
    1.3. re-entrancy tests.
    1.4. Scale tests (5000 accounts) and measurements.
  2. List accounts in batch is scale tests show bad performance

Testing Instructions:

  1. Manual Test -
    1.1. Install NooBaa 5.17 and create accounts, a system, buckets etc.
    1.2. Install NooBaa 5.18, start the noobaa service.
    1.3. Run NooBaa config dir upgrade -
sudo node src/cmd/manage_nsfs.js upgrade start --expected_version 5.18.0 --expected_hosts <host_name>

1.4. Check config dir was upgraded successfully.

  • Doc added/updated
  • Tests added

@romayalon romayalon force-pushed the romy-config-restructure-upgrade-script branch 2 times, most recently from d136178 to 54ad226 Compare October 30, 2024 10:44
@romayalon romayalon force-pushed the romy-config-restructure-upgrade-script branch 2 times, most recently from ead5e85 to cc8cd6f Compare November 5, 2024 17:32
@romayalon romayalon force-pushed the romy-config-restructure-upgrade-script branch from cc8cd6f to d201cfe Compare November 7, 2024 08:17
@romayalon romayalon force-pushed the romy-config-restructure-upgrade-script branch from d201cfe to 6b3f7d6 Compare November 7, 2024 08:18
@romayalon romayalon merged commit 4379cbf into noobaa:master Nov 7, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants