免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
12下一页
最近访问板块 发新帖
查看: 7928 | 回复: 11
打印 上一主题 下一主题

[Solaris]在Solaris中查看日志的方法 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2004-01-04 12:42 |只看该作者 |倒序浏览
近段时间,Solaris机器经常自动关机!手动启动正常!
请问:怎么查看操作日志和错误日志!
我查看过/var/adm/messages没有发现错误信息,可否告知重要错误的特征提示!或还有什么其他的地方可以查看相应的信息!
环境是Oracle 9i服务器,Oracle日志文件也没有记录什么错误信息!
谢!

论坛徽章:
0
2 [报告]
发表于 2004-01-04 21:25 |只看该作者
1.Check your Solaris power managerment strategy, if it has set to be energy-saving mode and auto power-off after half an hour(defaultly) of being untouched. You can use a GUI tools to check this. Login as superuser such as root,
#/usr/openwin/bin/dtpower
Then, check the strateby set and revised it if not properly.
(p.s.: In some circumstance, dtpower may not work. The power management strategy may not change. It\'s really confusing, I have no idea about this... Try sys-uncongfig, a bit rude...)

2.As you have stated, check /var/adm/message. System log info is mainly record there. \'Error\' and \'WARNING\' is the line you should pay attention to.

3.Check if some cron job runs to power off your machine.Defaultly,cron job log its information at /var/cron/log
Check it with #crontab -l
If you want to see currently runing cron job, contrast the result of \"ps -elf\" and \"crontab -l\"

As for you, I think it mainly because of circumstance 1.
GOOD LUCK!

论坛徽章:
0
3 [报告]
发表于 2004-01-05 10:40 |只看该作者
谢谢bloomit每次给予的回答!
我按照你的步骤进行了检查。
1,下面是我的dtpower文件,没有做更改,你的意思是要我注释掉他么?
#! /bin/ksh
#  (c) 1998-1999  Sun Microsystems, Inc.
#  @(#)dtpower.ksh      1.3 99/10/05 SMI
# Process arguments
while [[ $1 = -* ]]; do
        case $1 in
               -display )
                        shift
                        DISPLAY=$1
                        export DISPLAY
                        ;;
                -e )
                        EXPANDED=\"-e\"
                        ;;
                -res_cmd )
                        shift
                        RESTART=\"-res_cmd $1\"
                        ;;
                -geometry )
                        shift
                        GEOMETRY=\"-geometry $1\"
                        ;;
                * )
                        print \"Unexpected argument: $1\"
        esac
        shift
done
# Save the current directory.
current_dir=`pwd`
# Check if java exists in the user\'s environment
if [ -a /usr/java ]; then
        JAVA_HOME=/usr/java
fi
# Change directory to location of packages.
cd /usr/dt/appconfig/dtpower
# Set the LD_LIBRARY_PATH
LD_LIBRARY_PATH=`pwd`/lib:/usr/dt/lib{LD_LIBRARY_PATH}
# Set the class path to include each and every jar file of the application
CLASSPATH=`pwd`
cd classes
CLASSPATH=`pwd`{CLASSPATH}
jarfiles=`/bin/ls *.jar`
for i in ${jarfiles}; do
        CLASSPATH=`pwd`/${i}{CLASSPATH}
done
CLASSPATH=${CLASSPATH}:/usr/dt/classes/jhall.jar
CLASSPATH=${CLASSPATH}:/usr/dt/classes/xservices.jar
export LD_LIBRARY_PATH
# Get the java version.
tmp_file=/tmp/dtpower.version_test`echo $$`
${JAVA_HOME}/bin/java -version 2> $tmp_file
java_ver=`awk -F\\\" \'{ print $2 }\' $tmp_file`
# Get the major.minor.subminor java version numbers.
major=`awk -F\\\" \'{ print $2 }\' $tmp_file | awk -F\\. \'{ print $1 }\' `
minor=`awk -F\\\" \'{ print $2 }\' $tmp_file | awk -F\\. \'{ print $2 }\' `
subminor=`awk -F\\\" \'{ print $2 }\' $tmp_file | awk -F\\. \'{ print $3 }\' `

