laurentades Posted July 19, 2015 Posted July 19, 2015 Weird issue here. Running FMS 13.0v5 and FTPeek 1.66 enterprise on OS X 10.10. I am working on a script A calling FTPeek upload to FTP. Script B calls script A as part of an overall process. When i call script B from script A with usual Perform Script, everything works fine. However when i call it with Perform Script on Server (PSoS) - which is supposed to be supported by enterprise license - the script basically hangs. Then the FMS Admin-Console Activity/Clients shows a client connection as "FileMaker Script" which will basically won't leave the queue - even if I send a disconnect message. Only way to solve the issue is restart the entire host...! When running in debug mode from FMP, the moment script B calls script a with PSoS, FMP just freezes and I need to force quit it. I understand that 1.66 brought support for PSoS but that only applies to enterprise license which is what i have as my order confirmation message tells me so... Any idea anyone ? Logs attached. Thanks 360Plugins_ServerScripting64.log
Wim Decorte Posted July 19, 2015 Posted July 19, 2015 Triple-check your script for any non-server compatible script steps. As an aside, you don't need to restart the entire host, when a scedule or a PSoS call hangs just restart the FMS script engine: fmsadmin restart fmse
laurentades Posted July 20, 2015 Author Posted July 20, 2015 I have written 2 super simple scripts: scriptA:- Perform Script on Server [scriptB]- Exit Script[] scriptB:- Set Variable [$ftpRegister; Value:FTPeek_Register("msomeLicenseKey"" ; "someRegisteredName")]- Set Variable [$ftpPublicKey; Value:FTPeek_GetPublicKey("someIPAddress")]- Set Variable [$ftpConnect; Value:FTPeek_ConnectSFTP("someIPAddress" ; $ftpPublicKey ; "someUser" ; "somePassword" )]- Set Variable [$ftpDisconnect; Value:FTPeek_Disconnect]- Exit Script[] I run scriptA in Debug Mode from FMP and progressively enable the scriptB steps. All is good until i bring the last step in : the one calling function FTPeek_Disconnect which causes the script to hang. Interestingly, another scenario causes the script to hang: no matter how many script step i enable in scriptB, when i run script A without debug step-by-step but all-in-one-go, the script hangs as well. Very confusing...
Wim Decorte Posted July 20, 2015 Posted July 20, 2015 What you may be forgetting is that the PSoS call also runs whatever OnOpen script runs on the file and that one (or any of its subscripts) may be the cause for the hangups...
ryan360Works Posted July 20, 2015 Posted July 20, 2015 Hi laurentades, I took a look at your logs and there is not any ftpeek function calls in the log. The only thing in the log looks to be a schedule that runs with a scriptmaster custom plugin. Our logs overwrite when the script engine is restarted so I suspect that is why there isn't anything in the log. Go ahead and restart the server(or as mentioned use the terminal command "fmsadmin restart fmse -y") run the PSOS and then repost your logs or send them directly to me at [email protected] . Additionally, run the script locally without the PSOS call and send the local logs as well. I will take a look and see if there is anything that indicates why you are getting the hang. Regards,
laurentades Posted September 1, 2015 Author Posted September 1, 2015 Nailed it. To be more specific: the script was looping through records for uploads and was performing a Connect /Disconnect for each record. It appears that the ftp service was having a hard time coping with the intense connect/disconnect pace and thus causing a lag on an erratic basis. Solved by opening the ftp connection once, proceed with the loop of so many records and then disconnect. Important note: same was not happening with local OS X FTP service, therefore the suspect would be the target ftp service. Unfortunately I don’t know which one is used over there. Hope that helps someone out there.
Recommended Posts
This topic is 3665 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now