PermissionError: [Errno 13] Permission denied: while creating doctype, and script reports

I have logged in as Administrator.

I have enabled developer mode and server_script_enabled site_config.json file

“developer_mode”: 1,
“server_script_enabled”: true

If I tried to create “Trail Doctype” doctype , while i try to save doctype it gives ,
PermissionError: [Errno 13] Permission denied: '/opt/bitnami/apps/erpnext/htdocs/frappe-bench/apps/erpnext/erpnext/accounts/doctype/trial_doctype;

I tried, sudo chown -R frappe:frappe *, it gives error : chown: invalid user: ‘frappe:frappe’

Is there a frappe user available?

I just tried , sudo chown -R frappe:frappe *, frappe user means users of erpnext hosted account?

User is, by ERPNEXT installed

Where I can get above user and group details

The primary user’s group is stored in the /etc/passwd file and the supplementary groups, if any, are listed in the /etc/group file.

I checked, frappe user is not listed in specified files.


sudo chmod -R 777 /opt/bitnami

Please mark as solutions if this helps.



After creating a standard script report, added filters in .js file it worked, but any changes in .py file it does not show in the report, not even a frappe print message.

Should i run any command with bench?

Make changes in standard js and css.

bench update --build

run bench update --build to update and build css

Hi, after running bench update --build , in frappe-bench directory it stuck at building frappe assets.

Hi, Still stuck at building frappe assets
Error: spawn ENOMEM

I checked for solution, building swap file, but i did not understand clearly how to do that,

Check if this is the case by running the command free -m

Look at the bottom, if total of 0 bytes swap memory. Not good. Node can get pretty memory hungry and if no swap space is available when memory runs out, errors are bound to happen.

The method for adding a swap file varies between operating systems and distributions, but if you’re running Ubuntu, you can follow these instructions on adding a swap file.

  1. sudo fallocate -l 2G /swapfile
    Create a 2 gigabyte swapfile
  2. sudo chmod 600 /swapfile
    Secure the swapfile by restricting access to root
  3. sudo mkswap /swapfile
    Mark the file as a swap space
  4. sudo swapon /swapfile
    Enable the swap
  5. echo “/swapfile none swap sw 0 0” | sudo tee -a /etc/fstab
    Persist swapfile over reboot

Also you can check following link.

1 Like

Thank you,

Try chown -R frappe:frappe /home/frappe