Hello ALL
I was wondering if we cound proc metaoperate or some other procedure to pause SAS stored process server and resume it after some time?
Hello @Sajid01,
I wonder what is your purpose or requirement, for "pausing" just the SAS Stored Process Server.
You could, of course, with some code, identify the sas.exe processes that are being launched as Stored Processes. This it not very complicated, just identifying the path used in those executions (including (StoredProcess string), and you will never have more than the size of your pool for the SAS Stored Process Server.
A different story is the "pausing" part... I think it is perfectly possible, but not as a "pause" state but as a "non accessible" state.
You could create a SAS code, with some IOM code, for denying Read Metadata to SASUSERS (and to SAS Trusted user and SAS General Services, if you will), while ensuring full access to the SAS Administrators (to ensure you won't corrupt the access to the SAS Stored Process). In this way, nobody can launch Stored Processes anymore, not even system services (just SAS Admins).
You would need, of course, another code to revert this status back to original state.
An alternative to above, much easier perhaps, is to make export original state of STP server, then change of permissions manually when nobody access the STP server, then export SAS Package of the STP server definition. With those 2 packages, you can create a one-line code to import the package when you want to enable, or disable the STP server.
Look for the utilities in SASPlatformObjectFramework\9.4\ExportPackage.exe and SASPlatformObjectFramework\9.4\ImportPackage.exe
With all of this, the procedure could be such as:
- disable STP server (with IOM or just Export/Import package codes)
- kill remaining SAS STP processes
- when you are ready, enable back the STP server
is it simple enough? I hope it might help you.
Best regards,
Juan
Signals on Linux and UNIX can be used to manage process execution. You could pause all execution of code in SAS Stored Processes by finding the process ID's of the Stored Process servers then sending them SIGSTOP to pause their execution. Once you want them executing again sending it a SIGCONT will get them running again.
Thanks
I am working on a windows environment.
Thanks for the information
Hello @Sajid01,
I wonder what is your purpose or requirement, for "pausing" just the SAS Stored Process Server.
You could, of course, with some code, identify the sas.exe processes that are being launched as Stored Processes. This it not very complicated, just identifying the path used in those executions (including (StoredProcess string), and you will never have more than the size of your pool for the SAS Stored Process Server.
A different story is the "pausing" part... I think it is perfectly possible, but not as a "pause" state but as a "non accessible" state.
You could create a SAS code, with some IOM code, for denying Read Metadata to SASUSERS (and to SAS Trusted user and SAS General Services, if you will), while ensuring full access to the SAS Administrators (to ensure you won't corrupt the access to the SAS Stored Process). In this way, nobody can launch Stored Processes anymore, not even system services (just SAS Admins).
You would need, of course, another code to revert this status back to original state.
An alternative to above, much easier perhaps, is to make export original state of STP server, then change of permissions manually when nobody access the STP server, then export SAS Package of the STP server definition. With those 2 packages, you can create a one-line code to import the package when you want to enable, or disable the STP server.
Look for the utilities in SASPlatformObjectFramework\9.4\ExportPackage.exe and SASPlatformObjectFramework\9.4\ImportPackage.exe
With all of this, the procedure could be such as:
- disable STP server (with IOM or just Export/Import package codes)
- kill remaining SAS STP processes
- when you are ready, enable back the STP server
is it simple enough? I hope it might help you.
Best regards,
Juan
Try PROC IOMOPERATE. See statements for QUIESCE and PAUSE.
The SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment.
SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.
Find more tutorials on the SAS Users YouTube channel.