728x90
반응형


안녕하세요 오늘 저녁 포스팅 입니다.


일 때문에 하루종일 을지로에 있느라 을지로 특집입니다!! 


그럼 바로 갑니다!!



* 블로그장의 전체 총평 ( 2.3점 / 5점 )

모듬수육 55,000원짜리 두 개를 세 테이블에 나눠서 먹었는데.. 글쎄요... 양도 적고 먹을 수 있는 사람은 먹겠지만,

비쥬얼이 후덜덜 하더라구요.. 처음 먹는 사람이나, 여성 분들은 조금 드시기 힘들 수도 있을것 같습니다. (저야 없어서 못먹어서 다 먹습니다만...)


그리고, 메뉴판을 보시면 아시겠지만, 이 가게에서 나오는 고기들 전부가 국산인데, 한우, 젖소, 육우가 섞여 있다고 합니다.

이점 개인적으로는 마이너스네요..


MB가 왔다간 집이라 그런지 다들 유명한 곳이라고 그러는데, 기대가 커서 그런가요? 

가격, 맛, 가게 인테리어 등 모든 점에서 좀 실망했습니다.




종합하여 블로그장의 총평은!! 2.3점 드립니다.


추천: MB의 설렁탕 코스프레 하고 싶으신 분!

  설렁탕 포장으로 드실 분!!(포장은 만원에, 국물만 많이 준다고 합니다.)


비추천 : 깔끔한 가게와 음식을 원하시는 분


(주관적인 평가로 이에 대한 태클은 넣어둬~ )



1. 가게 위치 (서울 중구 을지로2가 101-32 1층)   




2. 메뉴판! 




3. 가게 전경 및 음식





 

728x90
반응형
728x90
반응형

안녕하세요 오늘 점심 포스팅 입니다.


을지로 쪽에 일이 있어서 오늘 내내 부득이 을지로 특집이네요..


그럼 바로 갑니다!!


* 블로그장의 전체 총평 ( 2.7점 / 5점 )

닭요리 전문점 답게 닭으로 한 요리가 많습니다.. 그리고 명동 옆이라 그런지 몰라도

종업원들이 일본어, 중국어하는 손님과 의사소통을 잘 하시더라구요..

외국인들끼리 와도 부담없이 원하는 음식을 시킬 수 있을것 같습니다. 


그러나!!! 제가 먹어본 닭갈비는 좀 맵고, 라면스프 맛이 좀 났어요.. 

매운맛은 콩나물냉국으로 어찌어찌 하는데, 라면스프 맛은 좀 별로 였네요..


종합하여 블로그장의 총평은!! 2.7점 드립니다.


추천: 각종 닭요리를 한번에 드시고 싶으신 단체손님

       

비추천 : 매운거 진짜진짜 못드시는 분


(주관적인 평가로 이에 대한 태클은 넣어둬~ )



1. 가게 위치 (서울 중구 을지로2가 101-15)




2. 메뉴판





3. 음식 및 가게전경


728x90
반응형
728x90
반응형
M계열 장비에 FRU Device 교체하는 방법에 대해 알아 본다!



용어 정리 
     FRU(Field Replaceable Unit) : 현장 교체 장치로 보통 hot swap이 가능한 장비를 지칭한다.

작업 순서
1. xscf> showhardconf   명령을 통해 하드웨어 장비의 장애를 확인하고, FRU 장치인지 확인
2. FRU 장치인 것을 확인 하였으면, xscf> replacefru  명령을 통해 단계적으로 조치
3. 조치 후 xscf> showhardconf 명령을 통해 장비의 장애 조치 확인
M계열의 FRU 장치는 FAN과 PSU를 뜻하며(Back Plne FAN 제외), 기타 PCI 카드 등은 OS 단에서 HOT Pulg 한다.


아래 LOG는 M4000 장비의 PSU 장치를 교체한 것을 적어두었다.

XSCF> replacefru
----------------------------------------------------------------------
Maintenance/Replacement Menu
Please select a type of FRU to be replaced.

1. FAN        (Fan Unit)
2. PSU        (Power Supply Unit)
----------------------------------------------------------------------
Select [1,2|c:cancel] :2

----------------------------------------------------------------------
Maintenance/Replacement Menu
Please select a PSU to be replaced.

No. FRU             Status
--- --------------- ------------------
1. PSU#0           Faulted
2. PSU#1           Normal
----------------------------------------------------------------------
Select [1,2|b:back] :1

You are about to replace PSU#0.
Do you want to continue?[r:replace|c:cancel] :r


이때 물리적으로 정상인 파트로 교체


Apr 14 12:01:00 xscf0 fmd: SOURCE: sde, REV: 1.17, CSN: BDF1048969  EVENT-ID: 80f3ea0d-5fa9-4b01-934b-81ea44c35c0c Refer to http://www.sun.com/msg/SCF-8002-LX for detailed information.
Please confirm the Ready LED is not lit and that the Check LED is
blinking.
If this is the case, please replace PSU#0.
After replacement has been completed, please select[f:finish] :f

Diagnostic tests for PSU#0 have started.
[This operation may take up to 3 minute(s)]
(progress scale reported in seconds)
   0.....  30..done

----------------------------------------------------------------------
Maintenance/Replacement Menu
Status of the replaced FRU.

FRU           Status
------------- --------
PSU#0         Normal
----------------------------------------------------------------------
The replacement of PSU#0 has completed normally.[f:finish] :f

----------------------------------------------------------------------
Maintenance/Replacement Menu
Please select a type of FRU to be replaced.

1. FAN        (Fan Unit)
2. PSU        (Power Supply Unit)
----------------------------------------------------------------------
Select [1,2|c:cancel] :c



728x90
반응형
728x90
반응형
HP P2000 Storage 장비의 디스크 교체에 대해서 알아 본다.

본 문서는 예전에 작성해 놓은 문서로 아마 UI가 조금 틀릴텐데 하는 방법은 지금까지도 같다.



작업 순서
1.SMU 접속
2. vdisk와 불량 disk 확인
3. 불량 디스크 제거
4. 1분 정도 후 SMU에서 제거된 Disk Bay를 확인하고, 그 자리에서 새 디스크를 삽입
5. SMU의 add visk spares 메뉴에서 새로 장착한 디스크를 선책 후 add vdisk spare 클릭
6. vdisk utility progress에서 진행 상황 확인 (Disk 용량에 따라 진행 속도가 다름)


VIRTUAL DISK CONFIG - vdisk configuration - vdisk status  클릭

위 이미지는 fail 난 disk는 빼고, 새 디스크를 넣은 다음 인클로져에서 디스크를 인지한 상태입니다.


VIRTUAL DISK CONFIG - vdisk configuration - add vdisk spares  클릭

Virtual disk config-Vdisk Configuration-add vdisk spares 로 가면 교체한 디스크에 체크 할 수 있도록 나옮니다. 위 이미지는 체크후 Add Vdisk Spares 버튼을 클릭한 후의 이미지입니다.


아래 이미지는 vdisk utility progress 이미지이고 Rebuilding진행률을 보여줍니다.





728x90
반응형
728x90
반응형
xscf의 version update에 대해서 알아 봅시다!!


 작 업   순 서 :
순번설명
1xscf LAN IP 할당 및 https 포트 enabled
2firmware version 확인
3
firmware download 및 upload
4fimware update
5firmware version 확인


본 문서는 xscf 구조 및 command 문서를 본 뒤에 봐야 이해가 쉽고, 1번은 앞 문서에 해당 내용이 기술되어 있으므로 생략한다.


2. firmware version 확인
XSCF> version -c xcp
XSCF#0 (Active )
XCP0 (Current): 1116
XCP1 (Reserve): 1116

xscf를 업데이트하는 주요 이유 중 하나는 xscf board 장애 시 EEPROM Panel과 XSCF 간 mismatch version 으로 인해 에러 로그가 발생하기 때문이다. EEPROM Panel version의 경우는 최초 xscf가 booting 될 때 로그인창에 뿌려주는 것을 제외하면 몇 버전인지 볼 수 있는 명령이 없다. 위 명령은 xscf board의 version을 확인하는 명령이다.

3. firmware download 및 upload
MOS(My Oracle Support)에서 xscf update 등의 검색어를 입력하면 firmware update 할 수 있는 파일이 출력되고, 각 장비마다 각 버전마다 Download Location을 제공한다.

https://support.oracle.com/epmos/faces/SearchDocDisplay?_adf.ctrl-state=r75d6qsnn_9&_afrLoop=783371501910563


파일을 다운로드 뒤 압축을 풀면 여러 파일들이 나타나는데, 업데이트 파일은 FFXCP1116.tar.gz 등으로 
장비타입VersionNumber.tar.gz  로 명명된다.

업로드를 위해서 XSCF LAN Port에 연결 후 https://장비_IP 로 접속한다.



