Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 441
  • Last Modified:

Lotus Notes ver 6.5.1 - Open file error on Server - Why?

Hello,

Our goal is  have this agent launch at a scheduled time from a server.

When the agent launches at the scheduled time on the server it runs to the point of opening  the output file and quits.

When I run the agent  on my pc locally it does not generate any errors and places the output file on disk on the pc  with a path of  "programfile/lotes/notes/request..dat".

Below is a segment of code and the run time messages from the log. We have run this agent on different servers with Admin security with no differences.

Why can't it open the output file on the server but it can open the file on the pc?

LOTUS SCRIPT CODE

REM Dim Server As String
      Dim FilePath As String
      REM Server = db.Server
      
      FilePath =  "Request.dat"
      
      Set db = session.CurrentDatabase
      Set view = db.GetView("(AdvAndClone)")
      Set docBoth = view.GetFirstDocument
      
      REM -----------------SET up the input file  ----------------------------------
      
      Dim fileNum As Integer
      fileNum% = Freefile()
      
      REM ----------------Open input file for reading ---------------------------------------
      Print "Before opening file"
      Open  FilePath For Output As fileNum% Len = 510
      Print "After opening file"
      REM Loop for Licensee ADV/CloneAD Forms-------------------------------------------------------
      
FROM THE LOG

03/14/2005 15:15:40   AMgr: 'Agent 'ExtractApprovedRequests' in 'corpar/licensing.nsf' will run on behalf of 'Robert Harris/Development'
03/14/2005 15:15:41   AMgr: Agent ('ExtractApprovedRequests' in 'corpar/licensing.nsf') printing: Before opening file
03/14/2005 15:15:41   AMgr: Agent ('ExtractApprovedRequests' in 'corpar/licensing.nsf') printing: Error Message201: Operation is disallowed in this session
03/14/2005 15:15:41   AMgr: Agent ('ExtractApprovedRequests' in 'corpar/licensing.nsf') error message: No RESUME


Thanks.....


0
BeastDan
Asked:
BeastDan
  • 2
3 Solutions
 
Sjef BosmanGroupware ConsultantCommented:
What are the permissions of Robert Harris/Development on the server? You have to look in the NAB, in the Server document for the server, and check what is set on the Security tab. Writing a file on the server is a restricted operation, which means that the signer of the agent must be present in the list of people permitted to run restricted agents: righthand side, Programmability Restrictions, 4th line.
0
 
Sjef BosmanGroupware ConsultantCommented:
And the No RESUME error is because you have an On Error, the error is caught and you didn't end the on-error with a RESUME.
0
 
Bozzie4Commented:
I agree with Sjef : it's a security / rights issue.

Your agent also has to have the "2. Allow Restricted Operations" option set (in the Agent properties), apart from the security settings  in the server document.  You can also use the "Run agent as" option, to let the agent run as the server.  To do that, you need the "Allowed to run agents as somebody else" in the server document.

cheers,

tom
0
 
qwaleteeCommented:
Hi sjef_bosman,

> And the No RESUME error is because you have an On Error, the error is caught and you didn't
> end the on-error with a RESUME.
Or EXIT SUB or just END

You need the agent signer to be in a group listed in the "Allowed to run unrestricted agents" field fpr taht server, on the security tab.  Or, listed directly there by name, but groups are a better idea.

Best regards,
qwaletee
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now