Difference between revisions of "Pam winbind Link"

m (Mmuehlfeld moved page Pam winbind link to Pam winbind Link: Updated title)
(Restructured page)
Line 1: Line 1:
 
= Introduction =
 
= Introduction =
  
To enable [http://www.linux-pam.org PAM] to authenticate domain accounts via Winbindd, it is necessary that PAM finds "pam_winbind.so". For that, it is recommended to place a symbolic link in the right place instead of copying, so that you don't have to replace the file after every Samba update.
+
To enable hosts to receive user and group information from a domain using Winbind, you must create two symbolic links in a directory of the operating system's library path.
  
 +
{{Imbox
 +
| type = note
 +
| text = Do not copy the library to the directory. Otherwise you must replace it manually after every Samba update.
 +
}}
  
  
  
  
= x86_64 vs. i686 =
 
  
The folder, in which the the link needs to be created, differs on the platform you are running. To determine, run
+
= Determining the Platform =
  
# uname -m
+
To determine the operating system's platform:
  
 +
# uname -i
  
  
  
  
= Locate pam_winbind.so =
 
  
The location of pam_winbind.so is defined by the ./configure parameter --with-pammodulesdir=. The default is "/usr/local/samba/lib/security/". If you don't remember the path, use "find", to locate the file
+
= Locating the libnss_winbind.so.2 Library =
  
# find / -type f -name pam_winbind.so
+
The <code>libnss_winbind.so.2</code> library is installed in the Samba library directory set at compile time. To locate the folder:
/usr/local/samba/lib/security/pam_winbind.so
 
  
 +
# smbd -B | grep LIBDIR
 +
    LIBDIR: /usr/local/samba/lib/
  
 +
Link the library from this directory to your operating system's library directory.
  
  
  
= Red Hat based Operating Systems =
 
  
== x86_64 ==
 
  
# ln -s /usr/local/samba/lib/security/pam_winbind.so /lib64/security/
+
= Operating System-specific Examples =
  
 +
== Red Hat-based Operating Systems ==
  
 +
=== x86_64 ===
  
== i686 ==
+
# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib64/
 +
# ln -s /lib64/libnss_winbind.so.2 /lib64/libnss_winbind.so
 +
# ldconfig
  
# ln -s /usr/local/samba/lib/security/pam_winbind.so /lib/security/
 
  
  
 +
=== i686 ===
  
 +
# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib/
 +
# ln -s /lib/libnss_winbind.so.2 /lib/libnss_winbind.so
 +
# ldconfig
  
  
= Debian based Operating Systems =
 
  
== x86_64 ==
+
== Debian-based Operating Systems ==
  
# ln -s /usr/local/samba/lib/security/pam_winbind.so /lib/x86_64-linux-gnu/security/
+
=== x86_64 ===
  
 +
# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib/x86_64-linux-gnu/
 +
# ln -s /lib/x86_64-linux-gnu/libnss_winbind.so.2 /lib/x86_64-linux-gnu/libnss_winbind.so
 +
# ldconfig
  
  
== i686 ==
 
  
# ln -s /usr/local/samba/lib/security/pam_winbind.so /lib/i368-linux-gnu/security/
+
=== i686 ===
  
 +
# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib/i386-linux-gnu/
 +
# ln -s /lib/i386-linux-gnu/libnss_winbind.so.2 /lib/i386-linux-gnu/libnss_winbind.so
 +
# ldconfig
  
  
  
 +
== SUSE-based Operating Systems ==
  
= SUSE based Operating Systems =
+
=== x86_64 ===
  
== x86_64 ==
+
# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib64/
 +
# ln -s /lib64/libnss_winbind.so.2 /lib64/libnss_winbind.so
 +
# ldconfig
  
# ln -s /usr/local/samba/lib/security/pam_winbind.so /lib64/security/
 
  
  
 +
=== i686 ===
  
== i686 ==
+
  # ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib/
 
+
# ln -s /lib/libnss_winbind.so.2 /lib/libnss_winbind.so
  # ln -s /usr/local/samba/lib/security/pam_winbind.so /lib/security/
+
# ldconfig

Revision as of 21:04, 19 October 2016

Introduction

To enable hosts to receive user and group information from a domain using Winbind, you must create two symbolic links in a directory of the operating system's library path.



Determining the Platform

To determine the operating system's platform:

# uname -i



Locating the libnss_winbind.so.2 Library

The libnss_winbind.so.2 library is installed in the Samba library directory set at compile time. To locate the folder:

# smbd -B | grep LIBDIR
   LIBDIR: /usr/local/samba/lib/

Link the library from this directory to your operating system's library directory.



Operating System-specific Examples

Red Hat-based Operating Systems

x86_64

# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib64/
# ln -s /lib64/libnss_winbind.so.2 /lib64/libnss_winbind.so
# ldconfig


i686

# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib/
# ln -s /lib/libnss_winbind.so.2 /lib/libnss_winbind.so
# ldconfig


Debian-based Operating Systems

x86_64

# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib/x86_64-linux-gnu/
# ln -s /lib/x86_64-linux-gnu/libnss_winbind.so.2 /lib/x86_64-linux-gnu/libnss_winbind.so
# ldconfig


i686

# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib/i386-linux-gnu/
# ln -s /lib/i386-linux-gnu/libnss_winbind.so.2 /lib/i386-linux-gnu/libnss_winbind.so
# ldconfig


SUSE-based Operating Systems

x86_64

# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib64/
# ln -s /lib64/libnss_winbind.so.2 /lib64/libnss_winbind.so
# ldconfig


i686

# ln -s /usr/local/samba/lib/libnss_winbind.so.2 /lib/
# ln -s /lib/libnss_winbind.so.2 /lib/libnss_winbind.so
# ldconfig