Name

msgusermigrate — migrate /etc/passwd members to Messaging Server LDAP datastore

Synopsis

/opt/lsb-caldera.com-volution/msg/bin/msgusermigrate [ --hash=[CRYPT|MD5] ] 
   [ --minUID=uid ] [ --passwdFile=file ] [ --shadowFile=file ] [ --domain=domain ]

Description

The msgusermigrate Messaging Server migration utility is a Perl script that converts UNIX system /etc/passwd entries to an LDAP datastore. After prompting the user for the admin password, msgusermigrate connects to the Messaging Server LDAP server identified in the msg.conf file and authenticates as the admin user. It then:

  1. Loads the passwd and shadow files into memory.

  2. Sorts through each passwd file entry

  3. Verifies that the entry has a shadow file entry; if none are found, it continues to the next user.

  4. Checks for the existence of the name as a Messaging Server UserID. It also checks within the domain for alias, mailname, or alternateMail attribute entries in the LDAP database. If any match the user name, it does not create the user but generates a warning and proceed.

    If no matches are found, it adds the user with msgusercreate(8) defaults.

  5. Pparses the user's shadow entry and sets their password attribute as {hash}encrypted_password in the LDAP database

After disconnecting from the LDAP server, this procedure adds user data to the LDAP datastore file. Depending on system capabilities, migration takes about one hour per 500 users.

Only the Messaging Server admin user can use the msgusermigrate tool.

The following options are supported:

--hash=[CRYPT|MD5]

Specifies the type of encryption algorithm used by the system shadow password database. The default is CRYPT. Most Unix systems use CRYPT; before migrating entries from a Linux system, verify which hashing algorithm is used.

--minUID=uid

Specifies the minimum user ID number to add to the Messaging Server database. The default is 100.

--passwdFile=file

Specifies the name of the file to parse for user information. The default is /etc/passwd.

--shadowFile=file

Specifies the name of the shadow password file to parse for shadow passwords. The default is /etc/shadow.

--domain=domain

Specifies the name of the domain to which users will be added. The default is hostname.

In this release, the msgusermigrate utility only offers migration from legacy UNIX mail systems.

Example

Follow these steps to create Messaging Server LDAP datastore entries for existing UNIX system users:

  1. Copy the existing /etc/passwd and /etc/shadow files to a temporary directory, such as /tmp/migrate, on your Messaging Server system.

  2. Run the msgusermigrate command:

    /opt/lsb-caldera.com-volution/msg/bin/msgusermigrate --passwdFile=/tmp/migrate/passwd --shadowFile=/tmp/migrate/passwd

  3. Enter your Messaging Server admin password.

The msgusermigrate utility then automatically loads user data into the LDAP datastore. Upon completion, newly created Messaging Server users can log into the Preferences Manager and begin using mail services.

Files

/opt/lsb-caldera.com-volution/msg/bin/msgusermigrate

the msgusermigrate Perl script

/etc/opt/lsb-caldera.com-volution/msg/msg.conf

the Messaging Server configuration file

See also

msg.conf(5), msgusercreate(8)