You can set up a thin server instance environment by performing a non-root Db2® installation on a
code server and sharing a read-only copy of the Db2 installation path to
other users in the network by using Network File System (NFS).
Procedure
To set up a thin server instance environment:
- Log in to the code server as a non-root user.
-
Perform a non-root Db2 installation on the
code server. For more information, see Installing Db2 database servers as a non-root user.
After successful non-root installation on code server, an instance is created in the
user home directory as shown in the following
example:
/home/db2inst1/sqllib/
where,
db2inst1 is the
non-root user name, and
/home/db2inst1 is the home directory of the non-root
user.
-
Share the non-root copy of Db2 installation path on
the code server as a read-only copy to other systems in the network by using NFS. Perform one of the
following set of substeps:
- On Linux® operating systems, perform the following substeps:
- Log in to the code server as a root user.
- In the /etc/exports file, add the following
entry:
/home/db2inst1/sqllib <ip_address_of_remote_server>(ro,sync,no_subtree_check,no_root_squash)
where,
/home/db2inst1 is the home of the instance user.
- Start the NFS server by issuing the following
commands.
/etc/init.d/nfsserver restart or /etc/init.d/service nfs restart or /etc/init.d/nfs restart
/etc/init.d/portmap restart
/etc/init.d/nfslock start
exportfs -a
exportfs -v
- On AIX® operating systems, perform the following substeps:
- Issue the smit nfs command.
- Click the Network File System (NFS) icon.
- Click the Add a Directory to Exports List icon.
- In the PATHNAME of directory to export field, enter the path name and
directory to export, such as /home/db2inst1/sqllib.
- Click the Mode to export directory icon.
- Select read-only.
- In the HOSTS and netgroups allowed client access field, enter the name of
the code server and remote server.
- Click OK.