Operating System - HP-UX
1829149 Members
2178 Online
109986 Solutions
New Discussion

swinstall slow for users with _ in username

 
SOLVED
Go to solution
A. Clay Stephenson
Acclaimed Contributor

Re: swinstall slow for users with _ in username

Okay, I've found that tusc has problems running setuid programs when it detects stdout is redirected to a file. We need to outbushwhack it by this subterfuge:

tusc -T '' /usr/sbin/swlist | tee /var/tmp/trace.txt


Hopefully, you can examine the file to see the system call that is preceding all of your gettimeofday() calls. I cannot reproduce this condition so I suspect that it is a libC or swagentd patch issue.
If it ain't broke, I can fix that.
Gordon McKinnon
Advisor

Re: swinstall slow for users with _ in username

I get permission errors from tusc even when I don't redirect. I am going to try a script as root with a su x_y -c /usr/sbin/swlist ; tusc -fp -T '' `ps -ef | grep swlist | awk...`
A. Clay Stephenson
Acclaimed Contributor

Re: swinstall slow for users with _ in username

yes, I just realized it has nothing to do with redirected output; however, what you can do it set the setuid bit on the tusc command itself (e.g. chmod 4755 /usr/local/bin/tusc) temporarily and then run your swlist command under tusc as the bad user.
If it ain't broke, I can fix that.
Gordon McKinnon
Advisor

Re: swinstall slow for users with _ in username

My scripted version does not catch the process early enough.

I got a permission error even with the setuid bit set on tusc, which does not make a lot of sense to me.

I tusced the execution of swlist as root. I will start checking the system calls...