yaai icon indicating copy to clipboard operation
yaai copied to clipboard

asteriskLogger under Windows

Open Tigger28 opened this issue 12 years ago • 7 comments

Hi Guys!

Is there any solution out now, to get asterisk Logger.php working under Windows?

I have installed Trixbox CentOS 5.5 with Asterisk, PHP 5.2.5 and MYSQL in VMware ESXI ( IP: 192.168.1.100 )

and my SugarCRM CE is also installed in ESXI under Windows ( IP: 192.168.1.101 )

So far I know that i need to create a Windows Service. I looked at this Link

http://stackoverflow.com/questions/5952500/setting-a-php-script-as-a-windows-service

But still I'm not further with it.

SRY for my bad English

Best regard, Mike

Tigger28 avatar Dec 18 '12 08:12 Tigger28

I'm the developer and I personally run asteriskLogger on windows. I just don't run it as a service...

I RDP into my server, open a command prompt and it runs for months... It was so stable I stopped worrying about the service.

That being said. It'd be a great help if you could do the research to figure out how to make it work as a service on windows.

blak3r avatar Dec 18 '12 10:12 blak3r

Oh and if you haven't already, check the Project TODO page. There are some notes there on research I had done prior. May be useful.

blak3r avatar Dec 18 '12 10:12 blak3r

THX alot blak3r for writting me back this fast. I'm new in this things, so could you give me please a short advice how to run asteriskLogger in the command prompt.

Tigger28 avatar Dec 18 '12 10:12 Tigger28

Found out how it works Great THX alot for your help :-)

Tigger28 avatar Dec 18 '12 12:12 Tigger28

cd <sugar root>/custom/modules/Asterisk/
php asteriskLogger

On Tue, Dec 18, 2012 at 5:27 AM, Tigger28 [email protected] wrote:

THX alot blak3r for writting me back this fast. I'm new in this things, so could you give me please a short advice how to run asteriskLogger in the command prompt.

? Reply to this email directly or view it on GitHubhttps://github.com/blak3r/yaai/issues/98#issuecomment-11480894.

blak3r avatar Dec 18 '12 17:12 blak3r

additional info:

"php" on Command Line only works after you Add the .PHP extension to the PATHEXT environment variable.

In my case i added the Path to the Sugar PHP file.

Mike :-)

Tigger28 avatar Dec 19 '12 09:12 Tigger28

Yep... that's important.

I got tricked into thinking this would be easy to do after seeing a manual page... 40 minutes later and I didn't get it completely working. I just committed what I did. I think it's pretty close. Maybe it'll work for you... not sure why I get service doesn't actually start.

Could you follow these instructions and see if you get an error about script not responding once you actually start it?

Here are the two files you'll need. https://github.com/blak3r/yaai/blob/master/misc/php_win32service.dll https://raw.github.com/blak3r/yaai/master/misc/create_win_service.php

  • Instructions:
      1. copy the php_win32service.dll to your /ext directory.
      1. update your php.ini file to include extension=php_win32service.dll
      1. Run the script. If it failed, you need to find the correct php_win32service.dll for your particular php version / compiled settings
      1. Once script runs successfully, you'll see it in the services control panel.
      1. The script wouldn't start for me (Blake Robertson)... but I'm committing it anyway as maybe someone can take it from here.

blak3r avatar Dec 20 '12 05:12 blak3r