• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    [SOLVED] Fatal Error: Failed to mount NFS Volume

    Scheduled Pinned Locked Moved
    FOG Problems
    7
    42
    20.7k
    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.
    • arnaudrigoleA
      arnaudrigole
      last edited by arnaudrigole

      Hi Fog Community,

      As i say in the title, i can’t upload any image on my shared storage i just created.
      I mounted a shared directory on /srv/cfs/SRVADM/images on my server, connected by domain admin account; on my FOG server, i’m able to create a directory with mkdir or a file asked for the problem like:

      touch /srv/cifs/SRVADM/images/.mntcheck
      touch /srv/cifs/SRVADM/images/dev/.mntcheck

      The two files appears in the directory; but when i try tu upload an image from a computer, iPXE say in “Mouting File System” step: "mount: mounting 10.1.11.170:/srv/cifs/SRVADM/images/dev on /images failed: Permission denied

      root@SRVFOG ls -l /srv/cifs/SRVADM returns
      drwxr-xr-x 2 fog fog 0 mars 10 18:18 images

      On the storage node defined on fog webui, the credentials are id: “fog” and pass “password” exactly like “defaultStorageNode”

      Thank you for ur help and sorry for my English…

      Arnaud

      1 Reply Last reply Reply Quote 0
      • Tom ElliottT
        Tom Elliott
        last edited by Tom Elliott

        Please check your /etc/exports file.

        I imagine it currently looks like:

        /images *(ro,sync,no_wdelay,no_subtree_check,insecure_locks,no_root_squash,insecure,fsid=0)
        /images/dev *(rw,async,no_wdelay,no_subtree_check,no_root_squash,insecure,fsid=1)
        

        You will need to change it to read as:

        /srv/cifs/SRVADM/images *(ro,sync,no_wdelay,no_subtree_check,insecure_locks,no_root_squash,insecure,fsid=0)
        /srv/cifs/SRVADM/images/dev *(rw,async,no_wdelay,no_subtree_check,no_root_squash,insecure,fsid=1)
        

        Save the file and reload with sudo exportfs -a

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

        Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

        Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

        1 Reply Last reply Reply Quote 1
        • arnaudrigoleA
          arnaudrigole
          last edited by arnaudrigole

          Hello,

          Thanks for ur help, effectively the /etc/exports file was default; i changed it but now the PXE “Mounting File System” step say

          "mouting 10.1.11.64:/srv/cifs/SRVADM/images/dev on /images failed: Connection refused

          Which credentials should i use ? i tried with domain account created for fog “adminfog”, with encrypted password, tried with “contoso\adminfog” also, tried with “fog” default storage nod + its password … i dont understand ?

          EDIT: ok, i misunderstood one thing… i have already mounted the 10.1.11.64’s shared storage on /srv/cifs/SRVADM/images folder.
          So, i think FOG must see this folder as a local folder, no ? so i defined “fog” local credentials, and now, when it reboot, “Mouting File System” step goes “Done”, but i still have “Fatal Error: Failed to mount NFS volume” ??

          ch3iC Q 2 Replies Last reply Reply Quote 0
          • ch3iC
            ch3i Moderator @arnaudrigole
            last edited by

            @arnaudrigole said:

            Hello,

            Thanks for ur help, effectively the /etc/exports file was default; i changed it but now the PXE “Mounting File System” step say

            "mouting 10.1.11.64:/srv/cifs/SRVADM/images/dev on /images failed: Connection refused

            Which credentials should i use ? i tried with domain account created for fog “adminfog”, with encrypted password, tried with “contoso\adminfog” also, tried with “fog” default storage nod + its password … i dont understand ?

            The client mount the NFS share without authentication, your problem is not here. I’ve never export a CIFS share via NFS.
            The simple way is to enable NFS on your storage instead cifs.

            1 Reply Last reply Reply Quote 0
            • Q
              Quazz Moderator @arnaudrigole
              last edited by Quazz

              @arnaudrigole You can’t reexport a directory you’ve mounted with NFS. You need to mount it directly.

              arnaudrigoleA 1 Reply Last reply Reply Quote 0
              • arnaudrigoleA
                arnaudrigole @Quazz
                last edited by

                @Quazz

                Thanks for your help. So, on fog storage node, instead of setup the “/srv/cifs/SRVADM/images” directory, mounted on a distant server; i setup directly the distant server with shared storage, with contoso credentials?

                @ch3i
                Désolé mais ça me paraît un peu compliqué, je connais pas vraiment la différence entre les deux. Je pensais que le cifs était utilisé pour monter des partage windows

                Q 1 Reply Last reply Reply Quote 0
                • Q
                  Quazz Moderator @arnaudrigole
                  last edited by

                  @arnaudrigole If NFS is enabled on that server for those directories then yes. If not, you’ll need to set that up.

                  arnaudrigoleA 1 Reply Last reply Reply Quote 0
                  • arnaudrigoleA
                    arnaudrigole @Quazz
                    last edited by

                    @Quazz
                    But its not what i want to … FOG can’t write on a local directory and i dont understand why … i defined the storage node on /srv/cifs/SRVADM/image which is a directory on FOG server, BUT, i did a “mount -t cifs” on SRVADM distant server which looks OK.
                    for example, on fog server i create a test.txt file on this /images folder, and i see it on my windows server SRVADM, in D:/DATA_FOG/Images 's shared folder…

                    Q 1 Reply Last reply Reply Quote 0
                    • Q
                      Quazz Moderator @arnaudrigole
                      last edited by Quazz

                      @arnaudrigole FOG needs NFS access, it won’t use CIFS/SAMBA. I believe there is a tutorial on how to switch over to CIFS/SAMBA but it’s not officially supported.

                      https://forums.fogproject.org/topic/5145/script-to-install-samba-with-settings-for-fog

                      arnaudrigoleA 1 Reply Last reply Reply Quote 0
                      • arnaudrigoleA
                        arnaudrigole @Quazz
                        last edited by

                        @Quazz
                        OK! But my data server SRVADM is a Windows Server 2008R2… i will look on it to enable NFS. Never did it before 🙂

                        1 Reply Last reply Reply Quote 0
                        • S
                          Sebastian Roth Moderator
                          last edited by

                          @arnaudrigole This might be helpful to you: https://wiki.fogproject.org/wiki/index.php/Windows_Storage_Node

                          Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

                          Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

                          george1421G arnaudrigoleA 2 Replies Last reply Reply Quote 0
                          • george1421G
                            george1421 Moderator @Sebastian Roth
                            last edited by

                            @Sebastian-Roth While researching how to enable a Synology NAS for a storage node, it appears that current versions of FOG require a web server on the storage node too (as far as I can tell). While I haven’t had too much time to investigate, I’m thinking that it wants something in fog/services/ipxe folder

                            Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!

                            1 Reply Last reply Reply Quote 0
                            • arnaudrigoleA
                              arnaudrigole @Sebastian Roth
                              last edited by

                              @Sebastian-Roth
                              Thank you, i think too !
                              But the described procedure seems to be not secured! (grant RW access for “all”, “all machines”, “everyone” on shared folders…

                              the cryptowall “locky” ransomware that we had last week ravaged our datas and infected all folders which was shared with “everyone” rw right…

                              Q ch3iC 2 Replies Last reply Reply Quote 0
                              • Q
                                Quazz Moderator @arnaudrigole
                                last edited by

                                @arnaudrigole I’m guessing your CIFS/SAMBA shares are mounted as network drives on other computers, yes?

                                The NFS shares should only be mounted on computers that are going get their image captured or where an image will be deployed and only for the duration of those actions.

                                I’ve yet to see a virus sniff out possible NFS connections and then be able to somehow use the correct credentials to then infect the shares, but I guess I could be wrong 😉

                                arnaudrigoleA 1 Reply Last reply Reply Quote 0
                                • arnaudrigoleA
                                  arnaudrigole @Quazz
                                  last edited by

                                  @Quazz
                                  Hi!
                                  Yeah thats it.
                                  Ok, so its why when i type \SRVADM on a Windows computer i don’t see the NFS “FOG” directory i just shared ?

                                  I’ll mount as described in the Sebastian’s procedure, and i’ll come back here so say whats up 🙂

                                  Q 1 Reply Last reply Reply Quote 0
                                  • ch3iC
                                    ch3i Moderator @arnaudrigole
                                    last edited by

                                    @arnaudrigole said:

                                    @Sebastian-Roth
                                    Thank you, i think too !
                                    But the described procedure seems to be not secured! (grant RW access for “all”, “all machines”, “everyone” on shared folders…

                                    the cryptowall “locky” ransomware that we had last week ravaged our datas and infected all folders which was shared with “everyone” rw right…

                                    Au besoin PM moi sur le forum, je pourrais surement te venir en aide.

                                    1 Reply Last reply Reply Quote 1
                                    • Q
                                      Quazz Moderator @arnaudrigole
                                      last edited by

                                      @arnaudrigole That and also because Windows doesn’t support NFS by default.

                                      ch3iC 1 Reply Last reply Reply Quote 0
                                      • ch3iC
                                        ch3i Moderator @Quazz
                                        last edited by

                                        @Quazz said:

                                        @arnaudrigole That and also because Windows doesn’t support NFS by default.

                                        Windows support NFS… look at Server 2008/2012 (2008 > NFS V3 et 2012 > NFS V4.1)

                                        Q 1 Reply Last reply Reply Quote 0
                                        • Q
                                          Quazz Moderator @ch3i
                                          last edited by

                                          @ch3i Server yes, clients not.

                                          1 Reply Last reply Reply Quote 0
                                          • arnaudrigoleA
                                            arnaudrigole
                                            last edited by

                                            I’ve another problem…
                                            haven’t the time yet to mount my NFS storage so i keep using /images default directory of FOG; but when i try to download an image on a computer it said …

                                            **FATAL ERROR: Failed to mount NFS volume
                                            *if you believe the filesystem is mounted, make sure you have a file called .mntcheck in the directory you are mouting on the server.
                                            **

                                            i don’t see any “.mntcheck” file in /images and /images/dev…
                                            So i created it with “touch /images/.mntcheck” and “touch /images/dev/.mntcheck” but it still dont work… 😞
                                            Can’t deploy anything now …

                                            Tom ElliottT 1 Reply Last reply Reply Quote 0
                                            • 1
                                            • 2
                                            • 3
                                            • 1 / 3
                                            • First post
                                              Last post

                                            195

                                            Online

                                            12.0k

                                            Users

                                            17.3k

                                            Topics

                                            155.2k

                                            Posts
                                            Copyright © 2012-2024 FOG Project