LDAP-UX Client Services B.04.15 Administrator's Guide

2.10.5.4 The migrate_nis_automount.pl Script
This script, found in /opt/ldapux/migrate, migrates the AutoFS maps from the NIS server
to LDIF.
2.10.5.4.1 Syntax
scriptnameinputfileoutputfile
2.10.5.4.2 Examples
The following commands migrate the AutoFS map /etc/auto_indirect to LDIF and place
the results in the /tmp/auto_indirect.ldif file:
export LDAP_BASEDN="dc=nisserv1" export NIS_DOMAINNAME="cup.hp.com" migrate_nis_automount.pl /etc/auto_indirect
/tmp/auto_indirect.ldif
The following shows the /etc/auto_indirect file:
#local mount point
remote server:directory lab1 hostA:/tmp
lab2 hostB:/tmp
The following shows the /tmp/auto_indirect.ldif file:
dn:automountMapName=auto_indirect,dc=nisserv1
objectClass: top objectClass: automountMap automountMapName: auto_indirect
dn:automountKey=lab1,\ automountMapname=auto_indirect, dc=nisserv1
objectClass: top objectClass: automount automountInformation:hostA:/tmp
automountKey: lab1
dn:automountKey=lab2,
\ automountMapname=auto_indirect, dc=nisserv1 objectClass: top objectClass:
automount automountInformation:hostB:/tmp automountKey:lab2
You can use the /opt/ldapux/bin/ldapmodify tool to import the LDIF file
/tmp/auto_indirect.ldif that you just created above into the LDAP directory. For example,
the following command imports the /tmp/auto_indirect.ldif file to the LDAP base DN
"dc=nisserv1" in the LDAP directory server LDAPSERV1:
/opt/ldapux/bin/ldapmodify -a -h LDAPSERV1 -D "cn=Directory Manager"
-w <passwd> -f /tmp/auto_indirect.ldif
2.10 AutoFS Support 59