Problem/Motivation
I was experimenting with config management on my local PC. I use Opensuse 13.2. Reproduce problem as follows
- Install standard D8 to http://testserver/d8t1 with database d8t1
- Copy site to second site http://testserver/d8t2 with database d8t2 as per https://www.drupal.org/node/2416545
- Copy database d8t1 to d8t2 with phpMyAdmin
- Copy files with a file manager from d8t1 directory to d8t2 directory
- Adjust one line in settings.php of d8t2 to point to d8t2 databse
- Within d8t2 site, toolbar items on both lines point to d8t1 site - This is an error
- Other links, such as bread crumbs or links within page, point correctly to d8t2
- I have not found a "rebuild menu" link in standard drupal
- Drush cache-rebuild solves problem
Proposed resolution
Determine why main links are updated and toolbar links are not. The inconsistency is a problem in itself
Edit documentation about site copying if toolbar can't be fixed
Remaining tasks
(reviews needed, tests to be written or run, documentation to be written, etc.)
User interface changes
(New or changed features/functionality in the user interface, modules added or removed, changes to URL paths, changes to user interface text.)
API changes
(API changes/additions that would affect module, install profile, and theme developers, including examples of before/after code if appropriate.)
Data model changes
(Database or configuration data changes that would make stored data on an existing site incompatible with the site's updated codebase, including changes to hook_schema(), configuration schema or keys, or the expected format of stored data, etc.)
Original report by [username]
(Text of the original report, for legacy issues whose initial post was not the issue summary. Use rarely.)
Comments
Comment #2
cilefen CreditAttribution: cilefen commentedA better title would be "Toolbar renders absolute links", because if it rendered relative links, this problem would not exist.
This is somewhat related:
#1494670: References to CSS, JS, and similar files should be root-relative URLs: avoids mixed content warnings & fewer bytes to send
Comment #3
AFowle@cliefen If you know that to be the case, I should be happy to change it. However it seems to be a caching issue as well.
Comment #4
cilefen CreditAttribution: cilefen commentedI think I may be wrong about the relative links cure because these are subdirectory sites.
It isn't unusual to need a cache rebuild in Drupal when you move a site to a different URL. Whether or not that ought to be the case is debatable. I think update.php causes a a rebuild.
Comment #5
Chi CreditAttribution: Chi commentedIt's not a bug for me.
drush cr
is a required part of deployment process. Perhaps we should document this somewhere if it is not documented yet.Comment #6
Wim LeersActually, it would still exist: for sites installed in subdirectories. If the subdirectory differs on the two servers, the same problem will occur.Heh, exactly.
#5++
Please clear caches and check if you can still reproduce this.
Comment #10
quietone CreditAttribution: quietone as a volunteer commented@AFowle, thanks for experimenting!
The comment in #5 suggests that the solution is to clear the cache (a solution supported by #6), a step that was not in the referenced doc page in 2015. An instruction to clear the cache was added to Workflow using the Drupal UI in 2016 by kiamlaluno.
Closing this as fixed
Comment #11
apadernoTruly, it was added from joachim on September, 2016. I reverted a revision that added wrong changes.