ML
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Nextcloud 13.0 to 13.0.1 Upgrade Failing

    Scheduled Pinned Locked Moved IT Discussion
    nextcloud 13
    14 Posts 5 Posters 1.2k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • scottalanmillerS
      scottalanmiller
      last edited by

      I have 13.0.1 fail for lots of other reasons.

      1 Reply Last reply Reply Quote 0
      • B
        bnrstnr
        last edited by

        Using @JaredBusch's script should set all the permissions correctly.

        #download the script 
        wget -O ~/selinux_config.sh https://raw.githubusercontent.com/sorvani/scripts/master/Nextcloud/selinux_config.sh
        #set it to executable
        chmod +x ~/selinux_config.sh
        #execute the script
        ~/selinux_config.sh
        
        JaredBuschJ 1 Reply Last reply Reply Quote 2
        • black3dynamiteB
          black3dynamite
          last edited by

          Another way to update via the web interface is to enable httpd_unified and then disable it after you are done.
          https://docs.nextcloud.com/server/12/admin_manual/installation/selinux_configuration.html#enable-updates-via-the-web-interface

          JaredBuschJ 1 Reply Last reply Reply Quote 2
          • JaredBuschJ
            JaredBusch @bnrstnr
            last edited by

            @bnrstnr said in Nextcloud 13.0 to 13.0.1 Upgrade Failing:

            Using @JaredBusch's script should set all the permissions correctly.

            #download the script 
            wget -O ~/selinux_config.sh https://raw.githubusercontent.com/sorvani/scripts/master/Nextcloud/selinux_config.sh
            #set it to executable
            chmod +x ~/selinux_config.sh
            #execute the script
            ~/selinux_config.sh
            

            Not for updating it does not.

            B 1 Reply Last reply Reply Quote 0
            • JaredBuschJ
              JaredBusch @black3dynamite
              last edited by JaredBusch

              @black3dynamite said in Nextcloud 13.0 to 13.0.1 Upgrade Failing:

              Another way to update via the web interface is to enable httpd_unified and then disable it after you are done.
              https://docs.nextcloud.com/server/12/admin_manual/installation/selinux_configuration.html#enable-updates-via-the-web-interface

              Correct, either use this or just setenforce 0. Both work fine since you are performing an upgrade manually and will turn them back on.

              1 Reply Last reply Reply Quote 0
              • B
                bnrstnr @JaredBusch
                last edited by

                @JaredBusch What exactly does this do? semanage fcontext -a -t ${httpdrw} "${ocpath}/updater(/.*)?"

                I don't know much about SELinux, but I thought this allowed the application to make changes to the files in this folder.

                JaredBuschJ 1 Reply Last reply Reply Quote 0
                • JaredBuschJ
                  JaredBusch @bnrstnr
                  last edited by

                  @bnrstnr said in Nextcloud 13.0 to 13.0.1 Upgrade Failing:

                  @JaredBusch What exactly does this do? semanage fcontext -a -t ${httpdrw} "${ocpath}/updater(/.*)?"

                  I don't know much about SELinux, but I thought this allowed the application to make changes to the files in this folder.

                  I am using variables here as I intended to make them parameters and never got around to it yet.

                  ${httpdrw} = httpd_sys_rw_content_t
                  ${ocpath} = /var/www/html/nextcloud
                  This allows anything to read and write to the files if the owner of the process is the httpd user account (apache)

                  B 1 Reply Last reply Reply Quote 0
                  • B
                    bnrstnr @JaredBusch
                    last edited by

                    @jaredbusch So this command would allow the upgrade to work? Is the web upgrade process not done by the apache account?

                    I'm curious because my web upgrade worked perfectly without disabling selinux or enabling httpd_unified. I just figured that line in your script gave the proper permissions to apache to do the upgrade.

                    JaredBuschJ 1 Reply Last reply Reply Quote 0
                    • JaredBuschJ
                      JaredBusch @bnrstnr
                      last edited by

                      @bnrstnr said in Nextcloud 13.0 to 13.0.1 Upgrade Failing:

                      @jaredbusch So this command would allow the upgrade to work? Is the web upgrade process not done by the apache account?

                      I'm curious because my web upgrade worked perfectly without disabling selinux or enabling httpd_unified. I just figured that line in your script gave the proper permissions to apache to do the upgrade.

                      The upgrade is done by the httpd account, but it touches potentially every file. Thus, it fails because most of the files do NOT have the httpd_sys_rw_content_t context.

                      1 Reply Last reply Reply Quote 2
                      • JaredBuschJ
                        JaredBusch
                        last edited by

                        0_1521665584686_c6d45354-85b9-4b3d-bd72-1a1af431ed1a-image.png

                        1 Reply Last reply Reply Quote 1
                        • 1 / 1
                        • First post
                          Last post