AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.


#Power
 View Only
Expand all | Collapse all

Need to update LDAP home directory for user.

  • 1.  Need to update LDAP home directory for user.

    Posted Tue September 27, 2011 08:01 PM

    Originally posted by: SystemAdmin


    Hi,
    I need to change LDAP home directory for user. Currently it is pointing to /home2 instead of /home2/<username>. Please help me to find our the way to do that.

    Thanks
    Amit
    #AIX-Forum


  • 2.  Re: Need to update LDAP home directory for user.

    Posted Sun October 30, 2011 01:01 PM

    Originally posted by: SystemAdmin


    Hi ,

    Home directory of an user can be changed using chuser command on LDAP client.

    For LDAP users use following command.

    chuser -R LDAP home=<new location> <username>

    Also the same can be done using ldapmodify command.

    Example:

    dn: uid=efs1,ou=People,cn=aixdata
    gidnumber: 1
    uidnumber: 220
    homedirectory: /home/efs1
    isadministrator: false
    loginshell: /usr/bin/ksh
    uid: efs1
    cn: efs1
    objectclass: posixaccount
    objectclass: account
    objectclass: shadowaccount
    objectclass: aixauxaccount
    objectclass: ibm-securityIdentities
    objectclass: top
    userpassword: {crypt}DAGuLcfz.wbnU
    shadowlastchange: 15133
    passwordchar: !
    hostlastlogin: 9.124.29.99
    ixtimelastlogin: 1307441811
    terminallastlogin: /dev/pts/1
    unsuccessfullogincount: 0

    ldapmodify -h <ldap server name> -D <adminDN> -w<adminPW> -i<filename>

    filename should contain as follows.

    dn: uid=efs1,ou=People,cn=aixdata
    cn: efs1
    changetype: modify
    replace: homedirectory
    homedirectory: /home/newhome

    Let me know if you need more information. thanks.
    #AIX-Forum