SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
groups and permissions

 
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite View previous topic
View next topic
groups and permissions
Author Message
seanc217



Joined: 23 May 2007
Posts: 272

Post groups and permissions Reply with quote
Hi there I have a user let's say user_x.

He's a member of several groups on a linux box let's say:
dsadm dstage dropoff d3000 momentum

It appears the scheduler is only picking up the primary group and not all of the secondary groups when running the script.
When I run the following in my script...

groups > /home/srv_etl/file_scripts/d3_s1/groups.txt

I get the primary group dsadm only.
Is there a way to apply the secondary groups?

Thanks.
Mon Jan 07, 2008 12:12 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7969

Post Reply with quote
Sorry, I didn't get it.

Is the job setup to run with specific user credentials? If yes, it starts a new process and then changes the user (like su command), otherwise, the job runs with the same credentials and settings that are available to the user running the scheduler process.
Mon Jan 07, 2008 1:22 pm View user's profile Send private message
seanc217



Joined: 23 May 2007
Posts: 272

Post Reply with quote
The job is setup to run as a specific user.
In this case, the user is called srv_etl.

This user belongs to the following groups:

dsadm dstage dropoff d3000 momentum

However in my script when I put the following command in:

groups > /home/srv_etl/file_scripts/d3_s1/groups.txt

When I run the script I get an output file, but it just lists the primary group which is dsadm.

Any ideas why the secondary groups are not being applied?
It's causing my script to fail with a permission denied error when I try to access a file which the user srv_etl has rights to through the secondary groups.

The script works fine if I run it on the machine, but when I try to excute it through the scheduler it fails.


Thanks.
Mon Jan 07, 2008 1:36 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7969

Post Reply with quote
What about the user account running the scheduler. Is that account a member of dsadm group only?
Mon Jan 07, 2008 1:55 pm View user's profile Send private message
seanc217



Joined: 23 May 2007
Posts: 272

Post Reply with quote
The remote agent and all the scheduler instances master and angents are running as root.
Mon Jan 07, 2008 2:03 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7969

Post Reply with quote
So this is happening on an agent computer, right?

I believe this is the way switch-user is working on your agent system and nothing can be done in the agent or scheduler settings. Please check your system docs for the behavior description of the "su" command, what it says about the effective group. Consider changing group order for that particular user, so that the group you want is listed first.

BTW, I checked generic Linux documentation and it is not clear about su behavior. Looks like there are no generic rules well documented for this gray area and different systems may implement different behavior.
Mon Jan 07, 2008 2:21 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7969

Post Reply with quote
Minor clarification: by "listed first", I meant to say to set it as a primary group.
Mon Jan 07, 2008 2:29 pm View user's profile Send private message
seanc217



Joined: 23 May 2007
Posts: 272

Post Reply with quote
OK thanks again for pointing me in the right direction.

There's a command in Unix/Linux called sg.

Here's the synopsis:

NAME
sg - execute command with different group ID

SYNOPSIS
sg group command


IF I execute my commands within this command it seems to work OK.

Just an fyi for anyone else that is having the same issues.
Mon Jan 07, 2008 4:18 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7969

Post Reply with quote
Thanks for the update. Glad you found an acceptable solution.
Mon Jan 07, 2008 4:22 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.