Your SAS programs, embedded in web apps and elsewhere

STP and access rights, unix, wirting files

Accepted Solution Solved
Reply
Contributor
Posts: 71
Accepted Solution

STP and access rights, unix, wirting files

Dear SAS Experts,

We got a STP running daily. It created a dataset in SAS BASE library X.
I want to do the same with library Y. A different stored process, a different SAS BASE library.
The sassrv user has access to write in the library folder.
the error reads (translated from German):

ERROR: user does not have required access to file Y.P15_SEL.DATA.

Have we missed something? We cant figure out what rights are missing.


Accepted Solutions
Solution
‎12-01-2016 03:07 AM
Super User
Posts: 6,936

Re: STP and access rights, unix, wirting files

Files that are created through STPs running on the stored process server should all have sassrv as an owner.

If STPs are executed not on the STP server, but on workspace server instances, then they will be owned by the user whose credentials were used to start the workspace server.

Still the best bet is to go looking in the UNIX filesystem and check ownerships and permissions on the OS level.

And if tables are registered in SAS metadata, then the authorization tab there needs to be checked also.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers

View solution in original post


All Replies
Super User
Posts: 6,936

Re: STP and access rights, unix, wirting files

Log on to the UNIX server, and navigate to the file path of library Y. Do a ls -l p15_sel.sas7bdat there. You may find that the file is already there, but was created by a user other than sassrv. If that is the case, remove it or do a chown (which requires root permissions)

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Contributor
Posts: 71

Re: STP and access rights, unix, wirting files

Thanks! Will check that.
Contributor
Posts: 71

Re: STP and access rights, unix, wirting files

Hi Kurt,

it has been a while and I just had an idea. The STP that builds P15_SEL accesses a dataset that has been generated by a --different-. STP. Could it be that sassrv needs access to the source dataset that is created every morning anew?

 

Solution
‎12-01-2016 03:07 AM
Super User
Posts: 6,936

Re: STP and access rights, unix, wirting files

Files that are created through STPs running on the stored process server should all have sassrv as an owner.

If STPs are executed not on the STP server, but on workspace server instances, then they will be owned by the user whose credentials were used to start the workspace server.

Still the best bet is to go looking in the UNIX filesystem and check ownerships and permissions on the OS level.

And if tables are registered in SAS metadata, then the authorization tab there needs to be checked also.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Super User
Posts: 6,936

Re: STP and access rights, unix, wirting files

Which part of my answer put you on the right path for your solution?

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Contributor
Posts: 71

Re: STP and access rights, unix, wirting files

There was a file on the server that had the same name and sassrv was not the owner.
Our admin had ot look twice. The files where at different locations.

Super User
Posts: 6,936

Re: STP and access rights, unix, wirting files

As is often said: "Shit happens".

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
☑ This topic is SOLVED.

Need further help from the community? Please ask a new question.

Discussion stats
  • 7 replies
  • 388 views
  • 5 likes
  • 2 in conversation