Practical guide for minimalistic Solaris installation

Preamble

When you install Solaris (and any other UNIX/Linux) in generally there are 2 ways: make full install of all packages from media and install as little as possible. Each of the ways have pros and cons, but discussion about this is outside the theme of this text. This article is directed to create custom, minimalistic installation of Solaris 10. For security resons we will use ssh as “communication” way, for support of international charsets we will install en_US.UTF-8 codepage, but for compatibility will set the default language to C




Installation

We will start core installation and after this add the packages and clusters: SUNWCssh, SUNWladm, SUNWxcu6. Of course is possible to add the packages and clusters on time of the installation and get ssh key generation done on the time of first boot. But for demonstration we will do this work on “hard” way i.e. install packages and generate keys by hand. Do not forget to edit your /etc/ssh/sshd_config file to enable root logins via ssh. I know this can is security problem, but for tests is OK. As Software Group choose Core Group. Set disk map as follow
/ - 2048
/opt – 2048
swap - =RAM
/home – 64
The above disk layout is just example, for your installation follow rules, defined in your company or by policies from product you want to install later (for filesystems sizing take a look here: Suggestions_and_ideas_about_filesystem_sizing_on_Solaris)




Install additional packages (SUNWCssh, SUNWladm, SUNWxcu6)

Mount CDROM (DVDROM) and install package. Be aware the order is important.
mount –o ro –F hsfs /dev/dsk/c1t0d0s0 /mnt
cd /mnt/Solaris_10/Products
pkgadd –d . SUNWsshcu SUNWsshr SUNWsshu SUNWsshdr SUNWsshdu 
pkgadd –d . SUNWxcu4 SUNWxcu6
pkgadd –d . SUNWladm



Generate ssh server keys

cd /etc/ssh
ssh-keygen –t rsa –f ssh_host_rsa_key
ssh-keygen –t dsa –f ssh_host_dsa_key
svcadm enable ssh
In process of generation when ask for password just press enter. The length of the keys is 768 bits. Change it in case of need.




Install additional packages

pkgadd -d . SUNWctpls
pkgadd -d . SUNWmfrun
pkgadd -d . SUNWxwrtl
pkgadd -d . SUNWxwice
pkgadd -d . SUNWxwfnt
pkgadd -d . SUNWxwplr
pkgadd -d . SUNWxwplt
pkgadd -d . SUNWbtool
pkgadd -d . SUNWarc
pkgadd -d . SUNWhea
pkgadd -d . SUNWtoo
pkgadd -d . SUNWlibmr
pkgadd -d . SUNWlibm
pkgadd -d . SUNWlibms
pkgadd -d . SUNWsprot
pkgadd -d . SUNWi1of
pkgadd -d . SUNWi1cs
pkgadd -d . SUNWeurf
pkgadd -d . SUNWi15rf
pkgadd -d . SUNWi15cs
pkgadd -d . SUNWxwfnt
pkgadd -d . SUNWadmfr
pkgadd -d . SUNWadmc
pkgadd -d . SUNWadmfw
pkgadd -d . SUNWadmr
pkgadd -d . SUNWadmap
Part of the packages are need for i18n support, part are need for installing and running java, the rest are need for proper Oracle (database server/client) installation. Of course you can decide for self, but most of them are need for installation and running almost every additional software. Again be aware the order is important.



install java SDK packages

When you need java (JRE/JDK) you can install it on 2 different ways: from standard packages and download and install from Oracle site. If you need to track changes and patch it the simplest way is to use java, bundled in installation. But if you need to run some specific version for some software you can download it from Oracle site (see remark #1), copy it on special place (even under directory tree of the product and set JAVA_HOME and PATH variables.
pkgadd -d . SUNWj5rt
pkgadd -d . SUNWj5man
pkgadd -d . SUNWj5cfg
pkgadd -d . SUNWj5dev

 

Final notes

This article give you just start point. For your product maybe you will need additional packages. The advantage of this type of installation is you have less packages to care (change, patch) about, you get only 500 MB disk space of installation, you get only 30 processes (may vary) started and only 150 MB memory used (may vary too).




Remarks

1. On the Oracle Java site you can see two kind of packages: jdk-6u4-solaris-i586.sh and jdk-6u4-solaris-i586.tar.Z (names are just examples). Difference between them is the first archive (.sh) after agree with license create directory with java files you can move (directory) wherever you want (see listing).
# ls -l
drwxrwxr-x  10 root     root         687 Dec 14 15:08 jdk1.6.0_04
The second archive (tar.Z) create few directories, containing packages you can install with pkgadd program (see listing).
# ls -l
-r--r--r--   1 10       143         4140 Dec 14 17:15 COPYRIGHT
-r--r--r--   1 10       143        14097 Dec 14 17:15 LICENSE
-r--r--r--   1 10       143        28599 Dec 14 17:15 README.html
drwxr-xr-x   4 10       143          226 Dec 14 17:14 SUNWj6cfg
drwxr-xr-x   4 10       143          226 Dec 14 17:14 SUNWj6dev
drwxr-xr-x   4 10       143          226 Dec 14 17:14 SUNWj6dmo
drwxr-xr-x   4 10       143          226 Dec 14 17:14 SUNWj6jmp
drwxr-xr-x   4 10       143          226 Dec 14 17:14 SUNWj6man
drwxr-xr-x   4 10       143          226 Dec 14 17:14 SUNWj6rt
drwxrwxr-x   4 10       143          226 Dec 14 17:14 SUNWjavadb-client
drwxrwxr-x   4 10       143          226 Dec 14 17:14 SUNWjavadb-common
drwxrwxr-x   4 10       143          226 Dec 14 17:14 SUNWjavadb-core
drwxrwxr-x   4 10       143          226 Dec 14 17:14 SUNWjavadb-demo
drwxrwxr-x   4 10       143          226 Dec 14 17:14 SUNWjavadb-docs
drwxrwxr-x   4 10       143          226 Dec 14 17:14 SUNWjavadb-javadoc

No comments:

Post a Comment

Compressed tar archive

There are some cases when you want to create compressed tar archive but you do not have enough disk space to keep original files and tar arc...