- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: mesg: cannot change mode
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2012 08:42 PM
02-26-2012 08:42 PM
mesg: cannot change mode
Hi,
i facing strange issue with all users on multiple servers, where when i switch from root user to any other user as following
# su - testuser
i facing the below message
mesg: cannot change mode
mesg: cannot change mode
please your support.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2012 08:51 PM
02-26-2012 08:51 PM
Re: mesg: cannot change mode
and also when i login direct or by switch from root user to any normal user i don't see any thing under the home directory
but when i run more command as following
$ more .profile
i see the content of this file ????! although there is nothing
$ ls -l
total 0
$ pwd
/home/mousa
$
$
$
$ cd
$ ll
total 0
$ pwd
/home/mousa
$
$
$
$ more .profile
# @(#)B.11.31_LR
# Default user .profile file (/usr/bin/sh initialization).
# Set up the terminal:
if [ "$TERM" = "" ]
then
eval ` tset -s -Q -m ':?hp' `
else
eval ` tset -s -Q `
fi
stty erase "^H" kill "^U" intr "^C" eof "^D"
stty hupcl ixon ixoff
tabs
# NOTE: '.' is added to $PATH for compatibility reasons only. This
# default will be changed in a future release. If "." is not
# needed for compatibility it is better to omit this line.
# Please edit .profile according to your site requirements.
# Set up the search paths:
PATH=$PATH:.
# Set up the shell environment:
set -u
trap "echo 'logout'" 0
# Set up the shell variables:
EDITOR=vi
export EDITOR
umask 077
mesg n
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-27-2012 07:55 AM
02-27-2012 07:55 AM
Re: mesg: cannot change mode
In Unix, files with "." as the first character of the filename are normally hidden. You can see them when you add option "-a" to the ls command.
In HP-UX, the "-a" option for ls is on by default for root, but off for all other users. So root will see all files with just "ls -l", but other users will need "ls -la".
When you login, you are given the ownership to the TTY/PTY device of your session. You can know your tty device with the command "tty".
The "mesg" command tries to change the permissions of the TTY/PTY device: "mesg n" is equivalent to "chmod o-w $(tty)", and "mesg y" is equivalent to "chmod o+w $(tty)".
When you use "su" or similar to switch to another user, the TTY/PTY device stays owned by the original user. When you switch from regular user to root, this is not a problem because root can change anything anyway. But when you switch from root to regular user, or from one regular user to another, commands like "mesg" may cause errors. This is usually nothing more than a minor inconvenience.