Visit Our UNIX and Linux User Community


AIX reboots


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers AIX reboots
# 1  
Old 06-04-2014
Error AIX reboots

Hi Everyone, I'm trying to figure out how many times my LPAR has been bounced? Anybody know a command or a place I can look into. The "who -b" shows the last system boot and I couldn't find anything useful using the "last" command.
# 2  
Old 06-04-2014
You can have a look if you have root privilege at /var/adm/ras/bootlog for a start...
# 3  
Old 06-04-2014
How about trying the below
last | grep -i reboot

or if you want to know the shutdown too
last | egrep -i 'reboot|shutdown'

It will give you date, time and terminal.

To do the actual count you can use |wc -l at the end.

Last edited by ibmtech; 06-04-2014 at 01:39 PM.. Reason: Added another line
# 4  
Old 06-04-2014
ibmtech,

Looks like this might have done the trick Smilie, I did a grep for date...
Code:
# grep date bootlog | sort
The "date" command is now available:  Thu Feb  6 23:19:35 UTC 2014
The "date" command is now available:  Thu Feb  6 23:53:28 UTC 2014
The "date" command is now available:  Thu Jan 24 23:51:04 UTC 2013
The "date" command is now available:  Thu Jan 26 23:06:55 UTC 2012
The "date" command is now available:  Wed Apr  4 22:32:15 UTC 2012
The "date" command is now available:  Wed Aug 22 23:40:17 UTC 2012

Thanks,

zroz9

---------- Post updated at 12:49 PM ---------- Previous update was at 12:47 PM ----------

ibmtech,

I'm running 7.1, and as I mentioned the "last" command does not return back anything. Comes back empty.

Code:
[root@test] /
# last | grep -i reboot
[root@test] /
# last | egrep -i 'reboot|shutdown'
[root@test] /

Thanks,

zroz9

Last edited by Don Cragun; 06-06-2014 at 02:02 AM.. Reason: Add CODE tags.
# 5  
Old 06-04-2014
It really does not matter what OS version you are using for last command.

Tell me what is the time stamp on file
/var/adm/wtmp , I think someone overwrote the file.

Adding my own server
Code:
root@nim01:/tmp# oslevel -s ;last | grep -i reboot |head -2
7100-01-07-1316
reboot    ~                                   Dec 04 15:47
reboot    ~                                   Dec 04 14:55

# 6  
Old 06-05-2014
One wonders why you are interested, but going forwards you could add a small script to run at boot to write a message to a persistent file, perhaps just as simple as:-
Code:
date >> /etc/my_boot_log


Robin
# 7  
Old 06-05-2014
ibmtech,

Seems like the file is empty:

Code:
[root@test] /var/adm
# ll | grep wtmp
-rw-rw-r--    1 adm      adm            1296 Jun 05 17:02 wtmp
[root@test] /var/adm
# cat wtmp
openacct        SПэЪrootpts/0pts/0CfSРшюXX.XX.XX.XX[root@test] /var/adm
#


And again the cool command only return back the OS level.
Code:
oslevel -s ;last | grep -i reboot |head -2

Thanks,

zroz9

Last edited by Don Cragun; 06-06-2014 at 02:00 AM.. Reason: Add CODE tags.
 

Previous Thread | Next Thread
Test Your Knowledge in Computers #945
Difficulty: Medium
A Fraggle attack is a variation of the Smurf attack where an attacker sends a large amount of UDP traffic to ports 7 (Echo) and 19 (CHARGEN) to an IP broadcast address with the intended victim's spoofed source IP address.
True or False?

10 More Discussions You Might Find Interesting

1. HP-UX

Prevent crash dump when SG cluster node reboots

Hi Experts, I have configured HP-UX Service Guard cluster and it dumps crash every time i reboot a cluster node. Can anyone please help me to prevent these unnecessary crash dumps at the time of rebooting SG cluster node? Thanks in advance. Vaishey (2 Replies)
Discussion started by: Vaishey
2 Replies

2. Slackware

HD-Audio: ALSA settings not persistent across reboots.

Hi: The OS is Slackware 14.0. When, after 14.0 install I first ran alsamixer, I got an error message and it quit. After some googling, I created /etc/modprobe.d/alsa.conf with these lines: alias snd-card-0 snd_hda_intel alias sound-slot-0 snd_hda_intel options snd_hda_intel... (0 Replies)
Discussion started by: stf92
0 Replies

3. Solaris

Persistent ownership of raw disk during reboots

Hi, I'm in process of creating oracle RAC using Solaris 10 in VirtualBox. I want to know how can I change the ownership of device e.g /dev/rdsk/c0t3d0s0 and keep it persistent during rebbots. When I enter chown grid:install /dev/rdsk/c0t3d0s0 ls -l still shows root:root. Thanks ... (2 Replies)
Discussion started by: jia786
2 Replies

4. AIX

How to run a script automatically when AIX version 7 server reboots?

Am new to AIX please help me. I have AIX7 server. When ever the system reboots my script need to run automatically. This will help me to start my application automatically after the server reboot. Thanks, Prince Wells (9 Replies)
Discussion started by: prince1987
9 Replies

5. Ubuntu

Lucid AMD 64 install on USB HDD reboots frequently

Hi all, I am using Ubuntu lucid. It is installed on external USB HDD and I boot into it. Besides other issues, the most significant one is as follows.. I boot in and start working. Everything goes on fine. As soon as I move the HDD, change its position, etc, all icons tuns into a red... (1 Reply)
Discussion started by: morningSunshine
1 Replies

6. Solaris

solaris reboots as it start loading

hello, my problem is the one of the title , as I press enter on Solaris voice in the grub, my computer reboots , is there an option, a flag ,I can add to the Solaris voice , that allow me to see where is the problem ? something that avoid the computer reboot on error? I can't find a way to know... (7 Replies)
Discussion started by: freeware
7 Replies

7. Solaris

system always reboots

i have a sun 280R server , that reboots randomly . i have checked for hardware failures but none can be seen . here is the output of prtdiag -v System Configuration: Sun Microsystems sun4u Sun Fire 280R (2 X UltraSPARC-III +) System clock frequency: 150 MHz Memory size: 2048... (1 Reply)
Discussion started by: ppass
1 Replies

8. UNIX for Dummies Questions & Answers

HP-UX reboots? Time between them?

HP-UX reboots? Time between them? I have a ? concerning planned reboots of a HPUX 11.11 (RP7410 machine; 10GB RAM; Oracle 8; BaaN v4c4 ERP). My new boss seems to think that all machines (Wintel & UX) should run 24x7x365 and NEVER ever require a reboot. In the practical world we SysAdmins know... (3 Replies)
Discussion started by: bergerp
3 Replies

9. UNIX for Dummies Questions & Answers

server reboots

Hi all i am using sun solaris 2.8 un sunultra10 sparc server.It is our firewall server. with check point firewall running. but the server suddenly halted several times with the same error as follows....and then there was no option but to reboot. the error was panic /thread=0*6115d360... (2 Replies)
Discussion started by: Prafulla
2 Replies

10. UNIX for Dummies Questions & Answers

Sun solaris server auto reboots

Hi Guys, For the past month, our sun solaris server has rebooted itself 3 times. The sysadmin is saying that is not a sun issue and does not want to carry out any further research with sun about that. The db logfile does not show anything about any db issues at that time. I opened an oracle TAR... (3 Replies)
Discussion started by: mnjanje
3 Replies

Featured Tech Videos