Installation on LightSail

Hi. I am new and just getting started. I read about SuiteCRM and wanted to test it out.

I setup new server on AWS lightSail
Linux + LAMP instance
its running bitnami

I got the server setup done, domain & SSL working. Got MariaDB username, password & DB created.

but when i open the URL, all i see is list of files. not the installer.
I have done the file permission commands, and set the directory to /public

any help would be great. below are the screen shot.

file permission on server

Check the default_permission in your config.php file. Also, ‘host_name’ & ‘site_url’ in the same file.

‘default_permissions’ =>
array (
‘dir_mode’ => ‘1533’,
‘file_mode’ => ‘436’,
‘user’ => ‘www-data’,
‘group’ => ‘www-data’,
),

If your user is bitnami then you need to use below command inside suitecrm folder.

chown -R bitnami:bitnami .

Also, it need to be same in your web server,

hi. Sorry i forgot to state that i downloaded the latest SuiteCRM 8.6. should i install SuiteCRM 7.14 instead?

on V8, I have done

find . -type d -not -perm 2755 -exec chmod 2755 {} ;
find . -type f -not -perm 0644 -exec chmod 0644 {} ;
find . ! -user bitnami -exec chown bitnami:bitnami {} ;
chmod +x bin/console

from Downloading & Installing :: SuiteCRM Documentation

but still nothing changed

ok. maybe V8 isnt for me. I moved them files to another folder and did the following

wget https://suitecrm.com/download/141/suite714/563700/suitecrm-7-14-3.zip
unzip suitecrm-7-14-3.zip
sudo chown -R bitnami:bitnami .
sudo chmod -R 755 .
sudo chmod -R 775 cache custom modules themes data upload
sudo chmod 775 config_override.php 2>/dev/null

I checked php.ini file and session.name = PHPSESSID is there

And i went to browser and i get “HTTP ERROR 500”
I followed all the steps from Downloading & Installing :: SuiteCRM Documentation

is there any log file that i can share for you guys?

Sorry, there was no suitecrm.log in the base folder. this is the permission of the files.
also i cant see config.php file either.

this is what i got my apache httpd log.

[Wed May 15 19:21:16.310205 2024] [proxy_fcgi:error] [pid 1675:tid 139796110223104] [client 51.89.5.185:59940] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaught
Exception: SuiteCRM is not installed. Entry point needs an installed SuiteCRM, please install first. in /opt/bitnami/apache/htdocs/include/entryPoint.php:59\nStack trace:
n#0 /opt/bitnami/apache/htdocs/index.php(47): require_once()\n#1 {main}\n thrown in /opt/bitnami/apache/htdocs/include/entryPoint.php on line 59’
[Wed May 15 19:21:31.879584 2024] [proxy_fcgi:error] [pid 2100:tid 139796513404672] [client 119.235.84.12:63754] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaugh
t TypeError: fwrite(): Argument #1 ($stream) must be of type resource, bool given in /opt/bitnami/apache/htdocs/install/install_utils.php:732\nStack trace:\n#0 /opt/bitnam
i/apache/htdocs/install/install_utils.php(732): fwrite()\n#1 /opt/bitnami/apache/htdocs/install/install_utils.php(64): installLog()\n#2 /opt/bitnami/apache/htdocs/install.
php(827): installerHook()\n#3 {main}\n thrown in /opt/bitnami/apache/htdocs/install/install_utils.php on line 732’
[Wed May 15 19:23:21.744815 2024] [proxy_fcgi:error] [pid 1675:tid 139796362004224] [client 94.156.79.9:34516] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaught
Exception: SuiteCRM is not installed. Entry point needs an installed SuiteCRM, please install first. in /opt/bitnami/apache/htdocs/include/entryPoint.php:59\nStack trace:
n#0 /opt/bitnami/apache/htdocs/index.php(47): require_once()\n#1 {main}\n thrown in /opt/bitnami/apache/htdocs/include/entryPoint.php on line 59’
[Wed May 15 20:34:42.734088 2024] [proxy_fcgi:error] [pid 1674:tid 139796303255296] [client 162.216.150.153:63240] AH01071: Got error ‘PHP message: PHP Fatal error: Uncau
ght Exception: SuiteCRM is not installed. Entry point needs an installed SuiteCRM, please install first. in /opt/bitnami/apache/htdocs/include/entryPoint.php:59\nStack tra
ce:\n#0 /opt/bitnami/apache/htdocs/index.php(47): require_once()\n#1 {main}\n thrown in /opt/bitnami/apache/htdocs/include/entryPoint.php on line 59’, referer: http://MYURL/
[Wed May 15 20:34:43.352469 2024] [proxy_fcgi:error] [pid 1675:tid 139796059866880] [client 162.216.150.153:63244] AH01071: Got error ‘PHP message: PHP Fatal error: Uncau
ght TypeError: fwrite(): Argument #1 ($stream) must be of type resource, bool given in /opt/bitnami/apache/htdocs/install/install_utils.php:732\nStack trace:\n#0 /opt/bitn
ami/apache/htdocs/install/install_utils.php(732): fwrite()\n#1 /opt/bitnami/apache/htdocs/install/install_utils.php(64): installLog()\n#2 /opt/bitnami/apache/htdocs/instal
l.php(827): installerHook()\n#3 {main}\n thrown in /opt/bitnami/apache/htdocs/install/install_utils.php on line 732’
[Wed May 15 20:35:36.892584 2024] [proxy_fcgi:error] [pid 1674:tid 139796286469888] [client 104.164.195.91:29379] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaug
ht Exception: SuiteCRM is not installed. Entry point needs an installed SuiteCRM, please install first. in /opt/bitnami/apache/htdocs/include/entryPoint.php:59\nStack trac
e:\n#0 /opt/bitnami/apache/htdocs/index.php(47): require_once()\n#1 {main}\n thrown in /opt/bitnami/apache/htdocs/include/entryPoint.php on line 59’
[Wed May 15 20:35:37.036575 2024] [proxy_fcgi:error] [pid 1674:tid 139796278077184] [client 104.164.195.91:29379] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaug
ht TypeError: fwrite(): Argument #1 ($stream) must be of type resource, bool given in /opt/bitnami/apache/htdocs/install/install_utils.php:732\nStack trace:\n#0 /opt/bitna
mi/apache/htdocs/install/install_utils.php(732): fwrite()\n#1 /opt/bitnami/apache/htdocs/install/install_utils.php(64): installLog()\n#2 /opt/bitnami/apache/htdocs/install
.php(827): installerHook()\n#3 {main}\n thrown in /opt/bitnami/apache/htdocs/install/install_utils.php on line 732’
[Wed May 15 21:29:49.758539 2024] [proxy_fcgi:error] [pid 2100:tid 139795271509760] [client 119.235.99.36:64267] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaugh
t TypeError: fwrite(): Argument #1 ($stream) must be of type resource, bool given in /opt/bitnami/apache/htdocs/install/install_utils.php:732\nStack trace:\n#0 /opt/bitnam
i/apache/htdocs/install/install_utils.php(732): fwrite()\n#1 /opt/bitnami/apache/htdocs/install/install_utils.php(64): installLog()\n#2 /opt/bitnami/apache/htdocs/install.
php(827): installerHook()\n#3 {main}\n thrown in /opt/bitnami/apache/htdocs/install/install_utils.php on line 732’
[Wed May 15 21:44:24.437904 2024] [proxy_fcgi:error] [pid 2100:tid 139795254724352] [client 119.235.99.36:64522] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaugh
t TypeError: fwrite(): Argument #1 ($stream) must be of type resource, bool given in /opt/bitnami/apache/htdocs/install/install_utils.php:732\nStack trace:\n#0 /opt/bitnam
i/apache/htdocs/install/install_utils.php(732): fwrite()\n#1 /opt/bitnami/apache/htdocs/install/install_utils.php(64): installLog()\n#2 /opt/bitnami/apache/htdocs/install.
php(827): installerHook()\n#3 {main}\n thrown in /opt/bitnami/apache/htdocs/install/install_utils.php on line 732’
[Wed May 15 21:44:26.456082 2024] [proxy_fcgi:error] [pid 2100:tid 139795237938944] [client 119.235.99.36:64523] AH01071: Got error ‘PHP message: PHP Fatal error: Uncaugh
t TypeError: fwrite(): Argument #1 ($stream) must be of type resource, bool given in /opt/bitnami/apache/htdocs/install/install_utils.php:732\nStack trace:\n#0 /opt/bitnam
i/apache/htdocs/install/install_utils.php(732): fwrite()\n#1 /opt/bitnami/apache/htdocs/install/install_utils.php(64): installLog()\n#2 /opt/bitnami/apache/htdocs/install.
php(827): installerHook()\n#3 {main}\n thrown in /opt/bitnami/apache/htdocs/install/install_utils.php on line 732’

