• Welcome to the Chevereto user community!

    Here users from all over the world gather around to learn the latest about Chevereto and contribute with ideas to improve the software.

    Please keep in mind:

  • Chevereto Support CLST

    Support response

    Support checklist

    • Got a Something went wrong message? Read this guide and provide the actual error. Do not skip this.
    • Confirm that the server meets the System Requirements
    • Check for any available Hotfix - your issue could be already reported/fixed
    • Read documentation - It will be required to Debug and understand Errors for a faster support response

JSON Error installing for the first time.

jeffrose

Chevereto Member
🎯Description of the issue

During a new install of 3.13.3, the installation fails with an error: Unexpected token < in JSON at position 0, during the Creating app/settings.php file step.

▶🚶‍Reproduction steps
  1. I downloaded installer.php from the site and ran it.
  2. Digital Ocean: PHP 7.0.33-0ubuntu0.16.04.5 with Apache
  3. Apache/2.4.18 (Ubuntu)
😢Unexpected result

2385

📃Error log message

[Provide any relevant error log entry. You may check our documentation for help on this]
 
Can you paste the contents of the installer error log file? You will find it in the same folder where you placed the installer.
 
Thanks for the reply Rodolfo, sorry for the delay in getting back.

There was no log file, so I deleted all the content and reinserted the installer.php and ran it again this morning. Same result, but no log file.

I may go the manual installer route if you don't have any suggestions. Not a big deal.
 

Attachments

  • Screen Shot 2019-07-08 at 10.38.13 AM.png
    Screen Shot 2019-07-08 at 10.38.13 AM.png
    323 KB · Views: 2
When you run the installer, it attempts to use its own error log file. If it can't do that is because your server isn't allowing to set the error_log file. In that case, check the main error_log file generated by your server.

By the way, I didn't added a error handler for the installer, so anytime PHP fails to do something, the return is not JSON and that's why JS prints that to the screen.

This is how the installer sets how it will handle error reporting:

PHP:
$phpSettings = [
    'error_reporting' => E_ALL ^ E_NOTICE,
    'log_errors' => true,
    'display_errors' => true,
    'error_log' => __DIR__.'/installer.error.log',
    'time_limit' => 0,
    'default_charset' => 'utf-8',
    'LC_ALL' => 'en_US.UTF8',
];
 
There's only 1 line added to the error log when it runs:

Code:
/home/jeffrose/public_html/photos/.htaccess: Option FollowSymLinks not allowed here, referer: https://jeffrose.ca/photos/installer.php

There's something on Digital Ocean I read about why the FollowSymLinks isn't allowed or how to allow it, but I can't remember where I saw that. If this is the core of the problem, then I can research it further.
 
In any case, neither the installer or the manual install will work for you because your vhost settings don't allow FollowSymLinks.

To get it working, you need to to manual install and remove this from .htaccess

Code:
Options +FollowSymLinks
 
Thanks. I'll try that. Removing it after the auto-install obviously doesn't work.

I have other servers I can use too, that might be the route I'll take.
 
Back
Top