How to determine installed patches on Solaris 10

To determine installed patches, simply use “showrev” command

# showrev -p | more
Patch: 121430-42 Obsoletes: 121435-04, 121437-02 Requires:  Incompatibles:  Packages: SUNWlucfg, SUNWlur, SUNWluu
Patch: 138709-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWlucfg
Patch: 138711-02 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWlucfg, SUNWlur, SUNWluu
Patch: 118367-04 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 118918-24 Obsoletes: 116781-02, 119012-03, 121282-02, 121284-02, 121292-01, 121473-01, 121476-01, 121478-01, 121786-01, 12344
4-01 Requires:  Incompatibles:  Packages: SUNWcsu, SUNWcsr, SUNWcsl, SUNWcnetr, SUNWcakr, SUNWckr, SUNWmdb, SUNWmdbr, SUNWcslr
Patch: 119042-10 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu, SUNWcsr, SUNWcsd, SUNWtnamr, SUNWkrbr, SUNWtnetr, SUNWgss
c, SUNWocfr, SUNWmdr, SUNWvolr, SUNWnfscr, SUNWbsr, SUNWpmr, SUNWnisr, SUNWatfsr, SUNWzoner, SUNWcnsr, SUNWpcr, SUNWpsr, SUNWefcr, S
UNWftpr, SUNWnfssr, SUNWntpr, SUNWpiclr, SUNWrcapr, SUNWrcmdr, SUNWslpr, SUNWsndmr, SUNWsshdr, SUNWaccr, SUNWdhcsr, SUNWkdcr
Patch: 119574-02 Obsoletes: 119267-01 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 119578-30 Obsoletes: 119330-01, 119331-01, 119559-01, 119576-01, 120635-02, 122396-01 Requires:  Incompatibles:  Packages: SU
NWcsu, SUNWcsl, SUNWckr, SUNWfmd, SUNWarc
Patch: 120044-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 120062-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu, SUNWloc
Patch: 120816-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu, SUNWesu, SUNWxcu4
Patch: 120830-06 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu, SUNWtoo, SUNWxcu4, SUNWxcu6
Patch: 120988-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 121012-02 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 121296-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 123015-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 123194-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 123319-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 123322-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 123326-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu, SUNWxcu4
Patch: 123328-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu, SUNWxcu4, SUNWxcu6
Patch: 123520-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu, SUNWxcu4
Patch: 124325-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 124997-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 125549-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 125894-01 Obsoletes: 125110-01 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 126260-01 Obsoletes: 122183-03 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 126262-01 Obsoletes: 125911-01 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 126419-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu, SUNWcsr
Patch: 126425-01 Obsoletes: 125810-01 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 126440-01 Obsoletes: 124244-02 Requires:  Incompatibles:  Packages: SUNWcsu, SUNWxcu4
Patch: 126538-01 Obsoletes: 121901-02 Requires: 119042-09 Incompatibles:  Packages: SUNWcsu
Patch: 127726-01 Obsoletes:  Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 127872-01 Obsoletes: 120618-01 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 127878-01 Obsoletes: 127876-01 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 127914-01 Obsoletes: 126145-01 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 127994-01 Obsoletes: 120128-02 Requires:  Incompatibles:  Packages: SUNWcsu, SUNWxcu6
Patch: 128300-03 Obsoletes: 122032-05, 125378-05 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 128330-01 Obsoletes: 121002-04 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 128342-01 Obsoletes: 118872-05 Requires:  Incompatibles:  Packages: SUNWcsu
Patch: 137017-01 Obsoletes: 125108-02 Requires:  Incompatibles:  Packages: SUNWcsu, SUNWxcu4, SUNWxcu6
Patch: 121453-02 Obsoletes: 120776-03, 121086-02, 119107-07 Requires: 119574-02, 119254-06 Incompatibles:  Packages: SUNWcsu, SUNWcs
r, SUNWccccrr, SUNWccccr, SUNWccfw, SUNWccsign, SUNWcctpx, SUNWccinv, SUNWcsmauth, SUNWppror, SUNWpprou, SUNWupdatemgru, SUNWupdatem
grr, SUNWswupcl, SUNWccccfg, SUNWccfwctrl, SUNWppro-plugin-sunos-base
Patch: 118833-36 Obsoletes: 118822-30, 118348-01, 118868-01, 120996-02, 121298-01, 119712-04, 119852-03, 119943-01, 119984-03, 12005
2-03, 120196-02, 121000-05, 117170-01, 117461-08, 118370-04, 118375-07, 118852-07, 118874-02, 118911-01, 118913-02, 118927-02, 11899
6-04, 119216-02, 119218-02, 119374-13, 119444-03, 119557-09, 119568-02, 119569-02, 119572-01, 119596-03, 119681-08, 119687-02, 11968
9-08, 119715-10, 119828-05, 119939-01, 119941-03, 119992-02, 119994-01, 119996-01, 120009-01, 120030-03, 120034-01, 120054-02, 12008
3-01, 120251-02, 120254-03, 120258-02, 120300-01, 120362-02, 120627-01, 121237-01, 121266-01, 121268-01, 121276-03, 121280-01, 12130
1-02, 121777-01, 121784-01, 121788-02, 121790-01, 121792-01, 121794-02, 121796-01, 121798-01, 121800-01, 121802-01, 121804-01, 12180
6-01, 121808-01, 121810-01, 121812-01, 121814-01, 121816-01, 121818-01, 121820-01, 121822-01, 121824-01, 121826-01, 121832-01, 12183
4-01, 121836-01, 121838-01, 121840-01, 121842-01, 121844-01, 121846-01, 121848-01, 121850-01, 121852-01, 121854-01, 121894-01, 12207
9-01, 122081-01, 122176-01, 122235-01, 122237-02, 122241-01, 122242-01, 122243-01, 122294-01, 122296-01, 122298-01, 122302-01, 12230

