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

No delivery service prefix after upgrading to 2.2 #1630

Closed
smalenfant opened this issue Dec 8, 2017 · 8 comments · Fixed by #1633
Closed

No delivery service prefix after upgrading to 2.2 #1630

smalenfant opened this issue Dec 8, 2017 · 8 comments · Fixed by #1633
Labels
bug something isn't working as intended high impact impacts the basic function, deployment, or operation of a CDN Traffic Ops related to Traffic Ops
Milestone

Comments

@smalenfant
Copy link
Contributor

Upgraded to 2.2 and lost all my delivery service prefixes (edge,tr). Looking at the code, seems like dbadmin never gets invoked with patch so the patches.sql never gets run.

@smalenfant smalenfant added bug something isn't working as intended critical Traffic Ops related to Traffic Ops labels Dec 8, 2017
@smalenfant smalenfant added this to the 2.2.0 milestone Dec 8, 2017
@smalenfant
Copy link
Contributor Author

As a workaround, please run this after upgrade.

# export PERL5LIB=/opt/traffic_ops/app/lib:/opt/traffic_ops/app/local/lib/perl5
# cd /opt/traffic_ops/app
# ./db/admin.pl --env=production patch

@smalenfant
Copy link
Contributor Author

In addition, seems like setting upgrade_http_routing_name doesn't work as intended. That should be a separate issue but it's part of the same process. I've tried putting my customer name parameter on the CCR, Edge and DS Profile, but still ended with tr.

smalenfant pushed a commit to smalenfant/trafficcontrol that referenced this issue Dec 8, 2017
@rawlinp
Copy link
Contributor

rawlinp commented Dec 8, 2017

Originally the DB upgrade step was attempted during the yum upgrade traffic_ops step, but it always failed due to the way PATH was hardcoded. So I took it out and documented it as a required manual step (#871) because our ops team had become accustomed to doing that step manually already due to it failing in the yum upgrade traffic_ops step. It doesn't show up on the latest published docs yet I'm guessing because 2.1 hasn't been released yet, but this is in master:

Upgrading Traffic Ops
To upgrade:

  1. Enter the following command: service traffic_ops stop
  2. Enter the following command: yum upgrade traffic_ops
  3. Enter the following command from the /opt/traffic_ops/app directory: PERL5LIB=/opt/traffic_ops/app/lib:/opt/traffic_ops/app/local/lib/perl5 ./db/admin.pl --env production upgrade
  4. See Traffic Ops - Installing to run postinstall.
  5. Enter the following command: service traffic_ops start

I know having another required manual step is not ideal, so it would probably be worth it to fix the yum upgrade traffic_ops step to upgrade the DB properly and remove the manual step. It would just require fixing the migratedb script to use the PATH where goose should be installed, but I believe the location of the goose binary install had changed at least once, which was basically a breaking change for migratedb. So it's safest to just run it manually where hopefully the goose binary will be found on your PATH (in case it was installed in a previous location).

About upgrade_http_routing_name not working as intended, I'm really curious as to why. The profile you're assigning it to is associated to a CDN right? Do you have the fields mixed up? Parameter details should look like this:

Name: upgrade_http_routing_name
Config File: temp
Value: <insert custom routing name here>

Used in the following profiles:
FOO_TR_PROFILE          TR profile for the FOO cdn

And the Profile details for FOO_TR_PROFILE should have a valid CDN name in the CDN field.

@smalenfant
Copy link
Contributor Author

I just found out why the upgrade_http_routing_name didn't work. There was a blank space in front of it, so the SQL query would never find it. That's all good now.

@smalenfant smalenfant assigned smalenfant and unassigned smalenfant Dec 8, 2017
@rawlinp
Copy link
Contributor

rawlinp commented Dec 8, 2017

Sweet, good to know.

@mitchell852
Copy link
Member

@smalenfant - can this be closed?

@smalenfant
Copy link
Contributor Author

@mitchell852 Can we merge #1633 ?

@mitchell852
Copy link
Member

oh ok, didn't realize there was a PR attached to this issue. i need to look closer in the future. looking at PR...

dangogh pushed a commit that referenced this issue Dec 19, 2017
@mitchell852 mitchell852 added the high impact impacts the basic function, deployment, or operation of a CDN label Nov 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something isn't working as intended high impact impacts the basic function, deployment, or operation of a CDN Traffic Ops related to Traffic Ops
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants