OpenLDAP: How to add home directory for users?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
2
down vote

favorite












I am experimenting with an OpenLDAP-Server and I'm not sure how to add /home directories for users. Also where are the files stored?



If a user creates a file on a Windows machine in the domain, where will it be stored? I suppose on the server but in which directory.



How do I create folders for users so that they can access them from any machine in the domain?



I know these might be simple questions but I hope someone still has the passion to answer them.










share|improve this question



























    up vote
    2
    down vote

    favorite












    I am experimenting with an OpenLDAP-Server and I'm not sure how to add /home directories for users. Also where are the files stored?



    If a user creates a file on a Windows machine in the domain, where will it be stored? I suppose on the server but in which directory.



    How do I create folders for users so that they can access them from any machine in the domain?



    I know these might be simple questions but I hope someone still has the passion to answer them.










    share|improve this question

























      up vote
      2
      down vote

      favorite









      up vote
      2
      down vote

      favorite











      I am experimenting with an OpenLDAP-Server and I'm not sure how to add /home directories for users. Also where are the files stored?



      If a user creates a file on a Windows machine in the domain, where will it be stored? I suppose on the server but in which directory.



      How do I create folders for users so that they can access them from any machine in the domain?



      I know these might be simple questions but I hope someone still has the passion to answer them.










      share|improve this question















      I am experimenting with an OpenLDAP-Server and I'm not sure how to add /home directories for users. Also where are the files stored?



      If a user creates a file on a Windows machine in the domain, where will it be stored? I suppose on the server but in which directory.



      How do I create folders for users so that they can access them from any machine in the domain?



      I know these might be simple questions but I hope someone still has the passion to answer them.







      ldap openldap






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited May 28 '15 at 15:30









      cuonglm

      98.6k21188285




      98.6k21188285










      asked May 28 '15 at 14:53









      valh

      2315




      2315




















          3 Answers
          3






          active

          oldest

          votes

















          up vote
          1
          down vote














          I am experimenting with an OpenLDAP-Server and I'm not sure how to add
          /home directories for users. Also where are the files stored?




          When you connect a Linux client (or server for that matter) directly to an OpenLDAP-server the default behavior is to use the 'homeDirectory'-attribute for each user read from your OpenLDAP-server.



          However, this home directory one specificies inside the LDAP database would be a local path on your (Linux) client's computer.



          One can of course mount this local path to a remote directory residing on your server using whatever protocol works best.



          Small detail or hint: I do not know if Firefox works with Samba/CIFS-shares though. It did not work for me but using the NFS-protocol for mounting home directories did however work for me.



          Of course one would not want to configure each client after install to be connected to your OpenLDAP-server manually. One could automate this using perhaps an 'unattended answer' file (actually when using Debian they are called 'preseeds').



          For Windows though, you would use Samba for your roaming profiles.




          If a user creates a file on a Windows machine in the domain, where
          will it be stored? I suppose on the server but in which directory.




          If you want a Windows machine to join a domain you will first have to set up a domain. Just installing and configuring an OpenLDAP-server will not get you a domain.



          However, if you want your OpenLDAP-server to contain users for your domain, you could setup a Samba-server which you would then configure to get its users from your OpenLDAP-server. You would specifiy an LDAP-URI as the 'passdb backend' inside your Samba configuration file.



          Samba 3.6 has been End-of-Life for a certain amount of time but you can just use a Samba 4.x. Although the latter Samba-versions have an Active Directory-mode one can still use just your own OpenLDAP-server, if you want to.




          How do I create folders for users so that they can access them from
          any machine in the domain?




          For Windows one can use a login script to map the proper shares to the proper drive letters. One can base this on group membership for example.



          One can use phpLDAPadmin to manage LDAP-users and all other things inside LDAP. It is quite configurable.



          Personally though, if it is just about managing users and groups inside LDAP I have a preference for LDAP-account-manager (which is also a web-based LDAP-managing tool) because my opinion is it is quite user-friendly (at least for basic management of users and groups).



          It is free for some basic management of users and groups inside LDAP. If you want more features though you will have to pay.






          share|improve this answer





























            up vote
            0
            down vote













            The easy way to set an openldap server is to search samba openldap domain howto
            on google,there's a lot of docs,mosts out of date,but with a little study
            you can adapt to your case.
            You will learn that exist a nice php program called phpldapadmin and you can add easy the homedir via web interface



            enter image description here



            If you not interested or not need samba or not use windows client,you can easily setup
            an ldap server,there's a lot of docs on google,search for "openldap migration tools" "openldap phpldapadmin".
            Some years ago i have set a ldap server using openldap



            1)Convert local user to ldap,with migration tools
            2)Setup a ldap server,search for openldap ignite or openldap init
            3)Setup authentication using pam-ldap module,search on google for info
            4)Using phpldapadmin to easy manage server





            share|improve this answer



























              up vote
              0
              down vote













              I answered this same question on another thread here:



              Edit home directory for an LDAP user in Linux



              However I'll answer it here as well...



              I know this thread is old. However, I stumbled across it while attempting the same thing on CentOS 7. I imagine the process is the same. I needed to change several users directories from /home/USER to /home/ldap-users/USER.



              First create an ldif file with the changes you want to make. I named mine changehomedirs.ldif. You may need to change your ou depending on what organizational unit you put your users in. I called mine People.



              Then I wrote a script to essentially loop through each LDAP user one at a time and used sed to replace the word USER in the changehomedirs.ldif file to the current user in the loop and redirect the output to a temporary file named tmp.ldif.



              Then I used the ldapmodify command to make the changes by using the -f option to read the desired changes from the tmp.ldif file. The example is in the screenshot below.



              This is just a testing system so the password is not sensitive in nature.



              Home dirs before LDAP modification



              How to change a users home directory in LDAP



              Home dirs after LDAP modification






              share|improve this answer




















                Your Answer







                StackExchange.ready(function()
                var channelOptions =
                tags: "".split(" "),
                id: "106"
                ;
                initTagRenderer("".split(" "), "".split(" "), channelOptions);

                StackExchange.using("externalEditor", function()
                // Have to fire editor after snippets, if snippets enabled
                if (StackExchange.settings.snippets.snippetsEnabled)
                StackExchange.using("snippets", function()
                createEditor();
                );

                else
                createEditor();

                );

                function createEditor()
                StackExchange.prepareEditor(
                heartbeatType: 'answer',
                convertImagesToLinks: false,
                noModals: false,
                showLowRepImageUploadWarning: true,
                reputationToPostImages: null,
                bindNavPrevention: true,
                postfix: "",
                onDemand: true,
                discardSelector: ".discard-answer"
                ,immediatelyShowMarkdownHelp:true
                );



                );













                 

                draft saved


                draft discarded


















                StackExchange.ready(
                function ()
                StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f206110%2fopenldap-how-to-add-home-directory-for-users%23new-answer', 'question_page');

                );

                Post as a guest






























                3 Answers
                3






                active

                oldest

                votes








                3 Answers
                3






                active

                oldest

                votes









                active

                oldest

                votes






                active

                oldest

                votes








                up vote
                1
                down vote














                I am experimenting with an OpenLDAP-Server and I'm not sure how to add
                /home directories for users. Also where are the files stored?




                When you connect a Linux client (or server for that matter) directly to an OpenLDAP-server the default behavior is to use the 'homeDirectory'-attribute for each user read from your OpenLDAP-server.



                However, this home directory one specificies inside the LDAP database would be a local path on your (Linux) client's computer.



                One can of course mount this local path to a remote directory residing on your server using whatever protocol works best.



                Small detail or hint: I do not know if Firefox works with Samba/CIFS-shares though. It did not work for me but using the NFS-protocol for mounting home directories did however work for me.



                Of course one would not want to configure each client after install to be connected to your OpenLDAP-server manually. One could automate this using perhaps an 'unattended answer' file (actually when using Debian they are called 'preseeds').



                For Windows though, you would use Samba for your roaming profiles.




                If a user creates a file on a Windows machine in the domain, where
                will it be stored? I suppose on the server but in which directory.




                If you want a Windows machine to join a domain you will first have to set up a domain. Just installing and configuring an OpenLDAP-server will not get you a domain.



                However, if you want your OpenLDAP-server to contain users for your domain, you could setup a Samba-server which you would then configure to get its users from your OpenLDAP-server. You would specifiy an LDAP-URI as the 'passdb backend' inside your Samba configuration file.



                Samba 3.6 has been End-of-Life for a certain amount of time but you can just use a Samba 4.x. Although the latter Samba-versions have an Active Directory-mode one can still use just your own OpenLDAP-server, if you want to.




                How do I create folders for users so that they can access them from
                any machine in the domain?




                For Windows one can use a login script to map the proper shares to the proper drive letters. One can base this on group membership for example.



                One can use phpLDAPadmin to manage LDAP-users and all other things inside LDAP. It is quite configurable.



                Personally though, if it is just about managing users and groups inside LDAP I have a preference for LDAP-account-manager (which is also a web-based LDAP-managing tool) because my opinion is it is quite user-friendly (at least for basic management of users and groups).



                It is free for some basic management of users and groups inside LDAP. If you want more features though you will have to pay.






                share|improve this answer


























                  up vote
                  1
                  down vote














                  I am experimenting with an OpenLDAP-Server and I'm not sure how to add
                  /home directories for users. Also where are the files stored?




                  When you connect a Linux client (or server for that matter) directly to an OpenLDAP-server the default behavior is to use the 'homeDirectory'-attribute for each user read from your OpenLDAP-server.



                  However, this home directory one specificies inside the LDAP database would be a local path on your (Linux) client's computer.



                  One can of course mount this local path to a remote directory residing on your server using whatever protocol works best.



                  Small detail or hint: I do not know if Firefox works with Samba/CIFS-shares though. It did not work for me but using the NFS-protocol for mounting home directories did however work for me.



                  Of course one would not want to configure each client after install to be connected to your OpenLDAP-server manually. One could automate this using perhaps an 'unattended answer' file (actually when using Debian they are called 'preseeds').



                  For Windows though, you would use Samba for your roaming profiles.




                  If a user creates a file on a Windows machine in the domain, where
                  will it be stored? I suppose on the server but in which directory.




                  If you want a Windows machine to join a domain you will first have to set up a domain. Just installing and configuring an OpenLDAP-server will not get you a domain.



                  However, if you want your OpenLDAP-server to contain users for your domain, you could setup a Samba-server which you would then configure to get its users from your OpenLDAP-server. You would specifiy an LDAP-URI as the 'passdb backend' inside your Samba configuration file.



                  Samba 3.6 has been End-of-Life for a certain amount of time but you can just use a Samba 4.x. Although the latter Samba-versions have an Active Directory-mode one can still use just your own OpenLDAP-server, if you want to.




                  How do I create folders for users so that they can access them from
                  any machine in the domain?




                  For Windows one can use a login script to map the proper shares to the proper drive letters. One can base this on group membership for example.



                  One can use phpLDAPadmin to manage LDAP-users and all other things inside LDAP. It is quite configurable.



                  Personally though, if it is just about managing users and groups inside LDAP I have a preference for LDAP-account-manager (which is also a web-based LDAP-managing tool) because my opinion is it is quite user-friendly (at least for basic management of users and groups).



                  It is free for some basic management of users and groups inside LDAP. If you want more features though you will have to pay.






                  share|improve this answer
























                    up vote
                    1
                    down vote










                    up vote
                    1
                    down vote










                    I am experimenting with an OpenLDAP-Server and I'm not sure how to add
                    /home directories for users. Also where are the files stored?




                    When you connect a Linux client (or server for that matter) directly to an OpenLDAP-server the default behavior is to use the 'homeDirectory'-attribute for each user read from your OpenLDAP-server.



                    However, this home directory one specificies inside the LDAP database would be a local path on your (Linux) client's computer.



                    One can of course mount this local path to a remote directory residing on your server using whatever protocol works best.



                    Small detail or hint: I do not know if Firefox works with Samba/CIFS-shares though. It did not work for me but using the NFS-protocol for mounting home directories did however work for me.



                    Of course one would not want to configure each client after install to be connected to your OpenLDAP-server manually. One could automate this using perhaps an 'unattended answer' file (actually when using Debian they are called 'preseeds').



                    For Windows though, you would use Samba for your roaming profiles.




                    If a user creates a file on a Windows machine in the domain, where
                    will it be stored? I suppose on the server but in which directory.




                    If you want a Windows machine to join a domain you will first have to set up a domain. Just installing and configuring an OpenLDAP-server will not get you a domain.



                    However, if you want your OpenLDAP-server to contain users for your domain, you could setup a Samba-server which you would then configure to get its users from your OpenLDAP-server. You would specifiy an LDAP-URI as the 'passdb backend' inside your Samba configuration file.



                    Samba 3.6 has been End-of-Life for a certain amount of time but you can just use a Samba 4.x. Although the latter Samba-versions have an Active Directory-mode one can still use just your own OpenLDAP-server, if you want to.




                    How do I create folders for users so that they can access them from
                    any machine in the domain?




                    For Windows one can use a login script to map the proper shares to the proper drive letters. One can base this on group membership for example.



                    One can use phpLDAPadmin to manage LDAP-users and all other things inside LDAP. It is quite configurable.



                    Personally though, if it is just about managing users and groups inside LDAP I have a preference for LDAP-account-manager (which is also a web-based LDAP-managing tool) because my opinion is it is quite user-friendly (at least for basic management of users and groups).



                    It is free for some basic management of users and groups inside LDAP. If you want more features though you will have to pay.






                    share|improve this answer















                    I am experimenting with an OpenLDAP-Server and I'm not sure how to add
                    /home directories for users. Also where are the files stored?




                    When you connect a Linux client (or server for that matter) directly to an OpenLDAP-server the default behavior is to use the 'homeDirectory'-attribute for each user read from your OpenLDAP-server.



                    However, this home directory one specificies inside the LDAP database would be a local path on your (Linux) client's computer.



                    One can of course mount this local path to a remote directory residing on your server using whatever protocol works best.



                    Small detail or hint: I do not know if Firefox works with Samba/CIFS-shares though. It did not work for me but using the NFS-protocol for mounting home directories did however work for me.



                    Of course one would not want to configure each client after install to be connected to your OpenLDAP-server manually. One could automate this using perhaps an 'unattended answer' file (actually when using Debian they are called 'preseeds').



                    For Windows though, you would use Samba for your roaming profiles.




                    If a user creates a file on a Windows machine in the domain, where
                    will it be stored? I suppose on the server but in which directory.




                    If you want a Windows machine to join a domain you will first have to set up a domain. Just installing and configuring an OpenLDAP-server will not get you a domain.



                    However, if you want your OpenLDAP-server to contain users for your domain, you could setup a Samba-server which you would then configure to get its users from your OpenLDAP-server. You would specifiy an LDAP-URI as the 'passdb backend' inside your Samba configuration file.



                    Samba 3.6 has been End-of-Life for a certain amount of time but you can just use a Samba 4.x. Although the latter Samba-versions have an Active Directory-mode one can still use just your own OpenLDAP-server, if you want to.




                    How do I create folders for users so that they can access them from
                    any machine in the domain?




                    For Windows one can use a login script to map the proper shares to the proper drive letters. One can base this on group membership for example.



                    One can use phpLDAPadmin to manage LDAP-users and all other things inside LDAP. It is quite configurable.



                    Personally though, if it is just about managing users and groups inside LDAP I have a preference for LDAP-account-manager (which is also a web-based LDAP-managing tool) because my opinion is it is quite user-friendly (at least for basic management of users and groups).



                    It is free for some basic management of users and groups inside LDAP. If you want more features though you will have to pay.







                    share|improve this answer














                    share|improve this answer



                    share|improve this answer








                    edited Aug 16 '15 at 10:42

























                    answered Aug 16 '15 at 10:34









                    Wieger

                    714




                    714






















                        up vote
                        0
                        down vote













                        The easy way to set an openldap server is to search samba openldap domain howto
                        on google,there's a lot of docs,mosts out of date,but with a little study
                        you can adapt to your case.
                        You will learn that exist a nice php program called phpldapadmin and you can add easy the homedir via web interface



                        enter image description here



                        If you not interested or not need samba or not use windows client,you can easily setup
                        an ldap server,there's a lot of docs on google,search for "openldap migration tools" "openldap phpldapadmin".
                        Some years ago i have set a ldap server using openldap



                        1)Convert local user to ldap,with migration tools
                        2)Setup a ldap server,search for openldap ignite or openldap init
                        3)Setup authentication using pam-ldap module,search on google for info
                        4)Using phpldapadmin to easy manage server





                        share|improve this answer
























                          up vote
                          0
                          down vote













                          The easy way to set an openldap server is to search samba openldap domain howto
                          on google,there's a lot of docs,mosts out of date,but with a little study
                          you can adapt to your case.
                          You will learn that exist a nice php program called phpldapadmin and you can add easy the homedir via web interface



                          enter image description here



                          If you not interested or not need samba or not use windows client,you can easily setup
                          an ldap server,there's a lot of docs on google,search for "openldap migration tools" "openldap phpldapadmin".
                          Some years ago i have set a ldap server using openldap



                          1)Convert local user to ldap,with migration tools
                          2)Setup a ldap server,search for openldap ignite or openldap init
                          3)Setup authentication using pam-ldap module,search on google for info
                          4)Using phpldapadmin to easy manage server





                          share|improve this answer






















                            up vote
                            0
                            down vote










                            up vote
                            0
                            down vote









                            The easy way to set an openldap server is to search samba openldap domain howto
                            on google,there's a lot of docs,mosts out of date,but with a little study
                            you can adapt to your case.
                            You will learn that exist a nice php program called phpldapadmin and you can add easy the homedir via web interface



                            enter image description here



                            If you not interested or not need samba or not use windows client,you can easily setup
                            an ldap server,there's a lot of docs on google,search for "openldap migration tools" "openldap phpldapadmin".
                            Some years ago i have set a ldap server using openldap



                            1)Convert local user to ldap,with migration tools
                            2)Setup a ldap server,search for openldap ignite or openldap init
                            3)Setup authentication using pam-ldap module,search on google for info
                            4)Using phpldapadmin to easy manage server





                            share|improve this answer












                            The easy way to set an openldap server is to search samba openldap domain howto
                            on google,there's a lot of docs,mosts out of date,but with a little study
                            you can adapt to your case.
                            You will learn that exist a nice php program called phpldapadmin and you can add easy the homedir via web interface



                            enter image description here



                            If you not interested or not need samba or not use windows client,you can easily setup
                            an ldap server,there's a lot of docs on google,search for "openldap migration tools" "openldap phpldapadmin".
                            Some years ago i have set a ldap server using openldap



                            1)Convert local user to ldap,with migration tools
                            2)Setup a ldap server,search for openldap ignite or openldap init
                            3)Setup authentication using pam-ldap module,search on google for info
                            4)Using phpldapadmin to easy manage server






                            share|improve this answer












                            share|improve this answer



                            share|improve this answer










                            answered May 28 '15 at 18:12









                            elbarna

                            3,85893577




                            3,85893577




















                                up vote
                                0
                                down vote













                                I answered this same question on another thread here:



                                Edit home directory for an LDAP user in Linux



                                However I'll answer it here as well...



                                I know this thread is old. However, I stumbled across it while attempting the same thing on CentOS 7. I imagine the process is the same. I needed to change several users directories from /home/USER to /home/ldap-users/USER.



                                First create an ldif file with the changes you want to make. I named mine changehomedirs.ldif. You may need to change your ou depending on what organizational unit you put your users in. I called mine People.



                                Then I wrote a script to essentially loop through each LDAP user one at a time and used sed to replace the word USER in the changehomedirs.ldif file to the current user in the loop and redirect the output to a temporary file named tmp.ldif.



                                Then I used the ldapmodify command to make the changes by using the -f option to read the desired changes from the tmp.ldif file. The example is in the screenshot below.



                                This is just a testing system so the password is not sensitive in nature.



                                Home dirs before LDAP modification



                                How to change a users home directory in LDAP



                                Home dirs after LDAP modification






                                share|improve this answer
























                                  up vote
                                  0
                                  down vote













                                  I answered this same question on another thread here:



                                  Edit home directory for an LDAP user in Linux



                                  However I'll answer it here as well...



                                  I know this thread is old. However, I stumbled across it while attempting the same thing on CentOS 7. I imagine the process is the same. I needed to change several users directories from /home/USER to /home/ldap-users/USER.



                                  First create an ldif file with the changes you want to make. I named mine changehomedirs.ldif. You may need to change your ou depending on what organizational unit you put your users in. I called mine People.



                                  Then I wrote a script to essentially loop through each LDAP user one at a time and used sed to replace the word USER in the changehomedirs.ldif file to the current user in the loop and redirect the output to a temporary file named tmp.ldif.



                                  Then I used the ldapmodify command to make the changes by using the -f option to read the desired changes from the tmp.ldif file. The example is in the screenshot below.



                                  This is just a testing system so the password is not sensitive in nature.



                                  Home dirs before LDAP modification



                                  How to change a users home directory in LDAP



                                  Home dirs after LDAP modification






                                  share|improve this answer






















                                    up vote
                                    0
                                    down vote










                                    up vote
                                    0
                                    down vote









                                    I answered this same question on another thread here:



                                    Edit home directory for an LDAP user in Linux



                                    However I'll answer it here as well...



                                    I know this thread is old. However, I stumbled across it while attempting the same thing on CentOS 7. I imagine the process is the same. I needed to change several users directories from /home/USER to /home/ldap-users/USER.



                                    First create an ldif file with the changes you want to make. I named mine changehomedirs.ldif. You may need to change your ou depending on what organizational unit you put your users in. I called mine People.



                                    Then I wrote a script to essentially loop through each LDAP user one at a time and used sed to replace the word USER in the changehomedirs.ldif file to the current user in the loop and redirect the output to a temporary file named tmp.ldif.



                                    Then I used the ldapmodify command to make the changes by using the -f option to read the desired changes from the tmp.ldif file. The example is in the screenshot below.



                                    This is just a testing system so the password is not sensitive in nature.



                                    Home dirs before LDAP modification



                                    How to change a users home directory in LDAP



                                    Home dirs after LDAP modification






                                    share|improve this answer












                                    I answered this same question on another thread here:



                                    Edit home directory for an LDAP user in Linux



                                    However I'll answer it here as well...



                                    I know this thread is old. However, I stumbled across it while attempting the same thing on CentOS 7. I imagine the process is the same. I needed to change several users directories from /home/USER to /home/ldap-users/USER.



                                    First create an ldif file with the changes you want to make. I named mine changehomedirs.ldif. You may need to change your ou depending on what organizational unit you put your users in. I called mine People.



                                    Then I wrote a script to essentially loop through each LDAP user one at a time and used sed to replace the word USER in the changehomedirs.ldif file to the current user in the loop and redirect the output to a temporary file named tmp.ldif.



                                    Then I used the ldapmodify command to make the changes by using the -f option to read the desired changes from the tmp.ldif file. The example is in the screenshot below.



                                    This is just a testing system so the password is not sensitive in nature.



                                    Home dirs before LDAP modification



                                    How to change a users home directory in LDAP



                                    Home dirs after LDAP modification







                                    share|improve this answer












                                    share|improve this answer



                                    share|improve this answer










                                    answered Jul 21 '17 at 15:54









                                    Kentgrav

                                    8317




                                    8317



























                                         

                                        draft saved


                                        draft discarded















































                                         


                                        draft saved


                                        draft discarded














                                        StackExchange.ready(
                                        function ()
                                        StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f206110%2fopenldap-how-to-add-home-directory-for-users%23new-answer', 'question_page');

                                        );

                                        Post as a guest













































































                                        Popular posts from this blog

                                        Peggy Mitchell

                                        Palaiologos

                                        The Forum (Inglewood, California)