How to Determine when least amount of users logged in on Server

Reply
Regular Contributor
Posts: 151

How to Determine when least amount of users logged in on Server

Hi Friends

How can I find when the least and maximum amount of users are logged in on the servers, Is there any way to find out that ?

I can find how many users logged in on the server using ps -ef | grep sas

but is  there any way to find during which time there will be lesser users logged in to server.

am using SAS 9.2 on Solaris 5.10

Super User
Posts: 7,809

Re: How to Determine when least amount of users logged in on Server

Posted in reply to sasprofile

I'd write a script that prints the date/time in a suitable format, does ps -ef|grep sas|wc -l and appends both to a file.

Then have that script run regularly (since ps doesn't eat a lot of CPU, you can run it basically every minute), and read the output file with a SAS data step into a dataset for further statistics.

Put that into the script:

RESULT=`date +%Y%m%d%H%M%S;ps -ef|grep sas|wc -l`

echo $RESULT>>outputfile

You then get 2 items in each line, the datetime and the number of SAS processes.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Regular Contributor
Posts: 151

Re: How to Determine when least amount of users logged in on Server

Posted in reply to sasprofile

Not able to Delete Stored Procedure from SAS EG 5.1

Hi Friends,

am try to delete stored procedure from EG 5.1, I gave deleted permissions to stored procedure and also folders.

but it still throwing below error saying.

EG Message

<?xml version=”1.0” ?><Exceptions><Exception><SASMessage

severity=”Error”.The user does not have permission to perform this

action.</SASMessage></Exception></Exception>

Any help would really appreciated

Trusted Advisor
Posts: 3,214

Re: How to Determine when least amount of users logged in on Server

Posted in reply to sasprofile

Sas profile  for your first question... Measuring the number of user running a sas proces is a good measurement  for the load on the machine. It is not the same as then number of sas users connected to the machine. When doing a login to the Sas metadata server no sas proces is started but the connection is made.

Your second question about a SP. The SP is a registration in metadata (sasfolder) that connects to a SAS server and has code on the os ( Unix folder) When any of these 3 parts is not allowed you get a message of not allowed..

---->-- ja karman --<-----
Regular Contributor
Posts: 151

Re: How to Determine when least amount of users logged in on Server

Jaap Kaarman,

I already gave permission to the stored procedure and also full permission to the metadata folder where this stored procedure resides and also had given full permissions to stored procedure sas program on Unix server,but still getting same error.

am not understanding where it's going wrong.

Thanks

Kiran

Trusted Advisor
Posts: 3,214

Re: How to Determine when least amount of users logged in on Server

Posted in reply to sasprofile

Checked the third option? That connection association to a server? That one is the metadata object  at the application server

---->-- ja karman --<-----
Regular Contributor
Posts: 151

Re: How to Determine when least amount of users logged in on Server

I Have checked the connection from EG to Application server and its connecting with any issues.

Trusted Advisor
Posts: 3,214

Re: How to Determine when least amount of users logged in on Server

Posted in reply to sasprofile

You can connect to the server with eguide that is read accès of the server. To alter information you must have write access. The admin of the server is defined as admin access. There are two types of updates to an appserver. That has a reflection in the metadata security or at least should have.

---->-- ja karman --<-----
Regular Contributor
Posts: 151

Re: How to Determine when least amount of users logged in on Server

Has an admin I connected to sas management console and gave read/write access to the stored procedure which the user wanted to delete from EG and I gave Delete permissions to the user meta data folder level where the stored procedure is stored and I gave full permissions to the program of the stored procedure on server also but still same error.

Trusted Advisor
Posts: 3,214

Re: How to Determine when least amount of users logged in on Server

Posted in reply to sasprofile

Still missing your mentioning of update accès to the appserver in the sas metadata.

---->-- ja karman --<-----
Regular Contributor
Posts: 151

Re: How to Determine when least amount of users logged in on Server

am not understanding what you are saying,please can you brief me in detail what you want me to do ?

Trusted Advisor
Posts: 3,214

Re: How to Determine when least amount of users logged in on Server

Posted in reply to sasprofile

When you define a SP it is more obvious.

You have to give an appserver to which the SP is belonging to. It can be a workspace or stored process server. The appserver get a registration in the Sas metadata at the appserver level eg SAS App. When deleting a SP that registration will also needed to be deleted. You cannot see that viewing the SAS APP but reviewing your SP should give the server it has associated to.

---->-- ja karman --<-----
Regular Contributor
Posts: 151

Re: How to Determine when least amount of users logged in on Server

So basically you want me to view the properties of SP and check with which App server the SP associated with and delete the registered App server(SAS Main)

Trusted Advisor
Posts: 3,214

Re: How to Determine when least amount of users logged in on Server

Posted in reply to sasprofile

Not deleting the SAS APP of course but that invisible association of the SP that must be there. The most reliable way to verify is having a new dummy SP being defined in the same way you are trying to delete one. When that security is blocked it should be more informational. Adding something and deleting again is less risky than starting to delete and not knowing how to recover from an untended change.

---->-- ja karman --<-----
Ask a Question
Discussion stats
  • 13 replies
  • 790 views
  • 0 likes
  • 3 in conversation