TruCluster
cancel
Showing results for 
Search instead for 
Did you mean: 

Performance problem of setuid programs on a TruCluster

SureshVaidyanathan
Occasional Contributor

Performance problem of setuid programs on a TruCluster

Hello,

We have a 4 node cluster (identical configuration) running Tru64 V5.1B with patchkit 4, One node in the cluster contains the cluster root and other nodes have it mounted from this host. We have a setuid application owned by usera (non-root). The permission of this file is as follows:

r-s--s--x usera users ... .

We run this appln as root on the node which has the cluster root and the performance is approx. 1.5s real, 0.2s for sys and user. We run this appl as 'usera' or even userb (which has the same group) and the time is more or less identical.

When we run this appln on a different node (which has the cluster root mounted), the for 'root' and 'userb', the time is 3-10 times greater than the time it takes for 'usera'.

i.e For root, userb, it is 4.8s real, 0.3s for sys and user.

For usera it remains at 1.5s real, 0.2s sys and user.

When we remove the 's' bit, the performance for root user comes down to 1.5s real, 0.3s for sys and user.

The following info may be useful:
(a) usera, userb are NIS accounts and have their home directories mounted through NFS onto the cluster hosts.
(b) root account is local to each host.

I'd like to know, why does it behave in this manner and what needs to be done to get it corrected.

In case, you need more information, do let me know.

Thanks & Regards,
Suresh.
7 REPLIES
Ivan Ferreira
Honored Contributor

Re: Performance problem of setuid programs on a TruCluster

This may be because the CFS server for the file system where is the data is the node where the application runs faster. Performance could be increased when you remove the suid bit because will be executed as root and will have more priority.

To check which node is the CFS server for a particular file system use the cfsmgr command. To relocate the file system use:

cfsmgr -a SERVER=nodename /mount_point
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Ann Majeske
Honored Contributor

Re: Performance problem of setuid programs on a TruCluster

Is the cluster the NIS master server?
SureshVaidyanathan
Occasional Contributor

Re: Performance problem of setuid programs on a TruCluster

Thanks a lot to those replies. The requirement is that all the nodes in the cluster (except for the failover node) will have to run the same software with the same performance. The software product itself is installed and running on each individual nodes. Moving the cluster root to another node reduces the performance on that node.

No. NIS master is not in the cluster.
Orjan Petersson
Frequent Advisor

Re: Performance problem of setuid programs on a TruCluster

What is the performance for local (non-NIS) unprivileged users?
SureshVaidyanathan
Occasional Contributor

Re: Performance problem of setuid programs on a TruCluster

The performance of a non-NIS user is equally bad, with the 's' bit set. It is either same as root and userb or even worse (sometimes).
Hein van den Heuvel
Honored Contributor

Re: Performance problem of setuid programs on a TruCluster

When the euid and uid differ, several security features are turned on.
Notbaly LD_LIBRARY_PATH will be ignored, and I believe the class scheduler may behave differently. Could that explain diffenences?
The application is not crashing and generating core files is it? Again that could behave differently with setuid active.

Just guessing...

Hein.

SureshVaidyanathan
Occasional Contributor

Re: Performance problem of setuid programs on a TruCluster

Thanks for the reply. I'm wondering, if for a moment, we assume what you say is right, it must apply even on the node which has the cluster root present and the results on all the nodes must be the same.

However, what I'm seeing is that the behavior on the system with Cluster root (CFS root) locally mounted, the performance as any user is almost equal. However, on the nodes which has the Cluster root mounted from remote, the performance differs for different user under conditions as specified in the first problem report. I'm not sure of whether class scheduler would work differently depending on the node which has cluster root local or remote. I'd like the experts to help me figure this out.

Without proper tools, I'm not able to even find out, whether it is the initial loading that differs on different node (truss doesn't work on executable with 's' bit set and I'm not sure of trace and even if it does, it doesn't have the time prefix to see if there is a delay.

Yes, the application is not crashing and is working as expected, except for the performance factor.

Suresh.