How to permit root to login Solaris 10 via SSH

1. By default, Solaris wont allow you to login remotely vias SSH.

2. To be able to login Solaris 10 remotely, /etc/ssh/sshd_config file must be edited and ssh deamon must restarted.

3. First, lets change /etc/ssh/sshd_config file. Open /etc/ssh/sshd_config and find below the line

PermitRootLogin no

4. If it is commented out, then uncomment it by removing # at the beginning line

#PermitRootLogin no

5. Change it as following and save the file.

PermitRootLogin yes

6. Now restart the ssh deamon.

bash-3.00#svcadm restart ssh

7. Done!

How to create symbolic link to a folder/file on Solaris 10

1.To create a symbolic link to a folder, see following command

2. bash-3.00#ln -s /target/folder_or_file /path/to/link/linkname

3. Done!

How to get fibre channel host bus adapter(HBA) information on Solaris 10

1. To get details of fibre channel host bus adapter(HBA) and link statistics on Solaris 10, you can use following command as a root

bash-3.00# fcinfo hba-port -l
HBA Port WWN: 2100001b32929953
OS Device Name: /dev/cfg/c1
Manufacturer: QLogic Corp.
Model: 375-3356-02
Firmware Version: 05.01.00
FCode/BIOS Version: BIOS: 2.2; fcode: 2.1; EFI: 2.0;
Serial Number: 0402R00-09XXXX2668
Driver Name: qlc
Driver Version: 20090519-2.31
Type: L-port
State: online
Supported Speeds: 1Gb 2Gb 4Gb
Current Speed: 4Gb
Node WWN: 2000001b32929955
Link Error Statistics:
Link Failure Count: 0
Loss of Sync Count: 0
Loss of Signal Count: 0
Primitive Seq Protocol Error Count: 0
Invalid Tx Word Count: 0
Invalid CRC Count: 0
HBA Port WWN: 2101001b32b29958
OS Device Name: /dev/cfg/c2
Manufacturer: QLogic Corp.
Model: 375-3356-02
Firmware Version: 05.01.00
FCode/BIOS Version: BIOS: 2.2; fcode: 2.1; EFI: 2.0;
Serial Number: 0402R00-093XXXX8
Driver Name: qlc
Driver Version: 20090519-2.31
Type: L-port
State: online
Supported Speeds: 1Gb 2Gb 4Gb
Current Speed: 4Gb
Node WWN: 2001001b32b29953
Link Error Statistics:
Link Failure Count: 0
Loss of Sync Count: 0
Loss of Signal Count: 0
Primitive Seq Protocol Error Count: 0
Invalid Tx Word Count: 0
Invalid CRC Count: 0
2. for more details of fcinfo, use man fcinfo

How to install Solaris 10 from scratch step by step – Part I

