<html><head><title></title></head><body><!-- rte-version 0.2 9947551637294008b77bce25eb683dac --><div class="rte-style-maintainer rte-pre-wrap" data-color="global-default" bbg-color="default" data-bb-font-size="medium"bbg-font-size="medium" style="white-space: pre-wrap; font-size: small; font-family: "Courier New", Courier, "BB.FixedWidth";"style="white-space: pre-wrap; font-size: small; font-family: "Courier New", Courier, "BB.FixedWidth"; color: rgb(0, 0, 0);">Thanks Mike. What you described is what we plan to do. I do see the migration historical files. They are under ../venv/pulp/3.7 in our case. It is a virtual environment used by the pulp_installer.  We set the pulp_install_dir to this directory.  Since we are upgrading python to 3.8 for pulp 3.15.  We set the pulp_install_dir to  a new ../venv/pulp/3.8. Because this is a new python install dir, I am not sure how pulp_installer know where to find the historical file under the old ../venv/pulp/3.7. Could this be an issue for the migration?<br><br><div class="rte-style-maintainer" data-color="global-default"bbg-color="default" data-bb-font-size="medium" bbg-font-size="medium" style="font-size: small; font-family: "Courier New", Courier, "BB.FixedWidth";"style="font-size: small; font-family: "Courier New", Courier, "BB.FixedWidth"; color: rgb(0, 0, 0);"><div><div class="bbg-rte-fold-content" data-header="From: mikedep333@redhat.com At: 09/20/21 12:21:22 UTC-4:00"data-digest="From: mikedep333@redhat.com At: 09/20/21 12:21:22 UTC-4:00" style=""><div class="bbg-rte-fold-summary">From: mikedep333@redhat.com At: 09/20/21 12:21:22 UTC-4:00</div>To: <a spellcheck="false" bbg-destination="mailto:bli111@bloomberg.net" href="mailto:bli111@bloomberg.net"> Bin Li (BLOOMBERG/ 120 PARK ) </a><br>Cc: <a spellcheck="false"bbg-destination="mailto:pulp-list@redhat.com" href="mailto:pulp-list@redhat.com"> pulp-list@redhat.com</a><br>Subject: Re: [Pulp-list] pulp3 migration directory</div><br></div><div class="rte-internet-block-wrapper" style="background: white; color: black; font-family: Arial, "BB.Proportional"; font-size: small; white-space: normal;"><div class="rte-internet-block"><blockquote><div dir="ltr">Hi Bin,<div><br></div><div>We are trying to understand what you are asking exactly.</div><div><br></div><div>It sounds like:</div><div>1. you have a test environment with a copy of the production database.</div><div>2. You upgraded pulp on the test environment. During this, the migrations were ran by pulp_installer against the test database copy.</div><div>3. You will run the upgrade pulp on the production environment, which will upgrade the production database.</div><div><br></div><div>So we have all the possibly needed migration files on disk. They are static, and are part of the pypi packages (and RPM packages too.) This is a change from the pulpcore 3.0 alpha/beta/rc behavior, when we generated the migrations.</div><div><br></div><div>If you run `find /usr/local/lib/pulp | grep migrations` , you will see all of them. You'll see both compiled .pyc files and the original .py files.</div><div><br></div><div>When the installer runs, it runs all the needed migrations. This is part of the pulp_database_config role, the task is named "Run database migrations".</div><div><br></div><div>roles/pulp_database_config/README.md still refers to the pulpcore 3.0 alpha/beta/rc behavior when it says that it "Create and run migrations." It only runs them now. I will fix this doc.</div><div><br></div><div>Does this answer your questions?</div><div><br></div><div>-Mike</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Sep 16, 2021 at 4:52 PM Bin Li (BLOOMBERG/ 120 PARK) <<a spellcheck="false"bbg-destination="mailto:rte:bind" class="" href="mailto:bli111@bloomberg.net" data-destination="mailto:rte:bind">bli111@bloomberg.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="font-size: small; font-family: "Courier New", Courier, "BB.FixedWidth"; white-space: pre-wrap;">The 3.15 release requires python 3.8. We are currently running pulpcore 3.7 with python 3.7 and an external db. When we use the pulp_installer to migrate the older release to 3.15 with new python 3.8 venv,it run successfully in a test environment. I am wondering how the new version knows the the historical migration file. Should I copy the historical migration files from older python 3.7 venv to the new 3.8 venv first?</div>_______________________________________________<br>Pulp-list mailing list<br><a spellcheck="false"bbg-destination="mailto:rte:bind" class="" href="mailto:Pulp-list@redhat.com" data-destination="mailto:rte:bind">Pulp-list@redhat.com</a><br><a spellcheck="false"bbg-destination="rte:bind" class="" href="https://listman.redhat.com/mailman/listinfo/pulp-list"data-destination="rte:bind">https://listman.redhat.com/mailman/listinfo/pulp-list</a></blockquote></div><br><div><br></div>-- <br><div dir="ltr"><p style="color:rgb(0,0,0);font-family:RedHatText,sans-serif;font-weight:bold;margin:0px;padding:0px;font-size:14px;text-transform:capitalize"><span>Mike</span> <span>DePaulo</span></p><p style="color:rgb(0,0,0);font-family:RedHatText,sans-serif;font-size:12px;margin:0px 0px 4px;text-transform:capitalize">He / Him / His</p><p style="color:rgb(0,0,0);font-family:RedHatText,sans-serif;font-size:12px;margin:0px;text-transform:capitalize"><span>Service Reliability Engineer, Pulp</span></p><p style="color:rgb(0,0,0);font-family:RedHatText,sans-serif;margin:0px 0px 4px;font-size:12px"><a style="margin: 0px;"spellcheck="false" bbg-destination="https://www.redhat.com/" class="" href="https://www.redhat.com/" data-destination="https://www.redhat.com/">Red Hat</a></p><div style="color:rgb(0,0,0);font-family:RedHatText,sans-serif;font-size:medium;margin-bottom:4px"></div><p style="color:rgb(0,0,0);font-family:RedHatText,sans-serif;margin:0px;font-size:12px"><span>IM: <span>mikedep333</span></span></p><p style="color:rgb(0,0,0);font-family:RedHatText,sans-serif;font-size:12px;margin:0px"><span>GPG: 51745404</span></p><div style="color:rgb(0,0,0);font-family:RedHatText,sans-serif;font-size:medium;margin-top:12px"><table border="0"><tbody><tr><td width="100px"><a spellcheck="false" bbg-destination="https://www.redhat.com/" class="" href="https://www.redhat.com/"data-destination="https://www.redhat.com/"><img src="https://marketing-outfit-prod-images.s3-us-west-2.amazonaws.com/f5445ae0c9ddafd5b2f1836854d7416a/Logo-RedHat-Email.png"style="width: 90px;" width="90"></a></td></tr></tbody></table></div></div></div></blockquote><br></div></div></div></div></body></html>