This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

jonathanmaloy
jonathanmaloy

I get this error:

exception 'ErrorException' with message 'unserialize(): Error at offset 44299 of 44308 bytes' in /***********/vendor/laravel/framework/src/Illuminate/Cache/FileStore.php:79

The weird part is that it only happens once a week (Saturday morning in this case) and fixes itself after a few minutes. I think I also tried clearing cache one weekend and it work immediately after. Any help would be appreciated. If you need more information please ask.

This is the line of code I am calling the seems to cause it:

$mediaList = MediaLibrary::instance()->listFolderContents($folder,'title','image');

Stack trace:

#0 [internal function]: Illuminate\Foundation\Bootstrap\HandleExceptions->handleError(8, 'unserialize(): ...', '/***********/...', 79, Array)
#1 /***********/vendor/laravel/framework/src/Illuminate/Cache/FileStore.php(79): unserialize('s:44290:"a:54:{...')
#2 /***********/vendor/laravel/framework/src/Illuminate/Cache/FileStore.php(44): Illuminate\Cache\FileStore->getPayload('cms-media-libra...')
#3 /***********/vendor/laravel/framework/src/Illuminate/Cache/Repository.php(95): Illuminate\Cache\FileStore->get('cms-media-libra...')
#4 [internal function]: Illuminate\Cache\Repository->get('cms-media-libra...', false)
#5 /***********/vendor/laravel/framework/src/Illuminate/Cache/CacheManager.php(312): call_user_func_array(Array, Array)
#6 /***********/vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php(213): Illuminate\Cache\CacheManager->__call('get', Array)
#7 /***********/vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php(213): Illuminate\Cache\CacheManager->get('cms-media-libra...', false)
#8 /***********/modules/cms/classes/MediaLibrary.php(92): Illuminate\Support\Facades\Facade::__callStatic('get', Array)
#9 /***********/modules/cms/classes/MediaLibrary.php(92): Illuminate\Support\Facades\Cache::get('cms-media-libra...', false)
#10 /***********/plugins/jonathanmaloy/sliders/components/SmallSlider.php(48): Cms\Classes\MediaLibrary->listFolderContents('/beachside-smal...', 'title', 'image')

Last updated

dazmiller8556
dazmiller8556

Do you have an artisan cache:clear command scheduled to run around that time?

Using https://laravel-news.com/2014/11/laravel-5-scheduler/ or https://github.com/Indatus/dispatcher/blob/master/README.md or something similar that is clearing your file cache as your code is running.

Seems strange happens same time. Would appear to be a scheduled job. Otherwise are you on a shared host, is their some backup procedure or something running at that time that is causing files to be locked?

jonathanmaloy
jonathanmaloy

I myself did not add any scheduled jobs. Not sure if October has any or any of the third party plugins I have installed. Is there a way to see all scheduled jobs?

Amazon EC2. No backups at that time or anything else that would cause the file to be locked that I can find.

dazmiller8556
dazmiller8556

Maybe here http://octobercms.com/docs/plugin/registration#scheduled-tasks

or

http://octobercms.com/docs/help/installation#crontab-setup

or some info on laravel scheduling

http://laravel.com/docs/master/scheduling

If you can try a find in files and check for registerSchedule and see if any plugins are adding anything.

Last updated

1-4 of 4

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.