접속 뒤 위 화면과 같이 Utilities - Firmware Update  탭에서 해당 업데이트 파일을 업로드를 하고, complete 메시지가 출력될 때까지 기다린다.

업로드 확인은 xscf 모드에서 아래와 같이 getflashimage -l 명령을 통해 확인한다.


XSCF> getflashimage -l
Existing versions:
        Version                Size  Date
        FFXCP1116.tar.gz   45794557  Mon Apr 14 12:35:39 KST 2014




4. xscf firmware update
XSCF> flashupdate -c update -m xcp -s upload된_버전     으로 update를 수행하고, 업데이트를 마친 뒤 xscf는 재기동을 한번 한다.

XSCF> flashupdate -c update -m xcp -s 1116        




5. xscf version 확인

XSCF> version -c xcp
XSCF#0 (Active )
XCP0 (Current): 1116
XCP1 (Reserve): 1116


728x90
반응형
728x90
반응형

Common Unix Commands

SysinfoDisplay system information i.e cpu, memory, etc
Memory and SwapInformation regarding the physical memory and swap area
Disks, Filesystems and DevicesDisplaying disk information, filesystems
NetworkingDisplay and configuring network parameters
Crash DumpConfigure, display and use the crash dump utiltities
Performance Monitoring and DiagnosticsList, Monitor and trace processes
Kernel Modules and ParametersDisplaying, modifying and tuning kernel parameters
ServicesDisplay, start and stop services
Patching / PackagesInstalling and removing patches and software packages
AccountsSetting up and removing user accounts
NFSInformation on NFS i.e starting, stopping, etc
NTPNetwork Time Protocol
Log FilesLocation to common log files
SecuritySecurity information
MiscOther stuff i.e shutdown, timezone, run level, etc

sysinfo

 
Solaris
Red Hat
Ubuntu/Debian
HP-UX
AIX
 
Server Release infocat /etc/releasecat /etc/enterprise-release
cat /etc/redhat-release

lsb_release -a

cat /proc/version

cat /etc/lsb-release

lsb_release -a
/stand/kernrel

 

oslevel -r

Server Release info
Server type/usr/platform/`uname -i`/sbin/prtdiag -vdmidecodedmidecode

model
uname -a

prtconf | grep -i 'System Model'Server type
Hardware Info

prtdiag -v
prtconf -D 
prtpicl -v [-c <class>]

picl = platform information and control library

lspci
lsusb
lshal

Note: hal = hardware abstraction layer

lspci
lsusb
lshal

ioscan
ioscan -fun [disk|tape|lan]

/opt/ignite/bin/print_manifest
cat /var/opt/ignite/local/manifest/manifest.info

lscfg -v 
lscfg -l ent0
lscfg -vl fcs0 (find the WWN of HBA adapter)

lsdev
lsdev -Cc disk
lsdev -Cc disk -p scsi0

lsslot -c [pci|phb|port]
lsslot -c pci -l ent0

lspath -l hdisk0

diag

Hardware Info
Operating Systemuname -auname -auname -auname -aoslevel [-r|-s]Operating System
Memory/usr/platform/`uname -i`/sbin/prtdiag -v
prtconf | grep -i mem

cat /proc/meminfo (detailed)
free -om

cat /proc/slabinfo

cat /proc/meminfo (detailed)
free -om

cat /proc/slabinfo

dmesg | grep -i physical
/usr/sam/lbin/getmem
/opt/ignite/bin/print_manifest

cat /var/opt/ignite/local/manifest/manifest.info

prtconf -m 
prtconf |grep -i memory
lsattr -El sys0 -a realmem
bootinfo -r 
Memory
CPU (type, number, etc)

/usr/platform/`uname -i`/sbin/prtdiag -v

## display,offline,online
psrinfo
psradm -f 0 (offline) 
psradm -n 0 (online) 

cat /proc/cpuinfo (detailed)cat /proc/cpuinfo (detailed)

/opt/ignite/bin/print_manifest
sam -> performance monitors -> system properties

cat /var/opt/ignite/local/manifest/manifest.info

prtconf |grep -i processorCPU (type, number, etc)
Disk Drives

format
prtvtoc <device>

format -e (to convert EFI (zfs) to SMI)

Note:
EFI - Extensible Firmware Interface
SMI - Sun Microsystems Inc

fdisk -l
sfdisk -l (advanced server)
parted <device> print
partprobe -s <device> 

smartctl -a <device>
fdisk -l
sfdisk -l (advanced server)
parted <device> print
partprobe <device>
ioscan -funC disklsdev -Cc disk
lsdev -Cc disk -p scsi0 (specific controller)
lsdev -Cc disk -S [a|d|s] (available, defined, stopped)

lscfg -v -l hdisk0
Disk Drives
Kernel File and associated directories

/kernel/genunix

/platform/`uname -m`/kernel
/platform/i86pc/kernel
/kernel
/usr/kernel

/boot/initrd.?????.img
/boot/vmlinuz
/boot/initrd.img-?????-server
/boot/vmlinuz-????-server
/stand/vmunix/unix

/usr/lib/boot
/usr/lib/drivers 

Note: /unix - symbolic link to kernel file i.e /usr/lib/boot/unix_64
Kernel File
Kernel 32 or 64isainfo -kv (solaris 9+)
isalist (sparc v9 will be listed first)
isainfo -b
uname -a
uname -m
getconf -a |grep -i 'long_bit'
cat /proc/version
uname -a
uname -m
getconf -a |grep -i 'long_bit'

getconf KERNEL_BITS ( version 11)
/opt/ignite/bin/print_manifest |grep -i 'os mode' 

HPUX < version 11 all 32 bit

Note: determine if system supports 64 bit
getconf HW_CPU_SUPP_BITS
/opt/ignite/bin/print_manifest |grep -i 'hw capability'

 

prtconf -k
bootinfo -K
Kernel 32 or 64
Display FirmwareAt the OK prompt type bannerboot into the BIOS (normally F2 or F12)boot into the BIOS (normally F2 or F12)

workstations:
reboot
enter PDC
type: IN (information menu) 
type: FV (Firmware Version)

prtconf |grep -i firmware 
lscfg -pv
invscout 
Display Firmware
Display IRQ, IO ports and DMAn/a/proc/interrupts
/proc/ioports
/proc/dma
/proc/interrupts
/proc/ioports
/proc/dma
n/aprtconfDisplay IRQ, IO ports and DMA
GUI admin tooladmintoollinuxconflinuxconfsamsmit
smitty
GUI admin tool

Memory and Swap

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
Memory/usr/platform/`uname -i`/sbin/prtdiag -v
prtconf | grep -i mem
cat /proc/meminfo (detailed)
free -om
cat /proc/meminfo (detailed)
free -om

dmesg | grep -i physical
/usr/sam/lbin/getmem
/opt/ignite/bin/print_manifest

cat /var/opt/ignite/local/manifest/manifest.info

prtconf -m 
prtconf |grep -i memory
lsattr -El sys0 -a realmem
bootinfo -r
Memory
page size (memory)/usr/bin/pagesize/usr/bin/getconf -a| egrep -i 'pagesize|page_size'/usr/bin/getconf -a| egrep -i 'pagesize|page_size'dmesg |grep -i physicalpagesize
pagesize -a (display all supported pagesizes)
page size (memory)
display swapswap -l
swap -s
cat /proc/swaps (detailed)
swapon -s
cat /proc/swaps (detailed)
swapon -s
swapinfo (displayed in KB)
swapinfo -m (display in Mb)
swapinfo -tm (total / Mb)
lsps -a (detailed) 
lsps -s
display swap
adding swap

mkfile 5m /var/swapfile 
swap -a /var/swapfile 

update /etc/vfstab

device:
create partition with fdisk (type 82)
file(create 50MB swap file):
dd if=/dev/zero of=/var/swapfile bs=1024 count=50000

mkswap <device>|<file>
swapon <device>|<file>

update /etc/fstab

device:
create partition with fdisk (type 82)
file(create 50MB swap file):
dd if=/dev/zero of=/var/swapfile bs=1024 count=50000

mkswap <device>|<file>
swapon <device>|<file>

update /etc/fstab
Create logical volume or filesystem

swapon <device> | -f <logical device>
swapon -p 3 <device> | -f <logical device>

update /etc/fstab

Note: -p = priority swap number . The nswapdevtunable system parameter controls the maximum number of swap devices.
mkps -a -s 4 -n <volume group>

