Web UI not loading properly

I did an easy installation on ubuntu 18.4 LTS. Setup was completed without any error. I am using AWS Lightsail. When I am using my public I.P, web UI is not working properly.

Also, I am using 1GB Memory with 40 GB Disk Space.

Please Help.

Same problem here
I donā€™t know is it related to lightsail or ubuntu version being 18.4, but i never had a problem with 18.4 before.

Help will be appreciated.

Thanks

can you both show the output of the browser console, maybe theres something useful

I actually faced the same error a while ago, because I restored the backup of an ERPNext version 13 server to version 12 server(which I installed through easy install script), to resolve this I updated the new server to the same version as of the old server and restored the backup again. Now everything is working fine.

some frappe files not exist in your site public files, error 404
try bench build

I tried it already. I am getting this:

WARN: bench is installed in editable mode!

This is not the recommended mode of installation for production. Instead, install the packa
ge from PyPI with: pip install frappe-bench

WARN: Command not being executed in bench directory

it says " Command not being executed in bench directory"
first enter frappe directory then execute bench build
try cd frappe-bench
then bench build

Facing the same issue on AWS EC2. Tried bench build and other stuff. Couldnā€™t find a solution. My old instances on EC2 works fine. Just new ones are going stripped of CSS.

I ran bench build successfully but the issue is still there.

Its mostly not about building the asset files, but its about nginx configuration.
check the configuration if you did manual install not using the easy install script

I installed it using an easy install script:
My steps:
sudo apt update
sudo apt -y upgrade
apt install python3-minimal build-essential python3-setuptools
sudo add user erpnext
sudo usermod -aG sudo erpnext
su erpnext
sudo wget https://raw.githubusercontent.com/frappe/bench/develop/install.py
sudo python3 install.py --production --verbose

I deployed it by creating a 2GB instance and now it is working fine.
I just want to know why it is creating a problem while deploying it in a 1 GB instance. Also, i have created a swap file, still it is of no use.

1 Like

remember that 404 error mean the file not found so it can be either bad nginx config or the file really not exist.

for example in the browser console it says 404 frappe-web.min.js not found so if you go to sites/assets/js and if this file is not in this folder that mean it is not nginx config problem but bench build faild probably due to low memory with 1GB, you can try to increase memory limit with:
export NODE_OPTIONS=ā€œā€“max-old-space-size=8192ā€
then run bench build, the file should be there and problem solved.

Actually, This installation incorrect / unusual, because you actually created a user erpnext and used it as a superuser to install frappe which in this case might install the software using incorrect permissions.

The best way to install it is actually by following the documentation step by step and make it easy with no or minimal modifications.

The usual user for bench is frappe and is created automatically by the installation file, you dont need to do more than that.

Are you using a custom Website Theme? When Iā€™ve had this issue in the past, Iā€™ve been able to solve it by rebuilding my custom theme doc, which can be done simply by editing and saving it.

Hi @peterg,

I have faced same issue.

Please help me
Thanks

The solution that worked with me is installing on a large memory instance 2GB for example

1 Like

Hi @A.Mas,

Thank you so much for help.

I have performed export NODE_OPTIONS="ā€“max-old-space-size=8192 but issue still replicated.

500 Internal Server Error is shown in web page console.

Thanks

one of the problem, is your account directory has no permission for other daemon access.

in my case, I just add the command
chmod o+x /home/frappe

frappe is my erpnext install account, you should change it base on your environment

3 Likes