Tuesday, 19 May 2009

Mengenai pkg

Saya biasa menggunakan command berikut terkait instalasi paket di solaris :
#pkginfo -l (menampilkan package dengan parameter long listing)


Sebenarnya banyak opsi lain
usage:
pkginfo [-q] [-pi] [-x|l] [options] [pkg ...]
pkginfo -d device [-q] [-x|l] [options] [pkg ...]
where
-q #quiet mode
-p #select partially installed packages
-i #select completely installed packages
-x #extracted listing
-l #long listing
-r #relocation base
and options may include:
-c category, [category...]
-a architecture
-v version


untuk mencari package yang partially installed(p) dan extracted listing(x):

#pkginfo -xp

SMCosl98d openssl
(sparc) 0.9.8d

Untuk mencari paket yang completely installed(i) , dengan extracted listing(x), dan architecture sparc
#pkginfo -xia sparc

Install paket
#pkgadd -d . nama_package

Remove paket
#pkgrm nama_package

Check status paket
#pkgchk -l SUNWzuluw

Pathname: /usr/openwin
Type: directory
Expected mode: 0755
Expected owner: root
Expected group: bin
Referenced by the following packages:
SUNWctlu SUNWcsu SUNWxwice SUNWxwcft SUNWtltk
SUNWjxmft SUNWxwicx SUNWeurf SUNWkoi8f SUNWkxmft
SUNWlccom SUNWadmap SUNW1251f SUNW5xmft SUNWxwacx
SUNWmp SUNWxilrl SUNWxildh SUNWxilow SUNWolrte
SUNWpmowu SUNWarrf SUNWi13rf SUNWi15rf SUNWi15cs
SUNWi1cs SUNWi2rf SUNWi5rf SUNWi7rf SUNWi9rf
SUNWcxmft SUNWtltkx SUNWeuodf SUNWxi18n SUNWxim
SUNWeuxwe SUNWtxfnt SUNWulocf SUNWuxlcf SUNWxi18x
SUNWximx SUNWuxlcx SUNWvid SUNWxilvl SUNWxwcsl
SUNWxwdim SUNWxwdem SUNWxwdxm SUNWxwfs SUNWxwoft
SUNWxwpft SUNWxwpsr SUNWxwpl SUNWxwxst SUNWxwxft
SUNWxwxstx SUNWxwxftx SUNWi4rf SUNWi8rf SUNWzuluw
SUNWnamow SUNWplow SUNWplow1 SUNWi1of SUNWxwfnt
SUNWxwopt SUNWxwsrv SUNWm64w SUNWpfbw SUNWxwplt
SUNWxwplx
Current status: installed




Tuesday, 2 December 2008

mengenai contents

/var/sadm/install/contents

File ini menyimpan package yang kita install di solaris, jika kita hendak membuat mesin cloning yang memiliki package level sama, maka bisa melakukan copy file ini ke mesin baru tersebut. Dengan asumsi mesin baru ini akan dibuat sama level packagenya dengan mesin reference.

Untuk melakukan test terhadap file contents ini bisa dilakukan dengan mereboot(shutdown -i6 -g0 -y), jika server berhasil up berarti contents nya lengkap.

Dapat command baru screen

Pastikan screen terinstall di sun solaris/linux anda:
#which screen
/usr/local/bin/screen

Setelah itu tinggal ketik:
#screen
dan
lakukan aktifitas anda, jika anda ingin keluar :
ctrl + a and z

Lalu jika anda ingin kembali bekerja:

login ke mesin anda dan ketik

#screen -r

maka anda masih mendapatkan sesi anda tanpa terinterupt.

Wednesday, 23 July 2008

.profile

When you are making a user, then you will have a .profile, you can export your environment setting here, your path, so it make easy so you dont have to run full path command, just run the alias you set

Monday, 7 July 2008

How to make solaris 10 using dhcp client

1.if in /etc/hosts you already have ip static configured for this host, please comment it.
2. touch empty file /etc/dhcp.interfacename example : touch /etc/dhcp.bge0
3. touch empty file /etc/hostname.interfacename example : touch /etc/hostname.bge0
4. reboot the system

How to do jumpstart

1. clean all unnecessary log and config files from the server we want to clone
2. make backup for the /etc/inittab
3. uncomment all the process of application in /etc/inittab
4. enter single mode (init s)
5. login using serial console cable
6. flarcreate -n hostname -c -S -x /oradata hostname_images.flar
7. restore inittab
8. reboot the system
9. transfer the image files to jumpstart server
to be Continue

Friday, 9 May 2008

Small tools

You can compare two files using command diff and sdiff:
example: diff file1 file2 or sdiff file1 file2

head --> to see the top content of the file

head filename.txt
head -10 filename.txt ---> to see the first 10 lines

tail filename.txt --> to see the last line

tail -10 --- > to see the last 10 lines

tail -f --> to see files/log, when it keep updating