# change the attributes 
chps -a n paging00 (don't use after restart)

# change the logical volume attributes (name in this case)
chlv -n <new name> <old old> (chang page space name) 

Note:

-a reconfigure paging space after restart
-s size of the page space (logical partitions)
-n activiates the paging space (use swapoff to deactivate)

also see /etc/swapspaces file
adding swap
removing swapupdate /etc/vfstab
swap -d
swapoff <device>|<file>

Remove device or file as normal
swapoff <device>|<file>

Remove device or file as normal
remove entry from /etc/fstab
reboot
swapoff /dev/paging00
rmps paging00 

Note: paging space must be deactiviated before removing
removing swap

Disks, Filesystems and Devices

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
Disk Drives

format
prtvtoc <device>
cfgadm -al
fcinfo hba-port
luxadm probe
mpathadm list initiator-port 
mpathadm show <initiator-port name>
iscsiadm list initiator-node
iscsiadm list discovery

format -e (to convert EFI (zfs) to SMI)

Note:
EFI - Extensible Firmware Interface
SMI - Sun Microsystems Inc

fdisk -l
sfdisk -l (advanced server)
parted <device> print
partprobe <device>

udevadm info -q all -n /dev/sda1
blkid
dmsetup [ls|info]

fdisk -l
sfdisk -l (advanced server)
parted <device> print
partprobe <device>
ioscan -funC disklsdev -Cc disk
lsdev -Cc disk -p scsi0 (specific controller)
lsdev -Cc disk -S [a|d|s] (available, defined,stopped)

lscfg -v -l hdisk0
Disk Drives
Disk serial Number, type, etcformat
iostat -En
luxadm inq <disk> (A5x00 disk arrays)
hdparm -i /dev/hda
hdparm -I /dev/hda (detailed)

hdparm -Tt /dev/hda (speed test)

sdparm -i /dev/sdb 

cat /proc/ide/ide0/hda/model
cat /proc/scsi/scsi
hdparm -i /dev/hda
hdparm -I /dev/hda (detailed)

haparm -Tt /dev/hda (speed test)

sdparm -i /dev/sdb 

cat /proc/ide/ide0/hda/model
cat /proc/scsi/scsi

diskinfo -v /dev/rdsk/c0t4d0 (detailed but no serial number)
/opt/ignite/bin/print_manifest (no serial number)

## Insure that the online diagnostic support tools have been installed
swlist -l bundle | grep 'Support Tools'

## Command-Line Support Tools Manager (cstm) 
## The run cstm 
cstm
cstm> map
cstm> sel dev 4       (select the disk of you choice)
cstm> info
cstm> il                  (obtain the serial number) 
cstm> quit 

lscfg -vl hdisk0
lscfg -vl hdisk*
Disk serial Number, type, etc
Disk disk partitionsprtvtoc <device>

cat /etc/vfstab

fdisk -l
sfdisk -l (advanced server)

cat /proc/partitions (very high level)
cat /etc/fstab

 

fdisk -l
sfdisk -l (advanced server)

cat /proc/partitions (very high level)
cat /etc/fstab

lvlnboot -v /dev/vg00 
lifls -Clv <device>

# Display the LIF contents
lifcp /dev/dsk/c0t6d0:AUTO - 

cat /etc/fstab

Note: Boot programs are stored in the boot area in Logical Interchange Format (LIF), which is similar to a file system. For a device to be bootable, the LIF volume on that device must contain at least the ISL
(the initial system loader) and HPUX (the HP-UX bootstrap utility) LIF files. ISL is like GRUB.

lsvg -l rootvg 
lchangelv

cat /etc/filesystems

Disk disk partitions
List Raw Partitionsuse format to partition the disk then just use the slice as a raw partition, remember to use the character device

## Old way 
/etc/sysconfig/rawdevices
service rawdevices start
chkconfig rawdevices on

## New way, Edit below file 
/etc/udev/rules.d/60-raw.rules
udevinfo -d or udevadm info

## Display raw partitions 
raw -qa

mknod /dev/rawctl c 162 0
mknod /dev/raw/raw0 c 162 1
mknod /dev/raw/raw1 c 162 2
ln -s /dev/rawctl /dev/raw/rawctl

## map raw devices to the disk
raw /dev/raw/raw1 /dev/sdb1

## display raw devices
raw -qa
Just create a new LVOL without a filesystem - that's it.

Just create a new LVOL without a filesystem

# create a raw volume
mklv -y rawVolume vg01 10

 

List Raw Partitions
Bad Blocksformat (use analyse )badblocksbadblocksdd if=/dev/rdsk/cXtYd0 of=/dev/null bs=1024K

Note: no errors means disk is good
chlv -b [y|n] <lv>

Note: enables bad block relocation
 
Filesystem commandsdf -k
df -h 
df -k 
df -h
df -k
df -h
bdf
df [-egiklnvfb]
df -k 
lsfs [<filesystem>] 
lsfs -q <filesystem> (detailed) 
Filesystem commands
Filesystem (create|remove)newfs -v <raw device>

# Display how the filesystem was created 
newfs -Nv <filesystem>

mkfs -t ext3 /dev/sdb1 
mke2fs -t ext4 /dev/sdb1

# all point to mke2fs 
mkfs.ext2
mkfs.ext3
mkfs.ext4 

cat /etc/mke2fs.conf

mkfs -t ext3 /dev/sdb1newfs -F vxfs -o largefiles /dev/vg01/rlvol1

mkfs -F vxfs -o largefiles /dev/vg01/rlvol1

Note: mkfs and newfs are a pointer to /sbin/fs_wrapper 

crfs -v jfs2 -d data02lv -m /data02 -A yes

-v filesystem type
-d device or logical volume
-m mountpoint
-A mount after restart [yes|no]

rmfs -ri /data02

-r remove the mountpoint
-i display warning before removing

chfs -a size=+1G /var (grow by additional 1GB) 
chfs -a size=1G /var (grow to 1GB in size)

Filesystem (create|remove|resize)
Tune Filesystemstunefs
fstyp -v <device> |grep -i minfree

tune2fs
tune2fs -l /dev/sda1

# change reserved blocks percentage to 1%
tune2fs -m 1 /dev/sda1

tune2fs
tune2fs -l /dev/sda1

# change reserved blocks percentage to 1%
tune2fs -m 1 /dev/sda1

tunefs -v <filesystem>
vxtunefs -v <filesystem> 
fstyp -v <filesystem>

# Disk fragmentation
fsadm -F vxfs -E / (report)
fsadm -F vxfs -e / (defrag)
chfs

Note: you can perform the following
resize
freeze
change mountpoint
permissions
lots more..............................
Tune Filesystems
Force fsck



# Check to see filesystem needs checking
fstyp -v <filesystem> | grep fsclean

touch /forcefsck
shutdown -Fr now
fsck.mode=force (kernel parameter) 


tune2fs -l /dev/sdb<?> |grep -i 'filesystem state'

touch /forcefsck
shutdown -r now


tune2fs -l /dev/sdb<?> |grep -i 'filesystem state' 

# edit /etc/default/rcS change below so 
# you dont have to hang around 
FSCKFIX=yes

 

 

# Look at the second line to see if a filesystem 
# needs checking 
tunefs -v <filesystem>

n/aForce fsck
backup filesystemufsdump|ufsrestore
tar
dd
cpio
dump/restore
tar
dd
cpio
dump/restore
tar
dd
cpio
fbackup/frecover
dump/restore
ftio 
tar
dd
cpio
backup|restore
tar
dd
cpio
backup filesystem
Display the boot deviceeeprom |grep boot-device 
prtconf -pv |grep bootpath 
prtpicl -v|grep ':bootpath'

cat /boot/grub/grub.conf
cat /etc/lilo.conf

grub = grand unified boot loader
lilo = linux loader

cat /boot/grub/menu.lstsetbootbootinfo -b (display last boot device) 
bootlist -m [normal|service] -o (display bootable devices)
Display the boot device
Setting the boot devicesetenv boot-device [<device>|<alias>]
eeprom boot-device [<device>|<alias>]

/boot/grub/grub.conf
/etc/lilo.conf

 

/boot/grub/menu.lstsetboot -p <primary path>
setboot -a <alternate path>

# autoboot sequnce 
setboot -b [on|off]
bootlist -m normal hdisk0 hdisk1Setting the boot device
Creating boot device (MBR)installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk <raw-device>grub-install <raw-device> 
lilo -v
grub-install <raw-device>mkboot -l <device>

Note: we are treating the disk as a LVM device
bosboot -a (uses default device)
bosboot -ad hdisk1
Creating boot device (MBR)
Format floppy drivefdformat -v -U
volcheck -v
newfs -v /vol/disk/aliases/floppy0
floppy --probe (use device obtained below ) 
floppy --createrc > /etc/fd0
floppy --format /dev/fd0
mkfs /dev/fd0
n/an/aformat -d /dev/rfd0
format -d /dev/fd0.18 (high format)
Format floppy drive
mount/unmount floppyvolrmmount -l floppy0
eject floppy
mount /dev/fd0 /mnt/floppy
umount /mnt/floppy
n/an/amount /dev/rfd0 /floppymount/unmount floppy
mount/unmount CDROMmount -F hsfs -o ro <device path> /cdrom/cdrom0
umount /cdrom/cdrom0

/etc/init.d/volmgr start
eject cdrom

mount -rt iso9660 /dev/cdrom /mnt/cdrom
umount /mnt/cdrom
eject cdrom

mount -rt iso9660 /dev/cdrom /mnt/cdrom
umount /mnt/cdrom
eject cdrom

mount -rF cdfs /dev/dsk/c1t6d0 /cdrom

start: /usr/sbin/pps_mountd
pps_mount

mount -v cdrfs -r /dev/cd0 /cdrom
umount /cdrom
mount/unmount CDROM
mount/umount ISO image

lofiadm -a <iso image> /dev/lofi/1
mount -F hsfs -o ro /dev/lofi/1 /mnt

# to list
lofiadm

     
remount a filesystemn/amount -o remount,rw /mount -o remount,rw /mount_vxfs -o remount,ro <filesystem>

mount -o remount,rw <filesystem>

Note:I did find a note that it should be possible to remount a jfs2 filesystem, but it did not work on my system

remount a filesystem
create boot disk or recovery tapen/amkbootdisk `uname -r` (boot diskette)n/arecovery tape (preview)
make_tape_recovery -v -l -x inc_entire=vg00
/opt/ignite/bin/make_recovery -ACv
mksysbcreate boot disk or recovery tape
boot cdrom/diskette (single user)ok> boot cdrom -susing the grub window append the word singleto the kernel lineusing the grub window append the word singleto the kernel lineenter PDC
> search 
>boot p1 (cdrom) 
interact with IPL? Y
ISL> hpux -is
based on a 9114-275 workstation
  1. Restart the machine.
  2. Wait the the AIX splash screen to come up. Devices begin to initialize here.
  3. When you see the [keyboard] word on screen hit the F5 button or the 5 key depending on your console.
  4. Choose “default boot list ” when the maintenance screen comes up.
boot cdrom/diskette (single user)
boot into maintenace modeok> boot -asf10 or f12f10 or f12>boot pri 
interact with IPL? Y
ISL> hpux -lm
based on a 9114-275 workstation
  1. Restart the machine.
  2. Wait the the AIX splash screen to come up. Devices begin to initialize here.
  3. When you see the [keyboard] word on screen hit the F5 button or the 5 key depending on your console.
  4. Choose “select boot options ” when the maintenance screen comes up, then option 1, then option 1 for scsi, then option 3 service mode boot
boot into maintenace mode
Device pathsfloppy:

disk:
/dev/dsk/c0t0d0s0

tape:
/dev/rmt/0ucb

cdrom:
/dev/dsk/c0t6d0s0
/dev/scd0 (external usb cd)

floppy:
/dev/fd0

disk:
/dev/hda or /dev/sda 
/dev/hdb or /dev/sdb

tape:

cdrom:
/dev/hda (depends on number of IDE disks)

floppy:
/dev/fd0

disk:
/dev/hda or /dev/sda 
/dev/hdb or /dev/sdb

tape:

cdrom:
/dev/hda (depends on number of IDE disks)

floppy:
n/a

disk:
/dev/dsk/c0t6d0

tape:
/dev/dsk/rmt/0

cdrom:
/dev/dsk/c1t6d0

floppy:
/dev/fd0
/dev/rfd0

disk:
/dev/hdisk0

tape:

cdrom:
/dev/cd0

Device paths
update /dev directorydrvconfig
devlinks
disks|tapes|ports

devfsadm ( solaris 8, 9, 10)
/dev/MAKEDEV <device>/dev/MAKEDEV <device>

insf -C tape (Class)

insf -H 0.1.0 -e (recreate deleted link)

cfgmgr
cfgmgr -l scsi0

mkdev

update /dev directory
remove or change a devicerem_drv  # remove all devices from a hardward path 
rmsf -k -H 52.6.0
rmdev
rmdev -l cd0

chdev
chdev -l rmt0 -a ret=no
remove or change a device
list device driversprtconf -D 
sysdef
cat /proc/devicescat /proc/deviceslsdev

lsdev
lsdev -Cc disk
lsdev -Cc disk -p scsi0

lsslot -c pci -l ent0

lscfg
lscfg -l ent0
lscfg -vl fcs0 (find the WWN of HBA adapter)

lspath -l hdisk0 

getconf DISK_SIZE hdisk1 (detailed)

list device drivers


Networking

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
Basic network information 
  (hostname, ip address)
/etc/hostname.hme0/etc/sysconfig/network
/etc/sysconfig/network-scripts/ifcfg-eth0
/etc/network/interfaces/etc/rc.config.d/netconfstores information in the ODM (Object Database Manager)Basic network information
  (hostname, ip address)
displaying network interfaces

prtdiag -v 
ifconfig -a 

kstat hme:0:parameters:<param name> 
kstat e1000g:0:parameters:<param name>

module:instance:name:statistics

# Solaris 11 
netadm list

dladm show-phys
dladm show-link
dladm show-linkprop
dladm show-vnic
dladm show-etherstub 

ipadm show-if
ipadm show-ifprop 
ipadm show-addr
ipadm show-addrprop

ifconfig
system-config-network (GUI)
ifconfigioscan -funC lan (list hardware) 
lanscan -v (list configured)
ifconfig lan0 (individual)
ifconfig -a

entstat -d <interface>

lsdev -Cc if
lsdev -Cc tcpip

odmget -q "name=en0" CuAt

lsattr -EHl en0 
displaying network interfaces
Configure network interface

ifconfig

# Solaris 11 - Automatic (using profiles) 
netadm enable -p ncp Automatic
netcfg       (use by Automatic) 

# Solaris 11 - Manual
netadm enable -p ncp DefaultFixed
netcfg 

dladm create-vnic
dladm delete-vnic 
dladm rename-link

dladm create-etherstub

ipadm create-ip net1 
ipadm create-addr -T static -a 192.168.0.110/24 net1/pfv 
ipadm delete-ip
ipadm delete-addr

ifconfigifconfigifconfig <interface>

mktcpip (completely setup a network interface)
rmtcpip (remove all network interfaces)

# configure an interface
mktcpip -h aix1 -a 192.168.1.200 -m 255.255.255.0 -i en1 -g 192.168.0.10

-h - hostname assigned to interface
-a - ip address
-m - netmask
-i - interface name
-g - gateway ip address

# remove an interface
ifconfig en1 detach 

ifconfig (configures IP address)

chdev (add aliases to network interface)

Configure network interface
Starting and stopping a network interfaceifconfig qfe0 up
ifconfig qfe0 down
/sbin/ifup eth0
/sbin/ifdown eth0
/sbin/ifup eth0
/sbin/ifdown eth0

ifconfig lan0 up
ifconfig lan0 down

note: there is no "ifconfig -a" in hpux use lanscan then "ifconfig <interface>"

ifconfig en0 up
ifconfig en0 down
ifconfig en0 detach (remove)

Starting and stopping a network interface
Setting NIC speedndd -set <device> <parm> <value> (dynamically) 
/etc/system (edit and update then reboot - permanent)
mii-tool -F 100baseTx-FD eth0
ethtool -s eth1 speed 100 duplex full
ethtool -s eth1 speed 100 duplex fullndd -set <device> <parm> <value>
lanadmin -X <option> lan0
chdev -l ent0 -a media_speed=1000_Full_Duplex -P
chdev -l ent0 -a media_speed=Auto_Negotiation -P 

Note:
entX - physical device
enX - frame type run on entX
Setting NIC speed
Change NIC parameters

ndd -get <device> <parm>

# List parameters 
ndd -get /dev/hme \?
ndd -get /dev/e1000g0 \?
ndd -get /dev/ip \?
ndd -get /dev/tcp \?

mii-tool -v 
ethtool eth1
ethtool -t eth0 online 

sysctl -a | grep net*

ethtool eth0 

sysctl -a |grep net*

lanadmin -> lan -> display

## options supported 
ndd -get /dev/ip ?
ndd -get /dev/tcp ?
ndd -get /dev/arp ?
ndd -get /dev/udp ?

netstat -v
entstat -d <interface> 

no -a
no -o "ipforwarding=1"

NIC speeds or Parameters
Display NIC statistics   netstat -i [-I interface] 
netstat -s
netstat -i [-f inet] 
netstat -s 
entstat -d <interface>
Display network statistics
display MAC addressifconfig -a (as user root)ifconfig
system-config-network (GUI)
ifconfiglanscannetstat -iadisplay MAC address
Displaying network packetssnoop -d <interface>

tcpdump -i <interface>

ethereal (needs to be installed)

tcpdump -i <interface>

ethereal (needs to be installed)

nettl -start
nettl -status all
nettl -tn pduin pduout -e ns_ls_driver -file /var/adm/LAN
nettl -stop

use netfmt to display the trace file

tcpdump -i <interface> 
iptrace -i <interface> <output file>
ipreport (used with iptrace to view reports) 

Note: you must stop the iptrace by using "kill -15"

Displaying network packets
default router/etc/defaultrouter

route add default <gateway> 
route -p add default <gateway> (persist changes)

edit /etc/sysconfig/network

add: GATEWAY=<IP address>

edit /etc/network/interfaces

add: gateway <IP address>
/etc/rc.config.d/netconfroute add 0 <gateway IP address>

Note: there is no file that holds the default router
default router
display routing tablenetstat -rnnetstat -rn
route -n
netstat -rn
route -n
netstat -rnnetstat -rn
netstat -r -f inet
lsattr -EHl inet0 -a route
display routing table
Test IPMP, Bonding

if_mpadm -d           (detach)
if_mpadm -r           (reattach)

tail /var/adm/messages

ifenslave -d bond0 eth1   (detach) 
ifenslave bond0 eth1       (reattach)

cat /proc/net/bonding/bond0

# create bonding
/etc/sysconfig/network-scripts/ifcfg-bond0

# modprobe
/etc/modprobe.d/bonding.conf

# for bonding options - use BONDING_OPTS 
/etc/sysconfig/network-scripts/ifcfg-bond0

# see bonding mode
cat /sys/class/net/bond0/bonding/mode

ifenslave -d bond0 eth1   (detach) 
ifenslave bond0 eth1       (reattach)

cat /proc/net/bonding/bond0

You buy an optional product called Auto-Port Aggragation.smitty etherchannel (creates, deletes and tests) 

entstat -d ent0
Test IPMP, Bonding
change the hostname

change the following files:

/etc/nodename
/etc/hostname.<interface>
/etc/inet/hosts
/etc/inet/ipnodes
/etc/net - few files in here as well 

# Solaris 11
svccfg -s system/identity:node listprop config/nodename

svcfg -s system/identity:node setprop config/nodename = astring: hostname
svcadm refresh system/identity:node
svcadm restart indentity:node

/etc/sysconfig/network
/etc/hosts

sysctl -a |grep hostname
/etc/hostname
/etc/hosts

sysctl -a |grep hostname
set_parms hostname (requires reboot)hostname <new hostname> 
chdev -l inet0 -a hostname=<hostname>
change the hostname
setup DNS

/etc/resolv.conf

# Solaris 11 - You need to use the svccfg command
svccfg -s dns/client listprop config/nameserver
svccfg -s dns/client listprop config/search
svccfg -s name-service/switch listprop config/host
svccfg -s name-service/switch listprop config/password

svcprop <pattern>

Note: just use listprop on its own to view all options 

svccfg -s "dns/client" setprop "config/nameserver = net_address: (192.168.0.1)"
svccfg -s "dns/client" setprop 'config/domain = astring: ("datadisk.co.uk")' 
svccfg -s "name-service/switch" setprop 'config/host = astring: "file dns"'
svcadm refresh name-service/switch
svcadm refresh dns/client

/etc/resolv.conf/etc/resolv.conf/etc/resolv.conf/etc/resolv.confsetup DNS
Name service switch file (DNS client)

/etc/nsswitch.conf
/etc/resolv.conf

# Solaris 11 - you need to use the svccfg command 
see above

/etc/nsswitch.conf
/etc/host.conf
/etc/resolv.conf
/etc/nsswitch.conf
/etc/host.conf
/etc/resolv.conf
/etc/nsswitch.conf
/etc/resolv.conf
/etc/netsvc.conf
/etc/resolv.conf
/etc/irs.conf (may not be there) 

chnamsv     (change name service) 
rmnamsv     (remove a name service) 
lsnamsv -C   (list name services) 
Name service switch file (DNS client)
Flush DNS cachesvcadm restart system/name-service-cache:default## if installed 
service nscd restart
 n/anetcdctrl -t dns -e hosts -fFlush DNS cache
Domain Name/etc/defaultdomain/etc/sysconfig/network  (HOSTNAME option)
/etc/resolv.conf 

Note: for NIS use the NISDOMAIN option
/etc/host
/etc/resolv.conf
/etc/rc.config.d/netconfdomainname <domainname>Domain Name
Obtain IP Address routingroute -n get <hostname>
traceroute
ip route get <IP address> 
traceroute
ip route get <IP address>
traceroute
n/aroute -n get <hostname>Obtain IP Address routing
Find Services on the network

Boot (jumpstart) servers:
rpcinfo -b bootparam 1

NFS servers:
rpcinfo -b mountd 1

NIS servers/slaves:
rpcinfo -b ypserv 1

Boot (jumpstart) servers:
rpcinfo -b bootparam 1

NFS servers:
rpcinfo -b mountd 1

NIS servers/slaves:
rpcinfo -u <yp server> ypserv

Boot (jumpstart) servers:
rpcinfo -b bootparam 1

NFS servers:
rpcinfo -b mountd 1

NIS servers/slaves:
rpcinfo -u <yp server> ypserv

Boot (jumpstart) servers:
rpcinfo -b bootparam 1

NFS servers:
rpcinfo -b mountd 1

NIS servers/slaves:
rpcinfo -b ypserv 1

Boot (jumpstart) servers:
rpcinfo -b bootparam 1

NFS servers:
rpcinfo -b mountd 1

NIS servers/slaves:
rpcinfo -b ypserv 1

Find Services on the network

Crash Dump

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
Crash Dump

dumpadm -d <device>
coreadm

crash (used to analyse crash dumps)
adb (used to analyse crash dumps)

diskdump
netdump
kdump (part of kexec rpm)

/etc/kdump.conf (select where you want the dump to go) 
service kdump start
chkconfig kdump on

## to crash the system
echo "c" > /proc/sysrq-trigger

crash (used to analyse crash dumps)

diskdump
netdump
kdump (part of kexec rpm)

/etc/kdump.conf (select where you want the dump to go) 
service kdump start
chkconfig kdump on

## to crash the system
echo "c" > /proc/sysrq-trigger

crash (used to analyse crash dumps)

edit /stand/system

add either:
dump 2/0/1.5.0
dump lvol
dump none

# crash config file
/etc/rc.config.d/savecrash

 

sysdumpdev -l (list dump destination)
sysdumpdev -e (estimates dumpsize)
sysdumpdev -L (info)

sysdumpstart -p (start dump primary)
sysdumpstart -s (start dump secondary)

# set the dump device permanently 
sysdumpdev -p <dump device> -P 

# analyse dump file
echo "stat\n status\n t -m" | crash /var/adm/ras/vmcore.0

Crash Dump

Performance Monitoring and Diagnostics

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
CPUtop (sunfreeware)
prstat 
sar
mpstat
w          (load average)
uptime   (load average) 
ps
vmstat
top
sar
mpstat
w          (load average)
uptime   (load average) 
ps
vmstat
procinfo
oprofile
cat /proc/cpuinfo
top
sar
mpstat
w          (load average)
uptime   (load average) 
ps
vmstat
procinfo
cat /proc/cpuinfo
top
sar
w          (load average)
uptime   (load average) 
ps
vmstat
glance
sam

topas -P
topas -L  (logical partitions) 
mpstat
sar -c 
w          (load average)
uptime   (load average) 
lparstat
ps
iostat -tT 1
tprof
curt 

CPU
Memoryprstat
vmstat
top
sar
free
vmstat
top
procinfo
slabtop
sar
cat /proc/meminfo 
free
vmstat
top
procinfo
slabtop
sar
cat /proc/meminfo
top
vmstat
sar
sam
glance
topas
vmstat
sar -b
svmon
ps
ipcs -a
lockstat (version 4) 
rmss 
Memory
Networkndd
netstat
lsof
snoop
route
ethtool
mii-tool
netstat
lsof
tcpdump 
ip
iptraf
nmap
ethtool
mii-tool
netstat
lsof
tcpdump 
ip
iptraf
netstat
lanadmin
sam
glance 
[ent|tok|fddi|atm]stat
netstat
netpmon (trcstop to stop trace)
Network I/O
Disksar -d
iostat
vmstat
lsof
sar -d
iostat
vmstat
lsof
sar -d
iostat
vmstat
lsof
iostat
sar
sam 
glance
topas -D   (disk)
topas -F   (filesystem) 
iostat
sar -D 
fcstat (fibre)
lvmstat
filemon (trcstop to stop) 
fileplace

# disk stat history 
chdev -l sys0 -a iostat=true
lsattr -HEl sys0 -a iostat
Disk I/O
Applicationtruss -p <pid> 
ppriv -D -e <command>
strace -p <pid>strace -p <pid>download and install tusc

tusc -p <pid>

topas
truss
sar 
probevue
tprof
svmon -P <pid>

Application
NFSnfsstatnfsstatnfsstatnfsstatnfsstat
NFS
Processtop
prstat
ps -ef 
pargs <pid> 
pcred <pid> 
pfiles <pid> 
pflags <pid> 
pgrep <pattern> 
pkill <pattern> 
pmap <pid> 
pldd <pid> 
preap <pid> 
prun <pid> 
psig <pid> 
pstack <pid> 
pstop <pid> 
ptime <pid> 
ptree <pid> 
pwait <pid> 
pwdx<pid>
     


Kernel Modules and Parameters

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
display loaded modulesmodinfocat /proc/modules (more detailed) 
lsmod
modinfo <module> 

Location: 
/lib/modules/`uname -r`/kernel/drivers

Config:
/etc/modprobe.conf
/etc/modprobe.d

cat /proc/modules (more detailed) 
lsmod

Location: 
/lib/modules/`uname -r`/kernel/drivers

Config:
/etc/modprobe.d/options
/etc/modprobe.d

kmadmin -k 
genkexdisplay loaded modules
load modulesmodload -p drv/<module name> 
modprobe <module>
insmod
modprobe <module>
insmod
kmadmin -L <module name>n/aload modules
unload modulesmodunload -i <module number>modprobe -r <module>
rmmod
modprobe -r <module>
rmmod

kmadmin -U <module name> 
kmadmin -u <module id>

n/aunload modules
set kernel parameters (tuning)/etc/system (edit and reboot)/etc/sysctl.conf (edit and update then reboot)
sysctl -p <filename>

sysctl -w param=value 

No reboot (dynamically):
echo "250 32000 100 28" > /proc/sys/kernel/sem
echo "536870912" > /proc/sys/kernel/shmmax
echo "4096" > /proc/sys/kernel/shmmni
echo "2097152" > /proc/sys/kernel/shmall
etc.............................................

/etc/sysctl.conf (edit and update then reboot)
sysctl -p <filename>

sysctl -w param=value 

No reboot (dynamically):
echo "250 32000 100 28" > /proc/sys/kernel/sem
echo "536870912" > /proc/sys/kernel/shmmax
echo "4096" > /proc/sys/kernel/shmmni
echo "2097152" > /proc/sys/kernel/shmall
etc.............................................

kcweb (11i) 
kctune (11i only)
rebuild kernel (< 11i see below)

chdev -l sys0 -a <parameter>=<value>
no -a          (network)
vmo -a        (virtual memory) 
nfso -a        (NFS)
ioo -a         (Input/Ouput) 
raso -a        (reliability, availability, serviceability) 
schedo -a   (processor scheduler) 

vi /etc/security/limits
cd /etc/tunables

tunchange, tundefault, tunsave, tunrestore, tuncheck 

Note: most parameters are dynamically changed in AIX , for example memory segments are dynamically adjusted

set kernel parameters
display kernel parameterscat /etc/system
sysdef -i
sysctl -a
cat /etc/sysctl.conf

cat /proc/sys/kernel/sem
cat /proc/sys/kernel/shmmax
etc...................................
sysctl -a
cat /etc/sysctl.conf

cat /proc/sys/kernel/sem
cat /proc/sys/kernel/shmmax
etc...................................
kctune (11i only)
sysdef
kmtune
kmsystem
/usr/sam/lbin/getkinfo -f /stand/vmunix -o /tmp/kernel.data
lsattr -EHl sys0 

Note: only a few kernel parameters can be changed
display kernel parameters
build kernel

edit and update file then reboot:
/etc/system

cd /usr/src/linux-2.5
edit Makefile (change EXTRAVERSION)
make mrproper
backup .config
make xconfig
make dep
make bzImage
make modules
move new kernel
make modules_install
change lilo/grub config file
reboot
 

cd /stand/build
/usr/lbin/sysadm/system_prep -v -s system
edit system file
/usr/sbin/mk_kernel -s ./system
mv /stand/system /stand/system.old
mv /stand/vmunix /stand/vmunix.old
mv /stand/build/system /stand
mv /stand/build/vmunix_test /stand/vmunix
reboot

chdev -l sys0 -a <parameter>=<value>

Note: most parameters are dynamically changed in AIX , for example memory segments are dynamically adjusted
build kernel
interprocess communicationipcs -aipcs -aipcs -aipcs -aipcs -ainterprocess communication

Services

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
display services

svcs -a
svcs -l <service>
svcs -vx 
inetadm -l

service --status-allThere is no services or chkconfig command use the old fashioned way /etc/init.d/<service>There is no services or chkconfig command 
use the old fashioned way /sbin/init.d/<service>
lssrc -adisplay services
start servicessvcadm enable nfsservice nfs startstartsrc -s <subsystem>
startsrc -g <group>
start services
stop servicessvcadm disable nfsservice nfs stopstopsrc -s <subsystem>
stopsrc -g <group>
stop services
reload servicesvcadm refresh nfs
svcadm clear nfs (changes state)
service nfs reloadrefresh -s <subsystem>reload service
restart servicesvcadm restart nfsservice nfs restartstopsrc -s <subsystem> 
startsrc -s <subsystem>
restart service
service statussvcs nfsservice nfs stauslssrc -aservice status
service dependenciessvcs -d networkn/an/aservice dependencies
service dependantssvcs -D networkn/an/aservice dependants
Service notifications

# change or add
svccfg

# verify or confirm 
svcprop

   
service logging, etc/var/svc/log
/var/svc/manifest
/lib/svc/method
/etc/svc/repository.db
/system/volatile/svc_nonpersist.db
n/a/var/adm/ras
/etc/syslog.conf 
/etc/rc.tcpip
service logging, etc
change service startupn/achkconfig --levels 2345 nfs onn/achange service startup
Add a new servicen/a

# Create your stop/start
# script in /etc/init.d

chkconfig --add <script>

  


Patching / Software

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
display installed patchesshowrev -p
patchadd -p
  swlist -l bundle 
swlist -l product
swlist -l patch
instfix -iadisplay installed patches
adding patchpatchadd
patchadd -M <dir> (multiple patches)
patch -p1 <patch>

zcat patch46.gz | patch -p1

Note: -p = # of path stripping
 


swcopy (install patch into depot)
swinstall (install patch from depot)

Note: the swagentd daemon must be running

instfix -kadding patch
removing patchpatchrmpatch -R -p1 <patch> swremoveinstallp -rremoving patch
display installed packagespkginfo (all packages)
pkginfo -l (single package)
pkgchk -l -p <file> (file belongs) 

# NEW IPS
pkg list (all packages)
pkg info (single package)
pkg search (find packages and files)
rpm -qa (all packages)
rpm -q (single package)
rpm -qf (file belongs)
rpm -qi <package> (very detailed)
dpkg -l
dpkg -S <search string> (search)
dpkg -S <filename> (file belongs) 
dpkg -s <package> (status)
dpkg -p <package> (detailed) 
swlist -l bundle <bundle> 
swlist -l product <product> 

## check a package
swlist -s <full_path/software>

lslpp -L all (all filesets)
lslpp -L <package> (single fileset) 
lslpp -w <file> (file belongs)
lslpp -ha (history of filesets)

rpm -qa (all packages)
rpm -q (single package)
rpm -qf (file belongs)
rpm -qi <package> (very detailed) 

oslevel -g (install packkages above os level)

whereis <filename> 
which_fileset <filename>

display installed packages
adding packagepkgadd

# NEW IPS
pkg install
pkg update 
rpm -Uhv (updates/installs if not already)
rpm -ihv (install)
dpkg -i <package>swinstall
swinstall -s <full_path/software>

installp -a
installp -c (cleanup after failed install)

rpm -i

geninstall (generic installer: installp, RPM, etc)

adding package
removing packages

pkgrm

# NEW IPS
pkg uninstall <package>

rpm -e <package>dpkg -r <package> (do not remove config files)
dpkg -P <package> (remove config files)
swremove

installp -u (commited packages) 
installp -r (applied packages)

rpm -e <package>

geninstall -u <package>

removing packages
verify package

pkginfo -l
pkginfo -p

# NEW IPS
pkg publisher 
pkg verify <package>

rpm -V <package>n/aswverity <fileset> (see /var/adm/sw/swagent.log)lppchk -v 

rpm -V <package>
verify package
List files in packagepkgchk -l <package> | grep -i pathname 

# NEW IPS
pkg contents <package>
rpm -ql <package>dpkg -L <package> (list files)swlist -l file <product>

lslpp -f <fileset>

rpm -ql <package>

List files in package
Other package commands# NEW IPS
pkg history
pkg purge-history
pkg freeze
pkg unfreeze 
pkg fix
pkg refresh
pkg publisher 
     
Package directory/var/sadm/var/lib/rpm/var/lib/dpkg/info/var/adm/sw

/usr/lpp

/var/lib/rpm

Package directory
List libraries required for binary programldd <file>ldd <file>ldd <file>chatr <file>ldd <file>List libraries required for binary program

Accounts

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
display userscat /etc/passwd

logins -x [-p]
cat /etc/passwd
system-config-users (GUI)
cat /etc/passwdcat /etc/passwd
logins -x
cat /etc/passwd

lsuser -f ALL   (detailed)
display users
create a user

useradd

# user defaults 
/usr/sadm/defadduser

useradd
system-config-users (GUI)
useradduseradd
sam
mkuser
useradd
create a user
remove a useruserdeluserdel
system-config-users (GUI)
userdeluserdel
sam
rmuser
userdel
remove a user
modify a userusermodusermod
system-config-users (GUI)
usermodusermod
sam
chuser -a
usermod 
passwd -f
passwd -s
chfn <username>
chfn <username><shell>
modify a user
change user passwordpasswdpasswdpasswdpasswdpasswd
pwdadm
pwdck -t ALL
change user password
create a groupgroupaddgroupaddgroupaddgroupaddmkgroup <group name>create a group
remove a groupgroupdelgroupdelgroupdelgroupdelrmgroup <group name>remove a group
modify a goupgroupmodgroupmodgroupmodgroupmodchgroup <attribute><group name>modify a goup
password files/etc/passwd
/etc/shadow
/etc/passwd
/etc/shadow
/etc/passwd
/etc/shadow
/etc/passwd
/tcb/files/auth/r/root (trusted system)
/etc/security/passwdpassword files
useful user commandsid -a
whoami
who
w
finger
logins -p
id -a
whoami
who
w
finger
id -a
whoami
who
w
finger
id
whoami
who
w
uptime (displays # of users logged in)
finger
id
whoami
who
w
uptime (displays # of users logged in)
finger 

# License information 
lslicense
chlicense

# Maximum number of processes for a user 
lsattr -D -l sys0 -a maxuproc
chdev -l sys0 -a maxuproc=<number>
useful user commands
useful group commandsgroups
setpgrp
newgrp
groupsgroupsgroups
setprivgrp
groups
setgroups
lsgroup ALL
useful group commands
Password Policy/etc/security/policy.conf
/etc/default/passwd
/etc/login.defs    
Password Agingpasswdchage -l <user>
chage <options> <user>
    

NFS

Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
NFS Daemonsserver: mountd, nfsd
client: statd, lockd
server: rpc.mountd,nfsd
client: rpc.statd, lockd

server: rpc.mountd,nfsd
client: rpc.statd, lockd

server: rpc.mountd, nfsd
client: rpc.statd, lockd

server: rpc.mountd, nfsd
client: rpc.statd, rpc.lockd

NFS Daemons
NFS files/etc/dfs/dfstab
/etc/dfs/sharetab
/etc/rmtab
/etc/exports
/var/lib/nfs/etab
/var/lib/nfs/xtab
/etc/exports
/var/lib/nfs/etab
/var/lib/nfs/xtab
/etc/exports
/etc/xtab
/etc/exports
/etc/xtab
NFS files
List nfs clients that have a remote mount/etc/rmtab/var/lib/nfs/rmtab/var/lib/nfs/rmtab/etc/rmtab/etc/xtabList nfs clients that have a remote mount
display nfs sharesdfshares
showmount -e localhost
showmount -e localhostshowmount -e localhostshowmount -e localhostexportfs
showmount -e localhost
display nfs shares
create nfs share/etc/dfs/dfstab (edit and add share)
share <path> 

## dfstab example 
share -F nfs -d "jumpstart" /export/jumpstart
redhat-config-nfs (GUI)

/etc/exports (edit and add share)
/sbin/service nfs reload

## /etc/exports example
/export *(rw,fsid=0,insecure,no_root_squash,sync)
/etc/exports (edit and add share, see below example)
exportfs -rav (export the shares) 

/etc/init.d/portmap restart
/etc/init.d/nfs-kernel-server restart

## /etc/exports example
/export *(rw,fsid=0,insecure,no_root_squash,sync)

/etc/rc.config.d/nfsconf (edit)
/etc/exports (edit and add share)
exportfs -a

mknfsexp -d <directory>
mknfsmnt

shareall
create nfs share
uncreate nfs shareunshare <path>
/etc/dfs/dfstab (edit and remove share) 
/etc/exports (edit and remove share)
/sbin/service nfs reload
/etc/exports (edit and remove share)
exportfs -rav (export the shares) 
/etc/rc.config.d/nfsconf (edit)
exportfs -au (unshare all)
exportfs -u /home/vallep 
/etc/exports (edit and remove share)
rmnfsexp  -d <directory> (unshares and removes from file) 

exportfs -u <filesystem> 
unshareall

uncreate nfs share
start/change nfs daemons

/etc/init.d/nfs.server start 
/etc/init.d/nfs.client start

svcadm enable nfs/server
svcadm disable nfs/server

/sbin/service nfs start/etc/init.d/portmap start
/etc/init.d/nfs-kernel-server start
/sbin/init.d/nfs.core start
/sbin/init.d/nfs.server start
/sbin/init.d/nfs.client start
mknfs
chnfs 

startsrc -s nfsd
startsrc -s rpc.mountd
start/change nfs daemons
stop nfs daemons/etc/init.d/nfs.server stop
/etc/init.d/nfs.client stop
/sbin/service nfs stop/etc/init.d/portmap stop
/etc/init.d/nfs-kernel-server stop
/sbin/init.d/nfs.client stop
/sbin/init.d/nfs.server stop 
/sbin/init.d/nfs.core stop
rmnfs

stopsrc -s nfsd
stopsrc -s rpc.mountd
stop nfs daemons
nfs statusps -ef|grep < nfs daemons>/sbin/service nfs status/etc/init.d/nfs-kernel-server statusps -ef | grep <nfs daemons>lssrc -a |grep -i nfsnfs status
nfs reloadshareall/sbin/service nfs reloadexportfs -rav (export the shares)exportfs -aexportfs -avnfs reload
nfs performanacenfsstatnfsstatnfsstatnfsstatnfsstatnfs performanace
nfs Optionsn/acat /var/lib/nfs/etabcat /var/lib/nfs/etabn/anfso -a
nfso -o <option>=<value>

exportfs (display options)
nfs Options
solaris/redhat mount problems (nfs v3 to v4)## Make sure you use NFS version 3 
mount -F nfs -o vers=3 <mount> <mountpoint>
n/an/an/an/asolaris/redhat mount problems (nfs v3 to v4)

NTP

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
Time daemons

xntpd

ntpd

ntpdxntpdxntpdTime daemons
ntp setup

# Solaris 8 
/etc/ntp.conf
/etc/ntp.server
/etc/ntp.client

/etc/rc2.d/xntpd [start|stop]

# Solaris 10
/etc/inet/ntp.server
/etc/inet/ntp.client

svcadm enable ntpd

/etc/ntp.conf (edit with ntp servers)
dateconfig (GUI)

chkconfig --list ntpd
chkconfig --level 2345 ntpd on 
/sbin/service ntpd start 

/etc/default/ntp
/etc/ntp.conf

/etc/init.d/ntp [start|stop|restart]

/etc/rc.config.d/netdaemons (set XNTPD to 1) 
/etc/ntp.conf

/etc/ntp.conf

startsrc -s xntpd
stopsrc -s xntpd

lslpp -L all|grep xntpd

ntp setup
ntp daemon options/lib/svc/method/xntp/etc/sysconfig/ntpd/etc/default/ntp/etc/rc.config.d/netdaemons

startsrc -s xntpd -a "-x"

/etc/rc.tcpip

ntp daemon options
NTP Trace commandsntpq -p
ntptrace
ntpq -p
ntptrace
ntpq -p
ntptrace
ntpq -p
ntpdate (set the date)
ntpq -p
ntptrace
ntpdate
NTP Trace commands

Log Files

Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
messages/var/adm/messages/var/log/messages/var/log/messages/var/adm/syslog/syslog.log/var/adm/ras
messages
syslog/var/log/syslog/var/log/syslog/var/log/syslog/var/adm/syslog/syslog.log/var/adm/ras
syslog
mail /var/log/mail/var/log/mail.*/var/adm/syslog/mail.log/usr/spool/mqueue/syslog
mail
cron/var/cron/log/var/log/cron/var/log/cron.log/var/adm/cron/log/var/adm/cron/log
cron
boot/var/adm/messages
dmesg
/var/log/boot
dmesg
/var/log/boot
dmesg
/var/adm/syslog/syslog.log
dmesg
/var/adm/ras

alog -o -t boot
alog -o -t console
alog -L  (list all the logs available)
boot
Error loggingloggerloggerloggerlogger

/usr/lib/errdemon -l (display attributes) 
/usr/lib/errdemon (start error logging) 
/usr/lib/errstop (stop error logging)

# use with above errorlog file 
errpt (summary errorlog report)
errpt -a (detailed errorlog report)
errpt -j <identifier> (single errorlog report)

errclear (clears errorlog)
errclear -d <class><days> (clears class errors)

errlogger "message upto 230 chars" 

Error logging

Security

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
Checking the passwd filepwckpwckpwckpwck
pwdck -t ALL 
usrck -t ALL
Checking the passwd file
checking the group filegrpckgrpckgrpckgrpckgrpckchecking the group file
console login (allow/deny)

# Solaris 10 (no reboot) 
/etc/default/login

# Solaris 11 (no reboot)
/etc/default/login
/etc/user_attr (see below)

rolemod -K type=normal root

# No reboot required 
/etc/securetty
# No reboot required 
/etc/securetty
# No reboot required 
/etc/securetty

Note: you may need to create this file if it does not exist
# No reboot required
/etc/security/user

chsec -f /etc/security/user -s root
console login (allow/deny)

Misc

 
Solaris
Red Hat
Ubuntu/Debian
HP
AIX
 
startup

eeprom

setenv boot-device

grub (GUI)
lilo (text based)
grub (GUI)setboot -p <primary path>
setboot -a <alternate path>

# autoboot sequnce 
setboot -b [on|off]
bootlist -m normal hdisk0 hdisk1startup
shutdown

shutdown -i5 -g0 -y (power down)
shutdown -i6 -g0 -y (reboot)
shutdown -i0 -g0 -y (OK prompt)

reboot -- -r (reboot/reconfigure)

touch /reconfigure

shutdown -h (halt)
shutdown -r (reboot)
shutdown -f (fast reboot no fsck)
shutdown -F (force fsck)

shutdown -h (halt)
shutdown -r (reboot)
shutdown -P (power off)

touch /forcefsck

# edit /etc/default/rcS change below so 
# you dont have to hang around 
FSCKFIX=yes

shutdown -h now (halt)
shutdown -r now(reboot)
shutdown -F (fast shutdown) 
shutdown -Fr (fast shutdown and reboot)
shutdown
Change run levelhalt
init
poweroff
reboot
shutdown
telinit
uadmin
halt
init
poweroff
reboot
shutdown
telinit
halt
init
poweroff
reboot
shutdown
telinit
init
reboot
shutdown
init
shutdown
reboot 
telinit
halt
Change run level
init status
0
1
2
3
4
5
6


0 - shutdown
1 - single user
2 - n/a
3 - Multi-user
4 - n/a
5 - power off
6 - reboot

 

# change default
vi /etc/inittab


0 - halt
1 - single user
2 - multiuser (no networking)
3 - multiuser (networking)
4 - unused
5 - GUI
6 - reboot

 

# change default
vi /etc/inittab


0 - halt
1 - single user
2 - multiuser (default)
3 - same as 2 
4 - same as 2 
5 - same as 2 
6 - reboot 



# change default - change all the telinit 
vi /etc/event.d/rc-default


0 - halt
1 - single users
2 - multiuser (networking)
3 - multiuser (networking, NFS, and CDE GUI) (default) 
4 - multiuser (netwrking, NFS, and VUE GUI)
5 - n/a
6 - n/a

 

# change default - change the initdefault line 
vi /etc/inittab


0 - reserved 
1 - reserved 
2 - multiuser mode with NFS 
3 - user defined 
4 - user defined 
5 - user defined 
6 - user defined 
7-9 - user defined

# change default - change the initdefault line 
vi /etc/inittab

init status
0
1
2
3
4
5
6
Startup options

boot <option>

# Options
-s single user
-a interactive
-x no device drivers (used in clustering) 
-r reconfigure devices
-m milestone

single  - use grub to edit kernel line 
emergency - use grub to edit kernel line 
linux rescue - use at the boot prompt

single: runlevel1, local fs mounted, no network
emergency: root fs read-only, no init files run 
rescue: use cd-rom/network, root mounted as /mnt/sysimage

single  - use grub to edit kernel line 
emergency - use grub to edit kernel line 
linux rescue - use at the boot prompt

single: runlevel1, local fs mounted, no network
emergency: root fs read-only, no init files run 
rescue: use cd-rom/network, root mounted as /mnt/sysimage

interact with IPL? Y

# single user 
ISL> hpux -is

# Logical volume maintanence mode 
ISL> hpux -lm

# No quroum check
ISL> hpux -lq

Based on 9114-275 workstation

1. switch off the machine

2. power on and enter the SMS menu

Note: to enter the SMS menu press numeric 1 after the word keyboard but before the word speaker 


Startup options
startup scripts/etc/init.d

/etc/rc0.d - /etc/rc6.d
/etc/init.d

/etc/rc0.d - /etc/rc6.d
/etc/init.d

/etc/rc0.d - /etc/rc6.d
/sbin/init.d
/etc/rc.config.d (startup config files) 

/sbin/rc0.d - /sbin/rc6.d

/etc/rc.d
/etc/rc.d/init.d

/etc/rc.d/rc2.d - rc9.d

/etc/rc.* (config files for auto-starting)

also uses the System Resource Controller

startup scripts
boot prompt commands

boot
printenv
setenv
banner
devalias
show-devs
show-pci-devs-all 
probe-scsi-all
probe-fcal-all
probe-pci 
watch-net-all
reset-all

F10 or F12F10 or F12interact with IPL? Y

Based on a 9114-275 workstation

1. switch off the machine

2. power on and enter the SMS menu

Note: to enter the SMS menu press numeric 1 after the word keyboard but before the word speaker

boot prompt commands
Boot process

Phases:

  • Boot PROM: displays system information, run POST, load bootblk, locate ufsboot
  • Boot Programs: bootblk loads and executes the ufsboot
  • Kernel Initialization: ufsboot loads and executes the core kernel, initializes core kernel data structures, loads other kernel modules based on the/etc/system file, starts/sbin/init program
  • init: starts other processes based on the /etc/inittab file

Boot sequence

  1. BIOS
  2. POST
  3. Master Boot Record (MBR) - point to the bootloader GRUB or LILO
  4. GRUB (stage 1) - point to GRUB stage 1_5
  5. GRUB (stage 1_5) - deals with specific filesystem types look at /boot/grub/*1_5 files
  6. GRUB (stage 2) – reads /etc/grub.conf and displays the grub menu, it specifies the kernel and the initrd files
  7. KERNEL - control given to the kernel
  8. INIT - reads /etc/inittab and runs /etc/rc.d/rc.sysinit script

Boot sequence

  1. BIOS
  2. POST
  3. Master Boot Record (MBR) - point to the bootloader GRUB or LILO
  4. GRUB (stage 1) - point to GRUB stage 1_5
  5. GRUB (stage 1_5) - deals with specific filesystem types look at /boot/grub/*1_5 files
  6. GRUB (stage 2) – reads /boot/grub/menu.lst and displays the grub menu, it specifies the kernel and the initrd files
  7. KERNEL - control given to the kernel
  8. INIT - runs the /etc/event.d/rc-default script

Phases:

  1. PDC - processor-dependent code; executes and performs self-tests
  2. ISL - initial system loader; loads the secondary system loader hpux
  3. HPUX - is the secondary system loader and loads the kernel /stand/vmunix, then hands over to the kernel
  4. KERNEL - swapper processes are started by the kernel then starts the init process
  5. INIT - reads /etc/inittab

Phases:

  • Read Only Storage (ROS): check the system board, perform POST, locate and load boot image, begin system initialization and execute phase 1 of the /etc/rc.boot script
  • Base Device Configuration: start configuration manager to configue base devices
  • System Boot: start init process phase 2, switch to hard-disk root filesystem, start other processes defined by /etc/inittab and execute phase 3 of the /etc/rc.boot script
Boot process
Boot Environments (BE)bootadm list-archive
bootadm update-archive
bootadm list-menu 
bootadm set-menu <option>

beadm create
beadm rename
beadm activate
beadm list
beadm destroy
     
determine the run levelwho -rrunlevel
who -r
runlevel
who -r
who -rwho -rdetermine the run level
obtain default run levelcat /etc/inittabcat /etc/inittab/etc/event.d/rc-default/etc/inittab/etc/inittabobtain default run level
list localelocale -alocale -alocale -alocale -alocale -alist locale
start xwindowsn/astartx (shorthand of below)
initx (lots of parms)
 n/an/astart xwindows
initialize systemsys-unconfig  set_parms [initial|hostname|ip_address|timezone]

Note: set_parms is in /sbin
install_assistinitialize system
Timezone/etc/TIMEZONE
/etc/default/init
/etc/sysconfig/clock
/usr/share/zoneinfo/zone.tab
/etc/timezone
/usr/share/zoneinfo/zone.tab
/etc/TIMEZONE/etc/environment
/etc/profile
Timezone


728x90
반응형

+ Recent posts