Operating System - Linux
1829044 Members
2643 Online
109986 Solutions
New Discussion

Re: Screen erasure upon logout

 
SOLVED
Go to solution
Sanjiv Sharma_1
Honored Contributor

Screen erasure upon logout

For Linux we can achieve by inserting "clear" in /etc/skel/.bash_logout

How can we do this in HP-UX 11.11? Thanks in advance.
Everything is possible
3 REPLIES 3
Matti_Kurkela
Honored Contributor
Solution

Re: Screen erasure upon logout

The answer depends on which shell the user is using: sh, ksh, csh (*horror*) or something else. Your Linux solution is applicable to HP-UX too, if you install the bash shell to your system and make it available to the users.

Standard warning: *never* change the shell of the root user: in HP-UX, root's shell must always be /sbin/sh. That is a special shell that will work even when /usr is not mounted and/or system libraries are gone... like when you boot the system to single user mode. If you change root's shell in HP-UX, your system may become unbootable until the change is undone.

If we assume that your users use the HP-UX default shell, /usr/bin/sh, then you could insert the following to the user's .profile (and/or /etc/skel/.profile):

trap "clear" EXIT

MK
MK
Sanjiv Sharma_1
Honored Contributor

Re: Screen erasure upon logout

Yes. I am using the default shell and it works. Thank you.
Everything is possible
Sanjiv Sharma_1
Honored Contributor

Re: Screen erasure upon logout

Solution worked
Everything is possible