group

user1 belong to group1
user2 belong to group2

I would like user1 to have access to user2 stuf. I’ve tried adding user1 to
the definition of group2 in /etc/group but to no avail. What have I miss?

By the way, during my investigation, I looked at utility newgrp but found
that it’s unusable in a pterm because it closes the shell and thus the pterm
:wink:

  • Mario

Mario Charest postmaster@127.0.0.1 wrote:

user1 belong to group1
user2 belong to group2

I would like user1 to have access to user2 stuf. I’ve tried adding user1 to
the definition of group2 in /etc/group but to no avail. What have I miss?

you are right on track.
since qnx4 doesn’t support supplement group, you can only be at one
group at a time. As user1, run:
newgroup group2 (or was it “newgrp group2”).
once you are done, you can switch back:
newgroup group1
goodluck.

Mario Charest postmaster@127.0.0.1 wrote:

Aas I mentioned I couldn`t find a way to use newgrp in pterm.

ah, photon. guess you need to file a bug report.
it works fine for me under X Window gui and text console.
maybe you could use xphoton/xterm if you insist on using GUI
and Photon.

“liug” <liug@mama.indstate.edu> wrote in message
news:b32r1l$f72$1@inn.qnx.com

Mario Charest postmaster@127.0.0.1 wrote:
user1 belong to group1
user2 belong to group2

I would like user1 to have access to user2 stuf. I’ve tried adding
user1 to
the definition of group2 in /etc/group but to no avail. What have I
miss?

you are right on track.
since qnx4 doesn’t support supplement group, you can only be at one
group at a time. As user1, run:
newgroup group2 (or was it “newgrp group2”).
once you are done, you can switch back:
newgroup group1

Aas I mentioned I couldn`t find a way to use newgrp in pterm.

goodluck.

Thanks

liug <liug@mama.indstate.edu> wrote:

Mario Charest postmaster@127.0.0.1 wrote:
Aas I mentioned I couldn`t find a way to use newgrp in pterm.

ah, photon. guess you need to file a bug report.
it works fine for me under X Window gui and text console.
maybe you could use xphoton/xterm if you insist on using GUI
and Photon.

Works for me in a pterm as well.

What version of QNX4? I’m testing with a relatively recent 4.25 and
Photon 1.14.

newgrp may do some login type processing – do you do anything interesting
or exciting in your /etc/default/profile, $HOME/.profile, or whatever file
is pointed to by $ENV after your $HOME/.profile has executed?

Hm…I just had a pterm go away…I did “newgrp blah” and blah was NOT
a valid group.

Try “whence newgrp” and you will probably find the result is “exec newgrp”,
which means the shell turns itself into “newgrp” and when newgrp fails, and
exits, the pterm window has no program running on its terminal, so it goes
away as well.

Try /bin/newgrp the_new_group for testing purposes… I’ll bet you’re getting
an error, but, of course, not being to see the error.

-David

QNX Training Services
http://www.qnx.com/support/training/
Please followup in this newsgroup if you have further questions.

David Gibbs <dagibbs@qnx.com> wrote:

Hm…I just had a pterm go away…I did “newgrp blah” and blah was NOT
a valid group.

Run your pterm with the -z option if you want more time to see the error
message…

Hm…I just had a pterm go away…I did “newgrp blah” and blah was NOT
a valid group.

yeah that was it there was a tpo in the /etc/group file ;_ Thanks


-David

QNX Training Services
http://www.qnx.com/support/training/
Please followup in this newsgroup if you have further questions.