1752565 Members
5740 Online
108788 Solutions
New Discussion юеВ

pty access mode error

 
SOLVED
Go to solution
Lai Siew Yuen
Frequent Advisor

pty access mode error

Hi,
I have accidentally issued a 'chmod -R 755 *' from the root directory of a HPUX version 11 server. Although I tried to change back some of the system files permission, I'm not sure if the revert is clean. For now I encountered an error in running the following command - 'script /tmp/test.txt', and the error is as follow:

"Script started, file is /tmp/test.txt
could not set pty ownership and access mode
Script done due to signal 15, file is
/tmp/test.txt
could not reset pty ownership and access mode"

May I know how should I reverse the change in a clean manner and how to overcome the above error?

Appreciate your kind guidance and thanks in advance.
4 REPLIES 4
Joelmel Roche
Valued Contributor
Solution

Re: pty access mode error

Hi,

Verify permission and ownership on /usr/bin/script and /usr/lbin/protect_pty are correct. They should be:

$ ls -l /usr/bin/script /usr/lbin/protect_pty
-r-xr-xr-x 1 bin bin ... /usr/bin/script
-r-sr-xr-x 1 root bin ... /usr/lbin/protect_pty


If permission or ownership is incorrect, then it should be fixed by executing as root:

# chown bin:bin /usr/bin/script
# chmod 555 /usr/bin/script

# chown root:bin /usr/lbin/protect_pty
# chmod 4555 /usr/lbin/protect_pty

tkc
Esteemed Contributor

Re: pty access mode error

hi, try recover the files from your backup into a temporary directory. from there, you can see the actual permission for all files.
Peter Nikitka
Honored Contributor

Re: pty access mode error

Hi,

I would really consider restoring an ignite backup - this is the fastest and most secure variant.
To check/set the mode of files created by 'swinstall', look at the man page of 'swverify' for a use of the options
-x check_permissions=true
-x fix=true

mfG Peter
The Universe is a pretty big place, it's bigger than anything anyone has ever dreamed of before. So if it's just us, seems like an awful waste of space, right? Jodie Foster in "Contact"
Lai Siew Yuen
Frequent Advisor

Re: pty access mode error

Hi all,
Thank you all for your guidance. The script problem is resolved now. Guess I'll have to set back the permission manually by comparing with another system as I do not have an ignite backup done on this server.
Thanks again and have a good day.