[function.unserialize]: Error at offset I initially came across this error while I migrated my site from local server to live server.

Notice: unserialize() [function.unserialize]: Error at offset 83 of 108 bytes in variable_initialize() (line 935 of /home/ebemorgi/kog.church/includes/bootstrap.inc).


I followed #9 from this drupal post , then I found out that
the variable causing the issue was authorize_filetransfer_connection_settings_ftp.

I deleted the above variable but that hung up my whole website.

Then I deleted the content in the variable table and re-populated it.
Initially the error didn't popup but when I tried installing a new module at the live server the error
popped up with an new offset value. Again the villain is authorize_filetransfer_connection_settings_ftp.
The error which I am now receiving is :

Notice: unserialize() [function.unserialize]: Error at offset 32 of 121 bytes in variable_initialize() (line 935 of /home/ebemorgi/kog.church/includes/bootstrap.inc).


I have made sure that I have updated the ftp details in my mysql dump file before importing it to live DB.

I'm not sure if this issue is related to Core, but I don't honestly know under which product to list it.

Any help is appreciated.
It looks as though you have invalid serialized data for that authorize_filetransfer_connection_settings_ftp variable.

If saving to the db manually, make sure you have serialized the data prior to db storage.

Some ways to set the variable include

variable_set('authorize_filetransfer_connection_settings_ftp', $value);

and

drush vset authorize_filetransfer_connection_settings_ftp 'value'

The former is a bit easier if setting an array value, otherwise you can do something like this with Drush:

drush php-eval 'variable_set("authorize_filetransfer_connection_settings_ftp",array("key1" =&gt; "value1", "key2" =&gt; "value2"));'