Showing posts with label Solaris. Show all posts
Showing posts with label Solaris. Show all posts

31 July 2010

Run level - Solaris

The first thing I noticed was /etc/inittab file is different from the Linux version. However, runlevel are quite identical

Default Solaris Run Level

• S : Single user state (useful for recovery)
• 0 : Access Sun Firmware ( ok> prompt)
• 1 : System administrator mode
• 2 : Multi-user w/o NFS
• 3 : Multi-user with NFS
• 4 : Unused
• 5 : Completely shutdown the host (like performing a power-off @ OBP) 
• 6 : Reboot but depend upon initdefault entry in /etc/inittab

Solaris 8/9 Find out runlevel

To find out current runlevel use who command:

$ who -r

Output:

. run-level 3 Mar 3 14:04 3 0 S

Solaris changing runlevels after bootup

You need to use init command, for example change runlevel to 2.

# /sbin/init 2

Solaris changing the default runlevel

An entry with initdefault (in /etc/inittab file) is scanned only when init is initially invoked. init uses this entry to determine which run level to enter initially.

Open /etc/inittab file:

# vi /etc/inittab
Find out this entry:
is:3:initdefault:

Change is:3 to number you want, don't use S, 0, 6 ;). Save file.



* Only init states 0, 1, 5, 6, and S can be reached using shutdown.

22 August 2008

Sudoers file on Solaris 10

sudo is available from the SFWsudo package on Solaris 10.
To use it a /etc/sudoers file has been set but still leading to the following error

user NOT in sudoers

Hopefully, truss will help :-)

root@server:/# truss -o /tmp/output sudo ls

The /tmp/output file is answering the enigma:

root@server:/# grep sudoers /tmp/output
lstat("/opt/sfw/etc/sudoers", 0xFFBFFB28) = 0
open("/opt/sfw/etc/sudoers", O_RDONLY) = 4

The sudoers file to edit is in /opt/sfw/etc

29 May 2008

Soft limit & Hard limit

Most of us encountered to increase the limit of file descriptors while installing a high end 3pp(party product).In doing so we will encounter with two different kinds of limits i.e.soft vs hard.

Hard limits are a kernel-configurable item and users can't exceed them. Soft limits are the user defaults and users can change that using the ulimit command.

Basically, soft limits can be changed to anything up to the hard limit. Soft limits are warning barrier. When a user reaches the soft limit they will get an warning message but are still allowed to use more space up to the hard limit.

Since its a kernel tunable we have to define the value in /etc/system and /etc/sysctl.conf for Pre-Solaris 10 and Linux respectively.

E.g.,

To set a hard limit of 4096 and soft limit of 1024 in Solaris 8.

set rlim_fd_max=4096 [Refers Hard limit]
set rlim_fd_cur=1024 [Refers Soft limit]


To raise the allowed limit in Linux based distributions update either /etc/limits.conf or /etc/security/limits.conf

14 November 2007

Sun: Advanced Lights Out Manager

Sun™ Advanced Lights Out Manager (ALOM) is a system controller that enables you to remotely manage and administer the Sun server's.
ALOM works as soon as it is installed and power on the server. ALOM comes pre-installed on the below server models
  • Sun Fire V125 server
  • Sun Fire V210 server
  • Sun Fire V215 server
  • Sun Fire V240 server
  • Sun Fire V245 server
  • Sun Fire V250 server
  • Sun Fire V440 server
  • Sun Fire V445 server
  • Netra 210 server
  • Netra 240 server
  • Netra 440 server
ALOM enables us to monitor and control our server over a network, or by using a dedicated serial port for connection to a terminal or terminal server.
ALOM provides a command-line interface that we can use to remotely administer geographically distributed or physically inaccessible machines.
ALOM enables us to run diagnostics remotely such as power-on self-test (POST), that would otherwise require physical proximity to the server's serial port.


We can also configure ALOM to send email alerts of hardware failures, hardware warnings, and other events related to the server or to ALOM.


ALOM circuitry runs independently of the server, using the server's standby power. Therefore, ALOM firmware and software continue to function when the server operating system goes offline or when the server is powered off.

Note: Most of the people will refer this ALOM as remote console or SC console.