BookmarkSubscribeRSS Feed
larsc
Obsidian | Level 7

Hi everyone,

 

We are experiencing some issues in SAS 9.4 M7. We've recently migrated from Microsoft server 2012 R2 to 2019 and this is when the issues started.  


We have a SAS scheduled batch job which every now and then will raise the following error:

ERROR: User does not have appropriate authorization level for library WORK.

 

As mentioned, this only happens every now and then (e.g., job runs successfully 10 times and then fails on run 11). There is no apparent pattern in terms of when it'll fail. It fails both when running in batch and when it is run manually. 

 

We've tried to exclude the work library catalogue from Microsoft Defender. We've also checked that the user has appropriate credentials to access the folder. This did not resolve the issue.

10 REPLIES 10
Tom
Super User Tom
Super User

I would check that the method SAS is using to name the directory it creates for the WORK directory is insured of generating a unique name.

 

Sounds to me like there is conflict of two or more jobs trying to use the same directory for their WORK location.  So the first one makes it with permissions for user X and when the second job tries to use for user Y the access is denied.

 

Do you have multiple SAS hosts that are sharing the same work directory?

Or multiple instances of SAS.

Or multiple SAS application servers?

 

 

SASKiwi
PROC Star

Where in the batch job does that happen? Is it at invocation or later? If later is it always the same statement or step causing the error? Can you post the SAS log for that step, including errors and notes?

viswmmo
Fluorite | Level 6

Hi,

we are seeing same errors with authorization level to Work occasionally. Also sas m7 on Microsoft Server 2019.

Did something resolve this issue? 

 

 

 

 

SASKiwi
PROC Star

@viswmmo - The original poster never responded to our questions. If you want help with your issue then you would need to answer those questions.

AnushaS4
Fluorite | Level 6
Hi. Was this issue ever resolved
ballardw
Super User

@AnushaS4 wrote:
Hi. Was this issue ever resolved

Since neither of the people asking about this provided any details we have no idea. If you are having a similar behavior start your own thread and provide the information requested of the other posters.

liuk
Calcite | Level 5

Hi there!

Encountered a very similar issue on SAS 9.4 M7 server running on windows 2019 server. Attached please see the log. It seems to only happen when the programs were ran by the batch jobs under a service account. The same SAS programs can run using the same service account interactively without any issue. Anyone knows how to fix it?

 

MicrosoftTeams-image2.png

SASKiwi
PROC Star

Is it ALL batch jobs run with this service account or is it an intermittent problem as described by the original poster? If it is all batch jobs, then I can only assume there is something wrong with the service account's permissions or the batch job settings. What scheduler are you using to start the batch job? Try starting the batch job from a Windows command line. If that works it could be a scheduler-related issue. I'd also recommend opening a Tech Support track so more diagnosing can be done.  

liuk
Calcite | Level 5

This issue has happened intermittently and randomly among different batch jobs and SAS programs. We wouldn't know which program would run into this issue until the error occurred.

The service account should have the proper permission settings to the SAS server/file server. We use the good old Windows Task Scheduler.

Patrick
Opal | Level 21

Going forward please don't repurpose old discussions as this gets messy. Ask a new question and potentially add a reference link to a similar old discussion.

 

WORK points to a session specific folder location that gets created during SAS invocation and that's always owned by the user under which the session executes. This means a SAS process always has full access to WORK.

 

In my experience such intermittent access problems are almost always caused by a virus scanner that locks a file during the scan. You need to talk to your SAS Admin so that SAS files get excluded from scanning.

 

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 10 replies
  • 4289 views
  • 1 like
  • 8 in conversation