Operating System - HP-UX
1752794 Members
6474 Online
108789 Solutions
New Discussion юеВ

Kernel tune - max_async_ports

 
SOLVED
Go to solution
Martha Mueller
Super Advisor

Kernel tune - max_async_ports

I wonder if anyone knows a way to determine where to set this value. There has been a lot of good information about how to determine a good starting value, but I would like to know how many are actually in use at any one time so that I can decide whether to increase or decrease this value. Our current value was increased dramatically from the default of 50 to 2000 in an attempt to solve a resource crisis ( cpu usage staying close to 100% ). We fixed our problem by re-writing some querys, and want to reduce the value of max_async_ports. The increase in this parameter increased the size of the kernel by several megabytes. But, I am not sure that the default value of 50 is high enough. I need some way to measure this usage.
10 REPLIES 10
Sanjay_6
Honored Contributor

Re: Kernel tune - max_async_ports

Hi Martha,

max_async_ports is a kernel parameter. Here is the detail on the same,

http://docs.hp.com//hpux/onlinedocs/os/KCparam.MaxAsyncPorts.html

Here is the detail on all the kernel parameters.

http://docs.hp.com//hpux/onlinedocs/os/KCparams.OverviewAll.html

Hope this helps.

Regds
S.K. Chan
Honored Contributor

Re: Kernel tune - max_async_ports

Well, max_async_ports number represent the maximum number of processes that can open /dev/async concurrently. The default value, from what I see is 50. Some people increase this value when "nproc" got bumped up but I think it is not necessary because it would not affect the performance of the server. You can make the change using SAM->Kernel Config->Configurable Parameters.


Martha Mueller
Super Advisor

Re: Kernel tune - max_async_ports

Thanks, but I am really looking for a way to measure what we are currently using, not the abstract paper on how to plan for the expected need.
Paula J Frazer-Campbell
Honored Contributor

Re: Kernel tune - max_async_ports

HI Martha

The max_async_ports parameter limits the number of
processes that can open /dev/async concurrently.
As a result, the maximum is nproc, which is the
limit on the number of processes that can run on
your system at any given time.

There is no performance issue associated with
increasing this parameter.

The default is as you know 50 which on all my servers is fine _(universe) I an not sure about other databases

I would change it back to its default value - 50. Unless your database requires something different.

Paula
If you can spell SysAdmin then you is one - anon
Martha Mueller
Super Advisor

Re: Kernel tune - max_async_ports

Thanks, Paula. That's what I am trying to determine - whether the default of 50 would be fine for my database or whether it needs to be higher. I feel certain that 2000 is too high, but I would like to be able to determine through some measurement rather than just try a value. But, that might be all that I can do, there may not be any method to measure.
Paula J Frazer-Campbell
Honored Contributor

Re: Kernel tune - max_async_ports

Martha

If you are running Oracale have a look at this.

If not what are you running on your server.

Paula
If you can spell SysAdmin then you is one - anon
Paula J Frazer-Campbell
Honored Contributor
Solution

Re: Kernel tune - max_async_ports

Hi again

This might also help:-

2.0 Configuring asynchronous i/o
================================
aio requires configuration of both Oracle and HP-UX

2.1 HP-UX Configuration
-----------------------
a. create the /dev/async character device
% /sbin/mknod /dev/async c 101 0x0
% chown oracle:dba /dev/async
% chmod 660 /dev/async

b. configure the async driver in the kernel
Using SAM
-> Kernel Configuration
-> Drivers
-> the driver is called 'asyncdsk'
Generate new kernel
Reboot

c. set max_async_ports
Using SAM
-> Kernel Configuration
-> Configurable Parameters
-> max_async_ports

max_async_ports limits the maximum number of processes that can concurrently
use /dev/async. Set this parameter to the sum of
'processes' from init.ora + number of background processes

The background processes started at instance startup will open /dev/async
twice.

If max_async_ports is reached, subsequent processes will use synchronous i/o.

Paula
If you can spell SysAdmin then you is one - anon
Steven Sim Kok Leong
Honored Contributor

Re: Kernel tune - max_async_ports

Hi,

According to the Oracle 8.0.4 release notes (http://otn.oracle.co.kr/docs/oracle78/hp/server.804/A59370_01/relnote.htm),

================================================
max_async_ports parameter
max_async_ports is a configurable HP-UX kernel parameter that controls the maximum number of processes that can open /dev/async simultaneously.

During a benchmark, some shadow processes failed to open the async driver with error EBUSY. This error is caused when the async driver has already opened the number of processes specified by this parameter.

An error in opening the async driver can have performance implications on a machine with a large number of shadow processes or many parallel query slaves doing async I/O.

To avoid this error, customers should estimate the highest likely number of processes that /dev/async may run and set max_async_ports to this value.

Note that Oracle does not flag this error in the alert.log file or the trace files.
================================================

You can use Glance to identify the processes performing async I/O on your system. From there, you can perhaps give a more reliable estimate of the value you need to set max_async_ports to.

If you don't have Glance, you can use lsof to perform a check on the processes using /dev/async.

You can download lsof from one of the HP Porting and Archive Centre:

http://hpux.asknet.de/hppd/hpux/Sysadmin/lsof-4.55/

So, first try assign a huge number (eg. 2000), then perform an lsof to identify the number of processes using /dev/async (eg. lsof |grep /dev/async).

Hope this helps. Regards.

Steven Sim Kok Leong
Martha Mueller
Super Advisor

Re: Kernel tune - max_async_ports

Paula, I am running sybase. I wanted to assign 10 points to both Paula and Steven because both answers are helpful in my quest. I think I have a good plan. I wasn't sure that lsof would give me accurate information...I was just mentioning it as an example of a tool. But the rest of the information about startup and shadowing processes will keep me from setting this value too low.

Thanks for your insight.