6.05.2006

[Work] File under "you learn something new everyday"

Adding a boat load of packages in Solaris is a lot easier when you know about the admin file, default is /var/sadm/install/admin/default and contains:


#
# Copyright 2003 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
#ident "@(#)default 1.5 03/06/11 SMI"
#
mail=
instance=unique
partial=ask
runlevel=ask
idepend=ask
rdepend=ask
space=ask
setuid=ask
conflict=ask
action=ask
networktimeout=60
networkretries=3
authentication=quit
keystore=/var/sadm/security
proxy=
basedir=default


chenge 'ask' to 'nocheck' and viola! Non-interactive package installs. Be warned though that it will not tell you interactively if things like dependencies are not met and it will not warn on setuid/gid settings, so know your dependencies and know what you are doing before you go forward.

To use the new admin file you can place it in /var/sadm/install/admin and call it anything but 'default'. pkgadd(1M) will look in this directory first for admin files, otherwise you can supply a full path name, example:

pkgadd -a nocheck -d . SMCgcc

No comments: