Professional Documents
Culture Documents
HUAWEI Confidential
Foreword
Features of the Solaris system
Major methods for daily management of
the Solaris system
HUAWEI Confidential
object
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
PROM
The PROM (OBP) firmware, which is also known as OBP or EEPROM, runs
immediately upon power-on of the system. The Prom firmware mainly serves
to:
test and initialize the system hardware;
change the startup order and the startup mode;
Set the systems bottom parameters ,such as scsi id.
HUAWEI Confidential
HUAWEI Confidential
The BootPROM
Upon completion of this module, you should be able to:
Describe the main functions of the boot programmable readonly memory (PROM) chip and NVRAM
Explain the basic elements of POST and the purpose of the
Stop key to control POST
Invoke some common boot PROM commands from the ok
prompt to customize how the system boots
Use boot command options to boot a system in different
situations
Demonstrate how to display the device tree to list all the
configured devices using the show-devs command
HUAWEI Confidential
The BootPROM
probe- :Use the commands to identify what peripheral devices (disks,
tape drives, or CDROMs) are currently connected to the system
Devalias: Using the command to determine a systems default boot
device
nvalias or nvedit : Create a custom device alias name for a new boot
device
Nvunalias: Delete a custom device alias name with the command.
eeprom :Use the command within the Solaris Operating Environment
to view or change the values of NVRAM parameters
Demonstrate the steps to interrupt an unresponsive system
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
For example
> ok help
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
Objectives
HUAWEI Confidential
Run Levels
A run level refers to an execution state of the system. It specifies a set of system services and
processes.
The following run levels are provided in the Solaris environment:
RL
Function
S,s
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
Action
Meaning
sysinit
To start the process before the access console, and not to handle the next item
until the completion of this process
initdefault
respawn
wait
To start the process, and not to handle the next item until the completion of
the process
powerfail
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
Chapter 2
HUAWEI Confidential
Web start wizard: console, witch means GUI mode on the monitor
suninstall: Character terminal interface mode
Jumpstart: Customized installation mode for multiple hosts
Network installation: To boot and install the system in network
mode
ok >boot cdrom
Later, set such system parameters that installation may
require.
HUAWEI Confidential
Objectives
Upon completion of this module, you should be
State
the different
able
to: installation methods available for the Solaris 8
Operating Environment software
Explain the hardware requirements for a Solaris 8 Operating
Environment installation
Identify the different Solaris 8 Operating Environment software
CD-ROM editions
List the five Solaris Software Groups
Demonstrate how to install the Solaris 8 Operating Environment
HUAWEI Confidential
HUAWEI Confidential
ok >
Note: Under the OS, do not directly press stop+A to enter the ok mode.
Solaris system startup:
Under the ok prompt characters, the system can
start in the following modes:
Ok > boot disk
disk
-s
HUAWEI Confidential
HUAWEI Confidential
Run-Level Transitions1
HUAWEI Confidential
or 6)
/usr/sbin/halt
//not suggested
/usr/sbin/poweroff
//not suggested
/usr/sbin/reboot
//not suggested
HUAWEI Confidential
# cd /etc ; ls -l
# cd /devices/pci@1f,0/pci@1,1/ide@3 ; ls -l
- Regular files
d Directories
l Symbolic links
b Block-special device files
c TECHNOLOGIES
Character-special
HUAWEI
CO., LTD.
device
HUAWEI files
Confidential
User group
Example:
#vi /etc/passwd
root:x:0:1:Super-User:/:/usr/bin/bash
daemon:x:1:1::/:
Note:
login_name:passwd_field:UID:GID:comment:home_directory:defau
lt_shell
HUAWEI TECHNOLOGIES CO., LTD.
HUAWEI Confidential
Add a user
useradd -u uid -g gid -d home_dir -m -k shell
username
Add a user group
groupadd -g gid groupname
Delete a user
userdel -r username
home directory
userdel username
HUAWEI Confidential
HUAWEI Confidential
package.
To obtain the software package information:
pkginfo
#pkginfo-d [device|pathname]-lpkg_name
Example:
# pkginfo |more
system
FJSVmdb
HUAWEI Confidential
# pkgadd-d[device|pathname]pkg_name
Example:
#pkgadd -d /cdrom/Solaris_3_SUNWaudio
Uninstall the software package
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
Instance Names
Instance names are abbreviated names assigned by the
HUAWEI Confidential
Reconfiguring Devices
Performing a reconfiguration boot
# touch /reconfig
# reboot -- -r
Ok boot -r
Using the devfsadm command
# devfsadm -c divice_class
# devfsadm -i diver_name
# devfsadm //normally, this command is enough
# drvconfig
Listing a System's Devices
The /etc/path_to_inst file
The prtconf command
The format command
HUAWEI Confidential
Reconfiguring Devices
Use the devfsadm command to reconfigure a device:
Limit configuration to a specific device type:
# devfsadm -c disk
HUAWEI Confidential
Reconfiguring Devices
Pre-Solaris 8 Operating Environment device reconfiguration is
handled with the drvconfig command.
HUAWEI Confidential
Disk Partitioning
In the SUN system, the disk is
HUAWEI Confidential
/dev/[r]dsk/c# t# d# s#
scsi controller number
Equipments scsi id
Equipments Logical Unit Number (LUN)
slice number
HUAWEI TECHNOLOGIES CO., LTD.
HUAWEI Confidential
#devfsadm -C
#drvconfig
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
nfs
Pseudo file systems:
HUAWEI Confidential
HUAWEI Confidential
# newfs /dev/rdsk/c0t0d0s5
Create a mount point
# mkdir /myfs
Mount a file system to a mount point
# df -k
or
# mount
# umount /myfs
Recover a file system
# fsckraw-device
Example: # fsck -y /dev/rdsk/c0t1d0s0
HUAWEI TECHNOLOGIES CO., LTD.
HUAWEI Confidential
HUAWEI Confidential
Troubleshooting
Repairing Important Files if Boot Fails
ok boot cdrom -s
Boot device: /pci@1f,0/pci@1,1/ide@3/cdrom@2,0:f File and args
-s
SunOS Release 5.8 Version Generic_106541-02 [UNIX(R) System
V
Copyright (c) 1983-1999 by Sun Microsystems, Inc.
Configuring the /dev and /devices directories
INIT: SINGLE USER MODE
# fsck /dev/rdsk/c0t0d0s0
# mount /dev/dsk/c0t0d0s0 /a
Use terminal login if need use vi editor to set :
# TERM=vt100
# export TERM
HUAWEI TECHNOLOGIES CO., LTD.
HUAWEI Confidential
HUAWEI Confidential
file
Device-to-fsck: To identify the local raw device file used to execute
fsck
Mountpoint: mount point
FS-type: Type of file system. In general, ufs is used for a local file
passes the check by the file system. The same figures indicate they
are checked concurrently.
Mount-at-boot: To decide that the file system is automatically
HUAWEI Confidential
the CD drive and FDD because it has started the service process
for volume management. If the system does not automatically
mount them, we can start the volmgt service manually.
#/etc/init.d/volmgt[start|stop]
# volcheck
HUAWEI Confidential
Chapter 5
HUAWEI Confidential
Chapter 5
HUAWEI Confidential
/etc/hosts
/etc/netmasks
/etc/nodename
hostname
/etc/inet/ipnodes
/etc/defaultrouter
HUAWEI Confidential
To display the network interfaces of active state in the system, use the
ifconfig command:
# ifconfig -a
HUAWEI Confidential
202.12.16.100
202.12.17.1
HUAWEI Confidential
Example: # netstat -r
Routing Table: IPv4
Destination
202.12.16.100
Gateway
Flags
10.72.88.69
UH
0 hme0
204.12.16.0
10.72.88.69
UG
10.72.88.0
10.72.88.69
2 hme0
default
10.72.88.254
UG
UH
17
localhost
localhost
228 lo0
HUAWEI Confidential
/etc/reslove.conf: To set the hosts domain name and the dns servers IP
HUAWEI Confidential
HUAWEI Confidential
root user.
For the root user to have the FTP right, modify the /etc/ftpuser
file under Solaris8 by commenting out the root user items.
For the root user to have the telnet right, modify the
/etc/default/login file by commenting out the
CONSOLE=/dev/console item.
HUAWEI Confidential
# kill -9 pid
# inetd -s
HUAWEI Confidential
# svcs -l telnet
# svcs -l ftp
To enable and disable ftp or telnet service
HUAWEI Confidential
# echo
"ses \"scsiclass,00.vSUN.pUniversal_Xport\"">>/etc/driver_aliases
Set system share memory for Sybase
HUAWEI Confidential
# mv /etc/rc3.d/S76snmpdx /etc/rc3.d/K06snmpdx
# /etc/init.d/init.snmpdx stop
# chmod 000 /usr/lib/snmp/snmpdx
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
Complete backup
Incremental backup
HUAWEI Confidential
system
System crashes
System break-in by an unauthorized user
HUAWEI Confidential
For example:
HUAWEI Confidential
HUAWEI Confidential
Command Format
ufsrestore options [ arguments ] [ filesystem ]
ufsrestore options [ arguments ] [ filenames . . . ]
Options:
t Lists the table of contents of the backup media.
r Restores the entire file system from the backup media.
x Restores only the files named on the command line.
i Invokes an interactive restore.
v Specifies Verbose mode. Displays pathnames to the terminal
screen as each file is being restored.
f Specifies the tape device name.
HUAWEI Confidential
1. ok boot cdrom -s
2. # mount /dev/dsk/c0t3d0s0 /a
3. # cd /a
4. # ufsrestore rvf /dev/rmt/0
5. # rm restoresymtable
6. # installboot bootblk /dev/rdsk/c0t3d0s0 cd /
HUAWEI Confidential
HUAWEI Confidential
HUAWEI Confidential
Thank You
www.huawei.com