BookmarkSubscribeRSS Feed
ckx
Quartz | Level 8 ckx
Quartz | Level 8

I'm using a VB script to run a series of SAS syntax files sequentally in batch mode, based on the script posted by Chris Hemedinger on his blog (
Using SAS Enterprise Guide to run programs in batch - The SAS Dummy), This basically works except that EG randomly asks for credentials (around 5% of the syntax files run). You have to enter your user name and password, then the script continues. Can anyone shed any light on why this happens and how to prevent it?

I'm using EG 4.3 with SAS 9.2 on a remote server. The options are set for credentials to persist for user. When using EG interactively, I'm never asked for credentials (unless I've changed my password). On rare occasions, I get a message "unable to connect" but the syntax runs normally if I press F8 a second time.I've never been asked for credentials when running a single file in batch.

10 REPLIES 10
Haikuo
Onyx | Level 15

Are you on Win7?

ckx
Quartz | Level 8 ckx
Quartz | Level 8

No, I'm currently running WinXP. The script does work under Win7 though.

Haikuo
Onyx | Level 15

When I mention Win7, I was thinking about somehow by default win7 local security setting "not allow user to save credentials", that was not the case. When you look at the facts: 1. no problem if you run interactively, meaning no problem when you are LOG ON. 2. Sporadic prompt for credentials when running batch. That makes one think that somehow your credentials can't be retrieved reliably when needed. I would file a ticket with SAS and talk to my Windows team at the same time.

Haikuo

ckx
Quartz | Level 8 ckx
Quartz | Level 8

The thing is, the script works as intended about 95% of the time. That would indicate it's not a matter of retaining credentials. It might be related to a configuration setting on the server side, to prompt for credentials if sessions start too frequently.

ChrisHemedinger
Community Manager

If a connection attempt is made but fails for any reason (network issue, wrong password, server problem), EG will "forget" the credentials it might have cached locally and prompt you on the next connection attempt.

It's possible that during your process, such a connection fails for some reason, and then EG decides it needs to prompt.

You can configure a "credentials.xml" file that might help.  This provides EG with a "go-to" location for where to find reliable credentials during automation.

See this SAS Note:

30917 - Scheduling projects in SAS® Enterprise Guide®

Chris

It's time to register for SAS Innovate! Join your SAS user peers in Las Vegas on April 16-19 2024.
Haikuo
Onyx | Level 15

Chris,

On Win7 if local security policy setting do NOT allow user to save credentials, will "credentials.xml" help to by-pass this security policy? I have tried by following your blog, but failed. just want to confirm with you.

Sorry, ckx, for borrowing your platform.

Thanks,

Haikuo

ChrisHemedinger
Community Manager

Haikuo,

Yes, if you record your credentials in a local file, you might inadvertently defeat any policy against caching credentials.  The credentials.xml mechanism was designed for when there is no logged-in user and the automation process needs to run.

SAS Admins can control some of this by setting the SASSEC_LOCAL_PW_SAVE option in the omaconfig.xml file.

It's time to register for SAS Innovate! Join your SAS user peers in Las Vegas on April 16-19 2024.
Haikuo
Onyx | Level 15

Thanks a lot!

Haikuo

ckx
Quartz | Level 8 ckx
Quartz | Level 8

Thanks Chris, this sounds good. No problems so far but maybe it's too quick to tell. I'll report back to this forum if the problem does come back.

ckx
Quartz | Level 8 ckx
Quartz | Level 8

I get the impression that a credentials.xml file helps but in any case not for 100%. EG prompted me for my credentials again today, for the third of 24 files. This could be related to the fact that EG was open at the time (I wasn't doing anything in it at the time).

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 10 replies
  • 2464 views
  • 3 likes
  • 3 in conversation