I think you will find those files under public/ or public/legacy/ folders

I dont see public or legacy folder

ok this solution worked.

sudo chown -R daemon:daemon .
sudo chmod -R 755 .
sudo chmod -R 775 cache custom modules themes data upload
sudo chmod 775 config_override.php 2>/dev/null

Oh that’s good! So, it was ownership issue. :smiley:

Yes i believe so. I will try to load V8 again and see how it does since i went down to V7

Yeah you should try with v8 too.

Good. On the Bitnami docker containers, the username:group are daemon:daemon.

When the file or directory permissions or ownership are crashing the app, you see these errors in the log:

AH01071: Got error ‘PHP message: PHP Fatal error: Uncaught Exception: 
SuiteCRM is not installed. 
Entry point needs an installed SuiteCRM, please install first. 
in /opt/bitnami/apache/htdocs/include/entryPoint.php:59
Stack trace:
#0 /opt/bitnami/apache/htdocs/index.php(47): require_once()
#1 {main}
 thrown in /opt/bitnami/apache/htdocs/include/entryPoint.php on line 59’

AH01071: Got error ‘PHP message: PHP Fatal error: Uncaught TypeError: 
fwrite(): Argument #1 ($stream) must be of type resource, 
bool given in /opt/bitnami/apache/htdocs/install/install_utils.php:732
Stack trace:
#0 /opt/bitnami/apache/htdocs/install/install_utils.php(732): fwrite()
#1 /opt/bitnami/apache/htdocs/install/install_utils.php(64): installLog()
#2 /opt/bitnami/apache/htdocs/install.php(827): installerHook()
#3 {main}
 thrown in /opt/bitnami/apache/htdocs/install/install_utils.php on line 732’
1 Like

Easy improvement to the app’s install algorithm: Before writing to the install log, which is the first time the app tries to write to the app directory, check the type of the opened file’s $stream, if it’s not the expected type, a resource, then stop the install, and attempt to fix the permissions and ownership. To do this, check if the app has enough permissions to fix permissions by itself, and if yes, run the 4 commands to fix the permissions and ownership, and verify they worked without error. If either the app doesn’t have enough permissions to fix permissions, or the commands to fix the permissions failed, tell the user “permissions and ownership are incorrect”, and show the 4 commands the admin should run to fix the problem.

2 Likes

Could you please add this to suggestion box :upside_down_face: :inbox_tray: