<p>It ended up being an unserialization issue. After exporting the sql file, I updated it with the new domain. The serialization part within the craft_info table needs to have the correct character length in front of the domain. Fixing that fixed my problem.</p>

CC BY-SA 4.0
2019-02-12T04:22:16.643Z
2019-02-12T04:22:16.643Z
kinoli
<p>I'm trying to migrate to a server from my local environment. I keep getting Internal Server Error. I have the latest version of 3+ of CraftCMS. Everything works fine locally but on the server not so much. Here is what I'm seeing in my Craft log file.</p>

<pre><code>    2019-02-08 05:02:35 [-][-][-][error][yii\base\ErrorException:8] yii\base\ErrorException: unserialize(): Error at offset 352 of 93525 bytes in /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php:997
Stack trace:
#0 /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/web/ErrorHandler.php(76): yii\base\ErrorHandler-&gt;handleError(8, 'unserialize(): ...', '/home/kinolicli...', 997)
#1 [internal function]: craft\web\ErrorHandler-&gt;handleError(8, 'unserialize(): ...', '/home/kinolicli...', 997, Array)
#2 /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(997): unserialize('a:17:{s:12:"dat...', Array)
#3 /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(982): craft\services\ProjectConfig-&gt;_getStoredConfig()
#4 /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(912): craft\services\ProjectConfig-&gt;_getLoadedConfig()
#5 /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(227): craft\services\ProjectConfig-&gt;_getConfigurationFromYaml()
#6 /home/kinoliclients/public_html/jbbls/cms/vendor/yiisoft/yii2/base/BaseObject.php(109): craft\services\ProjectConfig-&gt;init()
#7 [internal function]: yii\base\BaseObject-&gt;__construct(Array)
</code></pre>

<p>The PHP log file gives a bit more information.</p>

<pre><code>[08-Feb-2019 13:36:48 UTC] PHP Notice:  unserialize(): Error at offset 352 of 93525 bytes in /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php on line 997
[08-Feb-2019 13:36:48 UTC] An Error occurred while handling another error:
TypeError: Return value of craft\services\ProjectConfig::_getStoredConfig() must be of the type array, boolean returned in /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php:997
Stack trace:
#0 /home/kinoliclients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(982): craft\services\ProjectConfig-&gt;_getStoredConfig()
</code></pre>

<p>Also, just for context. I had the site running on the remote server but then did an update (the one that said, this is a difficult update). The update put it in a vegetative state (internal server error). The same update worked locally, so I then copied the files and database to the remote server hoping that would fix the issue remotely. However, it didn't. Was their a new PHP extension requirement or something, that might have done this?</p>

CC BY-SA 4.0
2019-02-08T14:18:21.057Z
Fly by guess: have you checked if a YAML file was created for projects and if this exists in both places?
joomkit
CC BY-SA 4.0
2019-02-09T00:13:55.067Z
No, their is no YAML file. Does PHP read that for something? I don't have that file locally where everything works, so I can't imagine that's the issue.
kinoli
CC BY-SA 4.0
2019-02-11T03:21:19.427Z
Try clearing out the Craft `storage/runtime/cache` folder.
Brad Bell
<craft3>
Internal Server Error while migrating to new server
# Internal Server Error while migrating to new server

(Asked by: username_0 on 2019-02-08)

I'm trying to migrate to a server from my local environment. I keep getting Internal Server Error. I have the latest version of 3+ of CraftCMS. Everything works fine locally but on the server not so much. Here is what I'm seeing in my Craft log file.
    2019-02-08 05:02:35 [-][-][-][error][yii\base\ErrorException:8] yii\base\ErrorException: unserialize(): Error at offset 352 of 93525 bytes in /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php:997
Stack trace:
#0 /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/web/ErrorHandler.php(76): yii\base\ErrorHandler->handleError(8, 'unserialize(): ...', '/home/username_0cli...', 997)
#1 [internal function]: craft\web\ErrorHandler->handleError(8, 'unserialize(): ...', '/home/username_0cli...', 997, Array)
#2 /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(997): unserialize('a:17:{s:12:"dat...', Array)
#3 /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(982): craft\services\ProjectConfig->_getStoredConfig()
#4 /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(912): craft\services\ProjectConfig->_getLoadedConfig()
#5 /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(227): craft\services\ProjectConfig->_getConfigurationFromYaml()
#6 /home/username_0clients/public_html/jbbls/cms/vendor/yiisoft/yii2/base/BaseObject.php(109): craft\services\ProjectConfig->init()
#7 [internal function]: yii\base\BaseObject->__construct(Array)

The PHP log file gives a bit more information.
[08-Feb-2019 13:36:48 UTC] PHP Notice:  unserialize(): Error at offset 352 of 93525 bytes in /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php on line 997
[08-Feb-2019 13:36:48 UTC] An Error occurred while handling another error:
TypeError: Return value of craft\services\ProjectConfig::_getStoredConfig() must be of the type array, boolean returned in /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php:997
Stack trace:
#0 /home/username_0clients/public_html/jbbls/cms/vendor/craftcms/cms/src/services/ProjectConfig.php(982): craft\services\ProjectConfig->_getStoredConfig()

Also, just for context. I had the site running on the remote server but then did an update (the one that said, this is a difficult update). The update put it in a vegetative state (internal server error). The same update worked locally, so I then copied the files and database to the remote server hoping that would fix the issue remotely. However, it didn't. Was their a new PHP extension requirement or something, that might have done this?

**Tags:** craft3

> **Comments:**
> **username_1**: Fly by guess: have you checked if a YAML file was created for projects and if this exists in both places?  
> **username_0**: No, their is no YAML file. Does PHP read that for something? I don't have that file locally where everything works, so I can't imagine that's the issue.  
> **username_2**: Try clearing out the Craft `storage/runtime/cache` folder.  

---

## 1 answers

### Answer by username_0 on 2019-02-12. Score: 1

It ended up being an unserialization issue. After exporting the sql file, I updated it with the new domain. The serialization part within the craft\_info table needs to have the correct character length in front of the domain. Fixing that fixed my problem.


---

