Answers.Body: <p>Here's how we handled this:</p>
  <p>From within your extensions directory:</p>
  <pre><code>cv dis mosaicomsgtpl mosaico flexmailer
  rm -rf org.civicrm.flexmailer
  cv flush
  cv en flexmailer mosaico mosaicomsgtpl
  cv ext:up
  </code></pre>
  <p>We've found that Mosaico didn't release it's grip on Flexmailer services properly and interfered with the process of getting it to use the core-ext version!</p>
  <p>Since adding this to our upgrade step we haven't had any further issues.</p>
  <p>As pointed out by Pete from Fuzion you might not have <code>mosaicomsgtpl</code> installed. In that case your steps would look like this:</p>
  <pre><code>cv dis mosaico flexmailer
  rm -rf org.civicrm.flexmailer
  cv flush
  cv en flexmailer mosaico
  cv ext:up
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-07-07T22:31:29.680Z
Answers.Text: many folk may not have that first extension, so folk don't be surprised if you get "Ignoring unrecognized extension "mosaicomsgtpl""
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-07-07T22:32:10.620Z
Answers.Text: and therefore also do not bother with cv en mosaicomsgtpl either
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-09-20T15:53:24.840Z
Answers.Text: HI I'm trying to use this. It hasn't worked on my first go - both extensions are still appearing in the list of extensions even after I've refreshed the page. What does en stand for - I've googled but can't find an answer. thanks
Answers.UserDisplayName: Caroline B
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-09-20T17:24:25.907Z
Answers.Text: It’s a shortcut for ext:enable
Answers.UserDisplayName: HomoTechsual
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-23T15:34:14.820Z
Answers.LastActivityDate: 2021-08-26T13:14:19.247Z
Answers.LastEditDate: 2021-08-26T13:14:19.247Z
Answers.UserDisplayName: HomoTechsual
Answers.Body: <p>Here's how I did it: <em>Delete the cache files</em></p>
  <p>From within the site's extensions dir:</p>
  <pre><code>EXT_DIR=/var/www/mysite.org/sites/default/files/civicrm/ext/
  CONFIG_AND_LOG_DIR=/var/www/mysite.org/sites/default/files/civicrm/ConfigAndLog
  BACKUP_DIR=~/just-in-case
  
  mkdir -p &quot;$BACKUP_DIR&quot;
  mv org.civicrm.flexmailer $BACKUP_DIR/.
  cd $CONFIG_AND_LOG_DIR
  rm Cache* # Remove cached container/ExtLoader files.
  cv flush # runs cleanly
  cv ext:upgrade-db
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-22T12:23:22.563Z
Answers.Text:  Thank you for documenting.
Answers.UserDisplayName: KarinG - Semper IT
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-22T15:04:24.837Z
Answers.Text: @KarinG-SemperIT yeah, annoyingly that's not working on another site (a busier site, I think it's a race thing)! So better answers welcome!
Answers.UserDisplayName: artfulrobot
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-23T16:41:38.843Z
Answers.Text: @HomoTechsual's answer worked for me! https://civicrm.stackexchange.com/a/39149/35
Answers.UserDisplayName: artfulrobot
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-22T07:15:55.183Z
Answers.LastActivityDate: 2021-03-22T15:04:52.320Z
Answers.LastEditDate: 2021-03-22T15:04:52.320Z
Answers.UserDisplayName: artfulrobot
Body: <p>I have Flexmailer 1.1.1 installed as a &quot;non-core&quot; extension , but since upgrading to 5.35.1 Flexmailer 1.1.2 is included with core. (This probably came in before 5.35.)</p>
  <p>The extensions page shows 1.1.1, implying the newer core version is not in use.</p>
  <ul>
  <li><p>I thought that if I removed the non-core extension dir Civi would have a hunt around and find the core version, but when I removed that dir, CiviCRM crashed complaining that it can't find it.</p>
  </li>
  <li><p>I thought that if I disabled the extension then it might find the new one, but disabling flexmailer requires disabling mosaico, too, since it's a dependency. And disabling that would also require disabling mosaicomsgtpl too. I'm a bit worried that disabling extensions might lose some configuration values along the way, which I might not notice until it's too late?!</p>
  </li>
  <li><p>I thought that I could symlink from the old location to the new core location, but again this causes a crash:</p>
  <pre><code>[Symfony\Component\Debug\Exception\FatalThrowableError] 
  Class 'Civi\FlexMailer\Services' not found              
  </code></pre>
  </li>
  <li><p>I thought I remembered that the filepath to an extension was in the db somewhere, but I searched and only found a reference to it in <code>civicrm_extension</code> - that table does not seem to have filepaths in it.</p>
  </li>
  </ul>
  
Tags: <extension><upgrade><flexmailer>
Title: CiviCRM core now includes Flexmailer: how to remove old flexmailer extension?
ThreadText: # CiviCRM core now includes Flexmailer: how to remove old flexmailer extension?
  
  (Asked by: username_0 on 2021-03-22)
  
  I have Flexmailer 1.1.1 installed as a "non-core" extension , but since upgrading to 5.35.1 Flexmailer 1.1.2 is included with core. (This probably came in before 5.35.)
  
  The extensions page shows 1.1.1, implying the newer core version is not in use.
  
  * I thought that if I removed the non-core extension dir Civi would have a hunt around and find the core version, but when I removed that dir, CiviCRM crashed complaining that it can't find it.
  * I thought that if I disabled the extension then it might find the new one, but disabling flexmailer requires disabling mosaico, too, since it's a dependency. And disabling that would also require disabling mosaicomsgtpl too. I'm a bit worried that disabling extensions might lose some configuration values along the way, which I might not notice until it's too late?!
  * I thought that I could symlink from the old location to the new core location, but again this causes a crash:
  
    ```
    [Symfony\Component\Debug\Exception\FatalThrowableError] 
    Class 'Civi\FlexMailer\Services' not found              
  
    ```
  * I thought I remembered that the filepath to an extension was in the db somewhere, but I searched and only found a reference to it in `civicrm_extension` - that table does not seem to have filepaths in it.
  
  **Tags:** extension, upgrade, flexmailer
  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_1 on 2021-03-23. Score: 7 | Accepted answer
  
  Here's how we handled this:
  
  From within your extensions directory:
  
  ```
  cv dis mosaicomsgtpl mosaico flexmailer
  rm -rf org.civicrm.flexmailer
  cv flush
  cv en flexmailer mosaico mosaicomsgtpl
  cv ext:up
  
  ```
  
  We've found that Mosaico didn't release it's grip on Flexmailer services properly and interfered with the process of getting it to use the core-ext version!
  
  Since adding this to our upgrade step we haven't had any further issues.
  
  As pointed out by Pete from username_2 you might not have `mosaicomsgtpl` installed. In that case your steps would look like this:
  
  ```
  cv dis mosaico flexmailer
  rm -rf org.civicrm.flexmailer
  cv flush
  cv en flexmailer mosaico
  cv ext:up
  
  ```
  
  > **Comments:**
  > **username_2**: many folk may not have that first extension, so folk don't be surprised if you get "Ignoring unrecognized extension "mosaicomsgtpl""  
  > **username_2**: and therefore also do not bother with cv en mosaicomsgtpl either  
  > **username_3**: HI I'm trying to use this. It hasn't worked on my first go - both extensions are still appearing in the list of extensions even after I've refreshed the page. What does en stand for - I've googled but can't find an answer. thanks  
  > **username_1**: It’s a shortcut for ext:enable  
  
  ---
  
  ### Answer by username_0 on 2021-03-22. Score: 3
  
  Here's how I did it: *Delete the cache files*
  
  From within the site's extensions dir:
  
  ```
  EXT_DIR=/var/www/mysite.org/sites/default/files/civicrm/ext/
  CONFIG_AND_LOG_DIR=/var/www/mysite.org/sites/default/files/civicrm/ConfigAndLog
  BACKUP_DIR=~/just-in-case
  
  mkdir -p "$BACKUP_DIR"
  mv org.civicrm.flexmailer $BACKUP_DIR/.
  cd $CONFIG_AND_LOG_DIR
  rm Cache* # Remove cached container/ExtLoader files.
  cv flush # runs cleanly
  cv ext:upgrade-db
  
  ```
  
  > **Comments:**
  > **username_4**:  Thank you for documenting.  
  > **username_0**: @username_4 yeah, annoyingly that's not working on another site (a busier site, I think it's a race thing)! So better answers welcome!  
  > **username_0**: @username_1's answer worked for me! https://civicrm.stackexchange.com/a/39149/35  
  
  ---
  
  