Today, I am going to demonstrate how to install Solaris 10 from scratch step by step. You will see screenshot of every step during installation that I have followed. Before taking next step, let see what we will need for/during installation. Requirements:

  1. DVD-ROM Driver
  2. Solaris 10 Installation DVD. If you dont have yet, you can get it from here.
  3. IP4 Address
  4. Default route/gateway address
  5. Hostname
  6. Netmask address
  7. 10GB Free disk space on your hard drive.
  8. A keyboard(Sun or Win Keyboard,doesnt matter). No need of mouse.
  1. Insert Sun Solaris 10 Installation DVD into driver and reboot the machine. After reboot you will see below screen. Select Solaris and enter to boot.

 

 

2. Now select Solaris Interactive

3. By using Up and Down keys, highlight your selection, use Space to select your keyboard layout and press F2 or Esc+2 to continue.

4. Press Enter to continue with console installation. 5. Type 0(zero) to select English 6. Please read instructions then press F2 or Esc+2 7. Then press F2 or Esc+2 8. Select Networked and press F2 or Esc+2 9. Select No for DHCP then press F2 or Esc+2 10. Enter hostname and press F2 or Esc+2 11. Enter IP Address and press F2 or Esc+2 12. Select Yes to be able to enter subnet address in next step 13. Enter Subnet address and press F2 or Esc+2 14. To be continued…

How to install a two-node cluster on Solaris 10

This Sun Cluster Two-Node Installation and Configuration How-To guide is intended to help a new or experienced Solaris user quickly and easily install and configure Sun Cluster software for two nodes, including the configuration of a quorum device. Users are guided step-by-step through the process, with examples and screenshots to simplify the process. This document will not cover the configuration of highly available services; that topic will be covered in a separate guide.

You can find the guide here.

How to check network interface’s status,speed on Solaris 10

1. There are two commands that can be very useful to see network interfaces status, and speed. But you must have root privileges to run them

bash-3.00# dladm show-dev
e1000g0         link: unknown   speed: 0     Mbps       duplex: half
e1000g1         link: unknown   speed: 0     Mbps       duplex: half
e1000g2         link: unknown   speed: 0     Mbps       duplex: half
e1000g3         link: unknown   speed: 0     Mbps       duplex: half
nxge0           link: up        speed: 1000  Mbps       duplex: full
nxge1           link: down      speed: 0     Mbps       duplex: unknown
nxge2           link: down      speed: 0     Mbps       duplex: unknown
nxge3           link: down      speed: 0     Mbps       duplex: unknown
nxge4           link: down      speed: 0     Mbps       duplex: unknown
nxge5           link: down      speed: 0     Mbps       duplex: unknown
nxge6           link: down      speed: 0     Mbps       duplex: unknown
nxge7           link: down      speed: 0     Mbps       duplex: unknown

2. Also you can see type of interface.

bash-3.00# dladm show-link
e1000g0         type: non-vlan  mtu: 1500       device: e1000g0
e1000g1         type: non-vlan  mtu: 1500       device: e1000g1
e1000g2         type: non-vlan  mtu: 1500       device: e1000g2
e1000g3         type: non-vlan  mtu: 1500       device: e1000g3
nxge0           type: non-vlan  mtu: 1500       device: nxge0
nxge1           type: non-vlan  mtu: 1500       device: nxge1
nxge2           type: non-vlan  mtu: 1500       device: nxge2
nxge3           type: non-vlan  mtu: 1500       device: nxge3
nxge4           type: non-vlan  mtu: 1500       device: nxge4
nxge5           type: non-vlan  mtu: 1500       device: nxge5
nxge6           type: non-vlan  mtu: 1500       device: nxge6
nxge7           type: non-vlan  mtu: 1500       device: nxge7

3. Done!

How to change the end of line character (^M) on Solaris 10

On Solaris 10, you may see ^M character on lines of ascii/text/xml etc.  files.

If file is transfered from Windows to Solaris, end of line character must be corrected.

To do that, use dos2unix command on Solaris 10

bash-3.00#dos2unix <filename> <filename>

Done!

How to count the number of files in a folder on Solaris 10

1. To get number of files in current directory

bash-3.00#find . -type f | wc -l

2. To get number of iles in a specific directory

bash-3.00#find /path/to/folder -type f | wc -l

3.Done!

How to change password on Solaris 10

1. Login to the Solaris 10 with an account that you want to change password or as a root

If you login as a root, run

  • 1. bash-3.00#passwd <your_username>
  • 2. Enter new password
  • 3. Re-enter new password
  • 4.Done!

If you login with your user, run

  • 1. bash-3.00#passwd
  • 2.Enter your current password
  • 3.Enter new password
  • 4.Re-enter new password
  • 5.Done!
Go to top