2,/var/adm/message存在下面的错误,在宕机后,屏幕显示的也是这个错误!(最后的错误提示)
Dec 30 08:15:41 rmss2         glm1 supports power management.
Dec 30 08:15:41 rmss2 scsi: [ID 365881 kern.info] /pci@8,700000/scsi@6,1 (glm1):
Dec 30 08:15:41 rmss2         Rev. 7 Symbios 53c876 found.
Dec 30 08:15:41 rmss2 pcisch: [ID 370704 kern.info] PCI-device: scsi@6,1, glm1
Dec 30 08:15:41 rmss2 genunix: [ID 936769 kern.info] glm1 is /pci@8,700000/scsi@6,1
Dec 30 08:15:41 rmss2 ebus: [ID 521012 kern.info] se0 at ebus0: offset 1,400000
Dec 30 08:15:41 rmss2 genunix: [ID 936769 kern.info] se0 is /pci@8,700000/ebus@5/serial@1,400000
Dec 30 08:15:43 rmss2 scsi: [ID 193665 kern.info] sd6 at glm0: target 6 lun 0
Dec 30 08:15:43 rmss2 genunix: [ID 936769 kern.info] sd6 is /pci@8,700000/scsi@6/sd@6,0
Dec 30 08:15:45 rmss2 pseudo: [ID 129642 kern.info] pseudo-device: pm0
Dec 30 08:15:45 rmss2 genunix: [ID 936769 kern.info] pm0 is /pseudo/pm@0
Dec 30 08:36:40 rmss2 /usr/dt/bin/ttsession[407]: [ID 504981 daemon.error] 子进程(436)推出,由于信号1
Dec 30 08:36:56 rmss2 picld[60]: [ID 339875 daemon.error] Keyswitch position changed to LOCKED
Dec 30 08:59:37 rmss2 /usr/dt/bin/ttsession[614]: [ID 504981 daemon.error]子进程(804)推出,由于信号1
Dec 30 10:06:16 rmss2 /usr/dt/bin/ttsession[931]: [ID 504981 daemon.error] 子进程(953)推出,由于信号1
Dec 30 12:25:00 rmss2 /usr/dt/bin/ttsession[1348]: [ID 504981 daemon.error] 子进程(1377)推出,由于信号1
这个session错误,我该再怎么样跟踪下去呢?

3、corn应该没有带来错误可能。

论坛徽章:
0
4 [报告]
发表于 2004-01-05 13:01 |只看该作者
1. I mean that you should run this script as root.
#/usr/openwin/bin/dtpower
then a java application GUI appears...

2.It seems that you have met a CDE problem, for error
/usr/dt/bin/ttsession[????]: child (????) exited due to signal 1
is mainly caused by CDE or Openwin problems.

I can not get more info of [B]your Solaris version[/B]. It seems that you are using a SUN work station of a former brand. So I guess that your Solaris is about SunOS 5.6, 5.7

Tell me more info about your  [B]your Solaris version[/B]...

论坛徽章:
0
5 [报告]
发表于 2004-01-05 13:39 |只看该作者
SunOS Release 5.9 Version Generic_112233-06 64-bit

论坛徽章:
0
6 [报告]
发表于 2004-01-05 19:01 |只看该作者
/usr/dt/bin/ttsession[????]: child (????) exited due to signal 1

Formly I met this problem on Solaris 2.6 platform, and when Recommended Patch installed, this error is solved.

I doubt whether Solaris 9 also has this problem. I suggest you to install Recommended Patch for Solaris 9.

Otherwise, this problem is mainly cause by other Application software installed on your OS, perhaps not Oracle... I have no idea about this

论坛徽章:
0
7 [报告]
发表于 2004-01-06 08:02 |只看该作者
哦,还是谢谢了!
在/var/adm/message中,存在
Dec 30 08:15:08 rmss2 picld[60]: [ID 526839 daemon.error] do_sysboard_init() failed
的错误不知道是否可以有帮助!

论坛徽章:
0
8 [报告]
发表于 2009-05-25 16:53 |只看该作者
用xmanager上去还不能执行dtpower
一定要去主机上执行

论坛徽章:
0
9 [报告]
发表于 2009-06-10 15:37 |只看该作者
很需要,谢谢楼主发资料

论坛徽章:
0
10 [报告]
发表于 2009-07-20 13:23 |只看该作者
good question, learning
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP