Jump to content
urza311

Retrospect Event Hander and 10.5

Recommended Posts

I've just setup one of my clients with a new iMac running 10.5.2 and Retrospect 6.1.138. I typically use the python-based Retrospect Event Handler to send backup notifications, but it doesn't seem to work under 10.5. I have it setup just like I've done many others but when Retrospect launches, I see the REH launch and quit twice, then it doesn't relaunch again.

 

I don't think this is an Intel-specific problem because I have another Mac running 10.4.11 and 6.1.138 that works fine, so I figure this is an issue with 10.5, and maybe with AppleScript? Has anyone else run into this and/or developed a workaround?

Share this post


Link to post
Share on other sites

I posted this question about a month ago and no one has replied to it yet. I've checked and the problem is still occurring. I've made sure everything is up-to-date as of this writing... it has all the latest Apple updates, and has the latest Retrospect 6.1 driver (6.1.14.101) but the problem remains the same. If you have the Retrospect Event Handler and macmail.py in the /library/preferences directory (like I have it setup on many other Macs), when Retrospect launches you'll see the REH attempt to launch, then quit; it appears to launch a second time and quits again a second later, but stays shut down after that. My guess is that changes in AppleScript included in 10.5 are making the REH malfunction and quit, but I know very little about AppleScript and that's just a gut feeling.

 

1. Has anyone run into this, or developed a workaround for the problem?

 

2. I really, really, REALLY hope that when Retrospect X comes out that it includes a genuine email notification system. I love Retrospect for taking care of both my Mac and Windows stations, but the email notification systems are so pathetic as to be practically worthless. If and when they work, about the best notification I get is if the backup worked or not. If there was an error, I may be lucky to get some idea of what it was. What I'd like to see is a FULL copy of the operations log entry for the evening emailed at the completion of the backup -- everything from the start time to which files failed comparison to throughput. It's all worthwhile information, and I shouldn't have to go to a specific station to find out why it failed to backup. The email notification should be enough for me to know what happened. And PLEASE setup this system so you can use port 587 for outgoing email. Port 25 is so 1990's. It should be a robust system capable of changing the outgoing port, setting SMTP authentication, and even SSL. It should be REAL email, not some cobbled-together attempt to use AppleScript to avoid putting it into the backup system properly.

 

Nuff said.

Share this post


Link to post
Share on other sites

Charles,

 

I only have used it on our Xserve G5 running MacOS 10.4.x Server (and, before that, with earlier versions of Retrospect since Retrospect 2.0, on our now-retired ASIP server), and it works, as you note on your other computers.

 

Just a thought, in case it is related to AppleScript changes in 10.5: Have you tried opening the AppleScript (Retrospect Event Handler) in the 10.5 Script Editor, then resaving the script and doing the little dance (save as application, stay open, never show startup screen, then delete the .app extension)? That would force a grammar/compilation check of the code.

 

Just a thought, in case you just copied the Event Handler without a resave.

 

I agree with you about the email notification system (which we have endured for over 15 years), but we also need scripting (not necessarily AppleScript, and preferably not AppleScript) synchronized with backup scripts so that we can take appropriate actions on our server during backup (e.g., stop the cyrus mailserver, replicate the mail store, restart the mailserver, back up the replicated mail store, etc.).

 

Russ

Share this post


Link to post
Share on other sites

I also have experienced this problem.

 

We have recently purchased a new Xserve, that shipped with 10.5.2, and as such were 'forced' to run the new OS. I have had no success with the Retrospect event handler on this machine (I have only tried to use it to send email notifications) under 10.5.2, with both the Mail.app scripts and the Python scripts. As described in previous posts - the event handler 'tries' to open twice, and then disappears, without actually performing any of the commands set out in the script.

 

We have a Desktop version of Retrospect also - which is running on a PPC workstation with 10.4.11, and there are no issues with the event handler on that machine.

 

I must confess that I'm not overtly savvy with AppleScript, but as mentioned above - we've had no issues using the same scripts on a Tiger machine.

 

I would consider this a fundamental aspect of any server based backup solution, and hope that either EMC fix it ASAP, or at the very least, find a reliable workaround.

 

Any help would be greatly appreciated...

Share this post


Link to post
Share on other sites
the event handler 'tries' to open twice, and then disappears, without actually performing any of the commands set out in the script.

 

All Retrospect does is call for an item with the correct name in the correct location to launch. After that, the application itself is the master of its own domain.

 

- Have you tried putting a fresh copy of the REH application into /Library/Preferences/Retrospect/ to ascertain if the problem lies with how you've customized the REH that you want to provide your specific needs?

 

I just tried in 10.5.2 and the Event Handler AppleScript application launches (once) and sits there idle (since everything is commented out of it).

 

- If a fully commented script launches correctly, what AppleScript code is in the one you're using?

Share this post


Link to post
Share on other sites

May I suggest, as I did above, since you haven't indicated whether you have done #2, below:

 

(1) use only the Python version; don't get me started on the others, but I'm not surprised if they don't work because Apple changes the AppleScript dictionary interface to Mail from release to release;

 

(2) Have you opened the REH in the AppleScript editor and then gone through the rubber chicken dance to: save as application, stay open, never show startup screen, then rename the application by deleting the ".app" extension? That will force the AppleScript editor to revalidate the REH AppleScript code, and to make any necessary changes if Apple has modified the AppleScript bytecode format for Leopard.

 

Russ

Share this post


Link to post
Share on other sites
To solve the problem, run the Script Editor in rosetta when you edit the Retrospect Event Handler.

 

What problem does this solve? And how does it solve it?

Share this post


Link to post
Share on other sites
To solve the problem' date=' run the Script Editor in rosetta when you edit the Retrospect Event Handler.[/quote']

 

What problem does this solve? And how does it solve it?

 

If you read the first post of this thread, you would know the problem that this solves.

 

I have no idea why running the Script Editor in rosetta fixes the problem but it does. You can also edit the Retrospect Event Handler on a PPC mac and then copy to a Intel mac. For whatever reason, if your using Script Editor as an universal application to edit the Retrospect Event Handler. You get the symptoms discussed in the first post of this thread.

Share this post


Link to post
Share on other sites
For whatever reason, if your using Script Editor as an universal application to edit the Retrospect Event Handler. You get the symptoms discussed in the first post of this thread.

 

I don't.

 

On my machine just now, a script created in Script Editor running native x86 behaves the same as a script created in Script Editor running in Rosetta; that is, in both cases, the script launches as expected and executes whatever AppleEvents are contained inside.

 

iMac CoreDuo

OS X 10.5.2

Retrospect 6.1.222 (a current beta, but my previous test upthread, was done with the then-shipping version)

 

As noted above, there is nothing magical about the Retrospect Event Handler script other then its name.

 

The original poster complained that he/she didn't get a reply after a month, then has not come back with the answer to a question posed by someone (Russ) who was trying to help.

 

The second poster also didn't answer questions posed, making it impossible to help.

 

I have no idea why users are seeing a double-launch attempt from an AppleScript application. I'd ask these users what happens when said script is launched directly from the Finder by double clicking it. I'd also ask these users again if they have tried a clean copy of the script from the Retrospect installer.

 

Dave

Share this post


Link to post
Share on other sites
On my machine just now, a script created in Script Editor running native x86 behaves the same as a script created in Script Editor running in Rosetta; that is, in both cases, the script launches as expected and executes whatever AppleEvents are contained inside.

 

I have to disagree when it relates to the Retrospect Event Handler script.

 

I've tested the following on 2 different x86 macs. One running 10.5.2 server and the other 10.5.2.

 

- Launch a fresh copy of the Retrospect Event Handler unopened by Script Editor. It launches and stays running.

- Open Retrospect Event Handler in Script Editor running native x86. Save and close the file. Launch the script and it immediately closes.

- Now open the Retrospect Event Handler you just tried in Script Editor, this time in rosetta mode. Save and close the file. Launch the script and it immediately closes.

- Open a fresh copy of the Retrospect Event Handler in Script Editor running through rosetta. Save and close the file. Launch the script and it stays running.

 

I don't encounter any of these problems on a 10.5.2 PPC server.

Share this post


Link to post
Share on other sites

Steps to reproduce! We LOVE steps to reproduce!!

 

- Run Retrospect installer, select Custom Install of just the AppleScript Utilities.

- Launch any of the Retrospect Event Handler scripts in the AppleScript Utilities folder. It launches and stays running.

- Open Retrospect Event Handler in Script Editor running native x86.

- Add a space; save and close the file.

- Launch the script and it immediately closes.

 

- Launch a fresh copy of the Retrospect Event Handler. It launches and stays running.

- Open Retrospect Event Handler in Script Editor running native x86.

- Add a space; Save As... with the same name to a different location.

- Launch the script; it launches and stays running.

 

 

I don't see anything obviously different among the original file, the broken saved file, and the happy file after a save as, although I didn't dig very deeply. They all have a resource fork, they all have the same Type/Creator codes. None has an .app file extension.

 

So running in Rosetta isn't required (I didn't test that, and will assume that it works as described in the steps to reproduce; did I say that we LOVE steps to reproduce?), as saving as a new file from Script Editor will fix a broken file. Interesting.

 

Share this post


Link to post
Share on other sites

- Launch a fresh copy of the Retrospect Event Handler. It launches and stays running.

- Open Retrospect Event Handler in Script Editor running native x86.

- Add a space; Save As... with the same name to a different location.

- Launch the script; it launches and stays running.

 

I tried this and it immediately closes. 10.5.3 didn't make any difference either.

Share this post


Link to post
Share on other sites

 

- Open a fresh copy of the Retrospect Event Handler in Script Editor running through rosetta. Save and close the file. Launch the script and it stays running.

 

This works for me.

Xserve intel, Mac OS X server 10.5.3, Retrospect workgroup 6.1.138.

 

Thanx Eric

 

Dimitri

Share this post


Link to post
Share on other sites

Thanks Eric.

 

After running fine for years I updated my password in Retrospect Event Handler. After that I experienced the same symptoms as urza311 with REH quitting as soon as it launched.

 

I opening Script Editor in Rosetta, copied everything from the old REH to a fresh copy, pasted, and saved. Everything's happy again.

Share this post


Link to post
Share on other sites

I have not been able to get an Event Handler to work - any of them - since updating to Retrospect 6.1.138. Dual G4 running 10.4.11, had previously been using the python notification set, and after the update, the script attempts to run and all I get is that "The script exited with a non-zero status."

 

I was hoping that the most recent update (6.1.230) would either install updated scripts, or handle the event notification process more effectively, but regardless of which script set I try (the Entourage script is useless because Entourage wants to verify each message sent, and I have yet to dig for the place to disable the check) notifications will not send. (The Mail.app script opens an email to send a notification, but the TO field is empty, and Mail is convinced it cannot send the message - also "new" since 6.1.138.)

 

The other very odd behavior I'm seeing regarding the scripts is that if I open any of them (of course, running on the PPC) and use "Save As..." to save the scripts to the /Library/Preferences/Retrospect directory, NONE of the saved-as scripts will run automatically when a triggering event occurs in Retrospect. I imagine this has everything to do with how I am saving the applications (need to be app bundles?), but I found it curious that only scripts that have been copied from the original AppleScript Utilities directory work with Retrospect.

 

Any insights regarding how to get notifications working again would be very much appreciated.

Share this post


Link to post
Share on other sites
The other very odd behavior I'm seeing regarding the scripts is that if I open any of them (of course, running on the PPC) and use "Save As..." to save the scripts to the /Library/Preferences/Retrospect directory, NONE of the saved-as scripts will run automatically when a triggering event occurs in Retrospect.

 

Not odd at all.

 

Select the script file, and do "Get Info" from the File menu. In the "Name" field, you'll probably see where the OS X version of Script Editor has added the ".app" file extension to the package.

 

Retrospect was hard coded to look for a specific name that does _not_ contain this file extension. Remove it, and the script should work.

Share this post


Link to post
Share on other sites

Thank you. I figured the issues saving out of Script Editor had to be something relatively simple.

 

Unfortunately, that still doesn't get me to the utopia where I actually receive notifications. Any insights on what is new & different about the latest versions of Retrospect (since 6.1.138) that the python script would be called any differently that it would only get me the "exited with non-zero status" rather than any mail sending? I've looked through the python script to make sure the correct binary is being called (seems to be in the same place in 10.4.11), but I'm not yet up-to-speed on Python coding, so I can't really check the syntax of the script to see why else it might be exiting without being able to send mail.

 

Thanks for the tip!

 

Gary

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×