Determining how long device has been in defined state


 
Thread Tools Search this Thread
Operating Systems AIX Determining how long device has been in defined state
# 1  
Old 02-04-2013
Determining how long device has been in defined state

All,

Hoping you can help. I'm wondering how I can determine how long a device (network interface) has been in a defined state. Know there's a way, just can't figure it out.

Thanks in advance!
# 2  
Old 02-04-2013
Afaik something like that is not being logged right out of the box. You could check the ODM, if there is any kind of timestamp somewhere associated with the appropriate interface (have no AIX to check at the moment), but I quite doubt that. I also doubt it is written to the Error Report, but you can try out that very easy. Error Report is bound to a buffer size and it`s entries will be overwritten, if too many messages go in there.

If you have Auditing (Accounting and Auditing on AIX 5L) set up you could be lucky to find some traces of any shell input. If not, you could set this up if things like this are in your interesst.

You could also think about to use something to track config changes like SPM.
There was also an AIX native tool, but I do not remember itīs name. Xray was using it - I will drop him a PM, to help me recall itīs name Smilie

If the user had to use sudo to issue the command, you might be lucky with the sudo logs.

If it was done via smitty, check smitty.log.
# 3  
Old 02-04-2013
You could use alog to check the boot log file but on most systems I see they wrap at a couple of boots, or less, so it may be lost.

Just like the errlog file these are way too small by default.

The errlog is by default 1MB of disk space on a system with 4, 16, 64 GB ram, this is silly, turn it up people if you want to have any idea of what happened!

I've seen systems fill the errlog in less than a minute!
# 4  
Old 02-05-2013
Thanks for the updates... appreciated. One of the SA's who supports my app has advised me that a few network interfaces went into defined state over a year ago. I'm not suggesting something nefarious is going on, I would simply like to know how he determined that.
# 5  
Old 02-05-2013
Um, did you think of asking them?
Please post back if it is anything other than "because I noticed it in the lsdev output" ;0)
# 6  
Old 02-11-2013
Quote:
Originally Posted by jwholey
Thanks for the updates... appreciated. One of the SA's who supports my app has advised me that a few network interfaces went into defined state over a year ago. I'm not suggesting something nefarious is going on, I would simply like to know how he determined that.
Basically, you should also ask - went into Defined state from what.

FYI (although you may know this already) - Defined means, simply, that there is an entry in the CuDv (Customized Device) ODM file. Available means there is "also" a system driver/kernel extension that is associated with the device.

An Available device can be made Defined by using the command
rmdev -l devName
And made available using the command
mkdev -l devName

AND: this needs to all be happening via the ODM
Code:
root@x107:[/export/lpp/7102/installp/ppc]lsdev -C | grep et
en0        Available       Standard Ethernet Network Interface
ent0       Available       Virtual I/O Ethernet Adapter (l-lan)
et0        Defined         IEEE 802.3 Ethernet Network Interface

Code:
root@x107:[/export/lpp/7102/installp/ppc]ifconfig et0
et0: flags=1e080822,480<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST,GROUPRT,64BIT,CHECKSUM_OFFLOAD(ACTIVE),CHAIN>
root@x107:[/export/lpp/7102/installp/ppc]ifconfig et0 10.1.1.1 up
root@x107:[/export/lpp/7102/installp/ppc]ifconfig et0            
et0: flags=1e080863,480<UP,BROADCAST,NOTRAILERS,RUNNING,SIMPLEX,MULTICAST,GROUPRT,64BIT,CHECKSUM_OFFLOAD(ACTIVE),CHAIN>
        inet 10.1.1.1 netmask 0xff000000 broadcast 10.255.255.255

Code:
root@x107:[/export/lpp/7102/installp/ppc]lsdev -C | grep et0
et0        Defined         IEEE 802.3 Ethernet Network Interface
inet0      Available       Internet Network Extension

Code:
root@x107:[/export/lpp/7102/installp/ppc]chdev -a netaddr=10.2.2.2 -a state=up -l et0
et0 changed

Code:
root@x107:[/export/lpp/7102/installp/ppc]lsdev -C | grep et0                         
et0        Available       IEEE 802.3 Ethernet Network Interface
inet0      Available       Internet Network Extension

Code:
root@x107:[/export/lpp/7102/installp/ppc]ifconfig et0
et0: flags=1e080863,480<UP,BROADCAST,NOTRAILERS,RUNNING,SIMPLEX,MULTICAST,GROUPRT,64BIT,CHECKSUM_OFFLOAD(ACTIVE),CHAIN>
        inet 10.2.2.2 netmask 0xff000000 broadcast 10.255.255.255

Code:
root@x107:[/export/lpp/7102/installp/ppc]rmdev -l et0
et0 Defined
root@x107:[/export/lpp/7102/installp/ppc]ifconfig et0
et0: flags=1e080822,480<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST,GROUPRT,64BIT,CHECKSUM_OFFLOAD(ACTIVE),CHAIN>
root@x107:[/export/lpp/7102/installp/ppc]lsdev -C | grep et0
et0        Defined         IEEE 802.3 Ethernet Network Interface

Code:
root@x107:[/export/lpp/7102/installp/ppc]mkdev -l et0
et0 Available
root@x107:[/export/lpp/7102/installp/ppc]lsdev -C | grep et0
et0        Available       IEEE 802.3 Ethernet Network Interface

Code:
root@x107:[/export/lpp/7102/installp/ppc]chdev -l et0 -a state=down
et0 changed
root@x107:[/export/lpp/7102/installp/ppc]lsdev -C | grep et0       
et0        Stopped         IEEE 802.3 Ethernet Network Interface
inet0      Available       Internet Network Extension

In short, what I hope to point out - defined is a particular - and often NORMAL state for devices listed by lsdev. Especially if the device is being managed "manually" rather than via ODM (aka cfgmgr).

I hope this clarifies (helps) with understanding device states on AIX. Smilie
Login or Register to Ask a Question

Previous Thread | Next Thread

5 More Discussions You Might Find Interesting

1. HP-UX

Failed to open tape device /dev/rmt/0mn:Device busy (errno = 16)

Hi, Unable to make tape backup, please help. /opt/ignite/bin/make_tape_recovery -a /dev/rmt/?mn -I -v -m tar -x inc_entire=vg00 * Creating local directories for configuration files and archive. ======= 04/25/16 16:28:08 IST Started /opt/ignite/bin/make_tape_recovery. (Mon... (4 Replies)
Discussion started by: anuragr
4 Replies

2. AIX

Open firmware state to running state

Hi Admins, I am having a whole system lpar in open firmware state on HMC. How can I bring it to running state ? Let me know. Thanks. (2 Replies)
Discussion started by: snchaudhari2
2 Replies

3. Red Hat

Unable To Activate Ethernet Network Device in RHEL 5.5 - e100 device eth0 does not seem to be presen

Hi All, Could anyone please help to resolve the below problem. I installed RHEL5.5 in my desktop.But when i try to activate the ethernet connection then it gives me the error. I spent 2 days for the above and go through with several suggestion found by googling. But no luck. ... (0 Replies)
Discussion started by: Tanmoy
0 Replies

4. AIX

Device Available / Define state

Hi, I would like to know wheather it is possible to make device in availabe state? if for same reason os is not able to make it in available state. and it is in define state. (2 Replies)
Discussion started by: manoj.solaris
2 Replies

5. UNIX for Dummies Questions & Answers

Hitting with custom port in CLOSE_WAIT state for long time in solaris 10

Hi, Occasionally I am getting the port state in CLOSE_WAIT for long time in the solaris server. I am not sure is it application problem or not. Because we are using port 9009 for Tomcat process in our web application, some time when I start the application, the port 9009 is in CLOSE_WAIT... (0 Replies)
Discussion started by: mgmk.84
0 Replies
Login or Register to Ask a Question