Ad Widget

Collapse

Insufficient file system permissions. Assets cache directory is not writable.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Insufficient file system permissions. Assets cache directory is not writable.

    After updating zabbix and restarting the system I got this error message, when trying to open the web interface.
    Insufficient file system permissions. Assets cache directory is not writable. <retry>
    I can not access the zabbix interface. Where can I find the Assets Cache Directory?
    Refers to version 4.0.8-1+bionic

    SOLVED:
    sudo chmod -R 777 /usr/share/zabbix/assets
    Last edited by ma-kom; 28-05-2019, 15:55.

    #2
    Great, that did the trick. Adding the web server's user to the group of the assets directory would also do the trick, I guess.

    Had another issue though after the update to version 4.0.8-1+bionic, all graphs did show without text. I found out that it had to do with a missing font file in the assets/fonts folder. Any ttf will do, I copied DejaVuSans to the default name graphfont, so I didn't have to edit the defines.inc.php file as suggested here: https://www.zabbix.com/forum/zabbix-...s-missing-text

    /usr/share/fonts/truetype/dejavu/DejaVuSans.ttf /usr/share/zabbix/assets/fonts/graphfont.ttf

    Comment


      #3
      ln -s /usr/share/zabbix/fonts/graphfont.ttf /usr/share/zabbix/assets/fonts/

      Comment


        #4
        I am currently running CentOS 7, Zabbix updated these four packages last night and no longer able to access the log in page as i see the same error message above.

        May 29 03:24:38 Updated: zabbix-web-mysql.noarch 4.0.8-1.el7
        May 29 03:24:40 Updated: zabbix-web.noarch 4.0.8-1.el7
        May 29 03:24:41 Updated: zabbix-server-mysql.x86_64 4.0.8-1.el7
        May 29 03:24:41 Updated: zabbix-agent.x86_64 4.0.8-1.el7


        I have tried changing the permissions to 777 and changing the owner to apache but this makes no difference for my setup.

        Comment


          #5
          Originally posted by ma-kom View Post
          SOLVED:
          sudo chmod -R 777 /usr/share/zabbix/assets
          Works for me too. Thanks

          Comment


            #6
            I do had to set some SELinux permissions as well to get it working

            Comment


              #7
              Originally posted by Nevn View Post
              I do had to set some SELinux permissions as well to get it working
              Nevn, do you recall the commands/what you changed in regards to SELinux?

              Comment


              • Nevn
                Nevn commented
                Editing a comment
                ausearch -c 'httpd' --raw | audit2allow -M my-httpd
                semodule -i my-httpd.pp

                This is what I had to do.

              #8
              Wille chmod and selinux fixes are ok, no service should be writing in /usr. That's why /var has been invented ... Even the chmod itself should not be needed, it just means there's something wrong with the package.

              Comment


                #9
                This directory is only supposed to exist from Zabbix 4.2.2 so there is definitely an issue,
                I checked my backup and before the update there was no assets directory

                Click image for larger version

Name:	422.PNG
Views:	172
Size:	11.6 KB
ID:	379722
                Attached Files

                Comment


                  #10
                  On CentOS 7, I fix this issue by adding RW permission to apache by :
                  # setfacl -d -m apache:rwX /usr/share/zabbix/assets/
                  # setfacl -R -m apache:rwX /usr/share/zabbix/assets/

                  and Selinux problems by :
                  # semanage fcontext -a -t httpd_sys_rw_content_t "/usr/share/zabbix/assets(/.*)?"
                  # restorecon -R /usr/share/zabbix/assets

                  Comment


                    #11
                    Originally posted by ma-kom View Post
                    After updating zabbix and restarting the system I got this error message, when trying to open the web interface.
                    Insufficient file system permissions. Assets cache directory is not writable. <retry>
                    I can not access the zabbix interface. Where can I find the Assets Cache Directory?
                    Refers to version 4.0.8-1+bionic

                    SOLVED:
                    sudo chmod -R 777 /usr/share/zabbix/assets
                    My is CentOS7.
                    Solved for me. Thanks

                    Comment


                      #12
                      Originally posted by mustapha.aisssat View Post
                      On CentOS 7, I fix this issue by adding RW permission to apache by :
                      # setfacl -d -m apache:rwX /usr/share/zabbix/assets/
                      # setfacl -R -m apache:rwX /usr/share/zabbix/assets/

                      and Selinux problems by :
                      # semanage fcontext -a -t httpd_sys_rw_content_t "/usr/share/zabbix/assets(/.*)?"
                      # restorecon -R /usr/share/zabbix/assets
                      Thanks! This resolved my issue.

                      Comment


                        #13
                        Originally posted by mustapha.aisssat View Post
                        On CentOS 7, I fix this issue by adding RW permission to apache by :
                        # setfacl -d -m apache:rwX /usr/share/zabbix/assets/
                        # setfacl -R -m apache:rwX /usr/share/zabbix/assets/

                        and Selinux problems by :
                        # semanage fcontext -a -t httpd_sys_rw_content_t "/usr/share/zabbix/assets(/.*)?"
                        # restorecon -R /usr/share/zabbix/assets
                        Thanks mustapha.aisssat. Though this resolved the login issue for me, all of the graph labels were missing.

                        Since I'm not a fan of arbitrarily doing recursive chmod 777s, I reverted to the snapshot taken prior to upgrade. I hope this will be resolved shortly.

                        Comment


                          #14
                          Originally posted by liedekef View Post
                          Wille chmod and selinux fixes are ok, no service should be writing in /usr. That's why /var has been invented ... Even the chmod itself should not be needed, it just means there's something wrong with the package.
                          You hit the nail on the head liedekef.

                          Comment


                            #15
                            If you don't wanna go scorched earth, my coworker Forkner solved it a little safer. ;-)

                            ```
                            chown -R apache /usr/share/zabbix/assets/
                            ```

                            Comment


                            • ksookhai
                              ksookhai commented
                              Editing a comment
                              Thank you Kindly Carmichael.chris and your coworker Forkner. Worked like a charm.

                          Announcement

                          Collapse
                          No announcement yet.
                          Working...
                          X