Solaris 10 post-installation tasks

This post outlines some of the post-installation tasks I usually perform after a fresh Solaris 10 installation. Note that this is my own approach and that it is based on x86 archictecture.

The first general tasks involve linuxifying the new environment and setting some environment variables:

a) Changing root account settings:

vi /etc/passwd
root:x:0:0:Super-User:/root:/usr/bin/bash

b) Creating a directory for the root account:

mkdir /root
mv /.bash* /root
mv /.sunw /root

c) Modifying /etc/profile or /root/.bash_profile according to my preferences:

PS1=’\[\033[01;31m\]SERVER-NAME \[\033[00m\]\u@\h:\[\033[01;34m\]\w\[\033[00m\]\$ ‘

alias la=”ls -alh”
alias cp=”cp -i”
alias mv=”mv -i”
alias rm=”rm -i”

PATH=/opt/csw/bin:/usr/sbin:/usr/bin:/usr/openwin/bin:/usr/dt/bin:/usr/ccs/bin:$PATH
export PATH

export TERM=xterm

d) Network stuff:

vi /etc/resolv.conf

search mydomain.com
nameserver 192.168.1.2

vi /etc/defaultrouter

192.168.1.1

cd /etc
cp nsswitch.dns nsswitch.conf

e) Once finished this basic configuration, I usually install and configure PKG-GET for the package management:

mkdir /tmp/karkoma

cd /tmp/karkoma

/usr/sfw/bin/wget http://www.blastwave.org/pkg_get.pkg
pkgadd -d pkg_get.pkg all

/usr/sfw/bin/wget http://www.blastwave.org/wget-i386.bin
chmod 755 wget-i386.bin

PATH=/tmp/karkoma:/opt/csw/bin:/usr/sbin:/usr/bin:/usr/dt/bin:/usr/openwin/bin:/usr/ccs/bin
export PATH

vi /opt/csw/etc/pkg-get.conf

Change this file according to your needs, remember to pick a mirror nearest to you. Then continue with the following:

pkg-get -i wget

PATH=/opt/csw/bin:/usr/sbin:/usr/bin:/usr/openwin/bin:/usr/dt/bin:/usr/ccs/bin
export PATH

pkg-get -i gnupg

Note that by adding the PATH to /etc/profile it will be available system wide.

f) Add users to your new environment:

mkdir -p /export/home
useradd -d /export/home/username -m -s /bin/bash -c “Franz Kafka” username
passwd username

g) Finally disable un-needed services

svcadm disable sendmail
svcadm disable ftp
svcadm disable telnet
svcadm disable finger

That’s all. Now, what kind of tasks do you perform in a fresh installation?

References:

Leave a Reply

You must be logged in to post a comment.