hi, how to configure mongrel_cluster in windows. mongrel_rails cluster::configure -e development -p 3000 -N 2 i have used this one its configured correctly then if i start the server it is throwing error.if any one knows how to configure help me with regards shiva -- Posted via http://www.ruby-forum.com/.
Shiva Kumaran escribi?:> hi, > how to configure mongrel_cluster in windows. > mongrel_rails cluster::configure -e development -p 3000 -N 2 i have used > this one its configured correctly then if i start the server it is > throwing error.if any one knows how to configure help me > > with regards > shiva >what error? -- Rafael Garcia Ortega -------------- next part -------------- A non-text attachment was scrubbed... Name: rgo.vcf Type: text/x-vcard Size: 241 bytes Desc: not available Url : http://rubyforge.org/pipermail/mongrel-users/attachments/20071120/14626bd0/attachment.vcf
On Nov 20, 2007 10:53 AM, Shiva Kumaran <lists at ruby-forum.com> wrote:> hi, > how to configure mongrel_cluster in windows. > mongrel_rails cluster::configure -e development -p 3000 -N 2 i have used > this one its configured correctly then if i start the server it is > throwing error.if any one knows how to configure help me >mongrel_cluster rely on fork() functionality, which is missing in the ruby mswin32 implementation, so it will fail trying to "daemonize" mongrel_rails. Right now, a workaround is set N services (mongrel_service) for N members of the cluster. This remembers me need to get the dust off on some stuff... but that takes time :-P -- Luis Lavena Multimedia systems - Leaders are made, they are not born. They are made by hard effort, which is the price which all of us must pay to achieve any goal that is worthwhile. Vince Lombardi
Rafael Garc?a wrote:> Shiva Kumaran escribi?: >> hi, >> how to configure mongrel_cluster in windows. >> mongrel_rails cluster::configure -e development -p 3000 -N 2 i have used >> this one its configured correctly then if i start the server it is >> throwing error.if any one knows how to configure help me >> >> with regards >> shiva >> > what error?iam getting this error D:\project\sutra>mongrel_rails cluster::start starting port 3000 c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cluster/init.rb :98:in ``'': Exec format error - mongrel_rails start -d -e development -p 3000 -P tmp/pids/mongrel.3000.pid -l log/mongrel.3000.log (Errno::ENOEXEC) from c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cl uster/init.rb:98:in `start'' from c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cl uster/init.rb:80:in `each'' from c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cl uster/init.rb:80:in `start'' from c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cl uster/init.rb:239:in `run'' from c:/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-mswin32/bin/../lib/mon grel/command.rb:212:in `run'' from c:/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-mswin32/bin/mongrel_ra ils:281 from c:/ruby/bin/mongrel_rails:16:in `load'' from c:/ruby/bin/mongrel_rails:16 -- Posted via http://www.ruby-forum.com/.
Shiva Kumaran wrote:> Rafael Garc?a wrote: >> Shiva Kumaran escribi?: >>> hi, >>> how to configure mongrel_cluster in windows. >>> mongrel_rails cluster::configure -e development -p 3000 -N 2 i have used >>> this one its configured correctly then if i start the server it is >>> throwing error.if any one knows how to configure help me >>> >>> with regards >>> shiva >>> >> what error? > > iam getting this error > > > D:\project\sutra>mongrel_rails cluster::start > starting port 3000 > c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cluster/init.rb > :98:in ``'': Exec format error - mongrel_rails start -d -e development -p > 3000 -P > tmp/pids/mongrel.3000.pid -l log/mongrel.3000.log (Errno::ENOEXEC) > from > c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cl > uster/init.rb:98:in `start'' > from > c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cl > uster/init.rb:80:in `each'' > from > c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cl > uster/init.rb:80:in `start'' > from > c:/ruby/lib/ruby/gems/1.8/gems/mongrel_cluster-1.0.5/lib/mongrel_cl > uster/init.rb:239:in `run'' > from > c:/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-mswin32/bin/../lib/mon > grel/command.rb:212:in `run'' > from > c:/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-mswin32/bin/mongrel_ra > ils:281 > from c:/ruby/bin/mongrel_rails:16:in `load'' > from c:/ruby/bin/mongrel_rails:16Yeah this is an unfortunate bug with the way that ''bin'' files are setup on windows. In particular, you can''t call exec on a text file containing nothing but ruby. The solution is to add ".bat" or ".cmd" to the binary name in the offending call to system / exec, lead it with a call to ruby. It''s probably worth noting at this point that the "-d" option doesn''t work either, so I am not sure the current cluster commands will work on windows.
On Nov 21, 2007 3:18 AM, James Tucker <jftucker at gmail.com> wrote:> Yeah this is an unfortunate bug with the way that ''bin'' files are setup on windows. In particular, you can''t call exec on a text file containing nothing but ruby. The solution is to add ".bat" or ".cmd" to the binary name in the offending call to system / exec, lead it with a call to ruby. >this is the way system() works. a shame :-P> It''s probably worth noting at this point that the "-d" option doesn''t work either, so I am not sure the current cluster commands will work on windows.Yep, I keep telling this over and over, no mongrel_cluster for windows. -- Luis Lavena Multimedia systems - Leaders are made, they are not born. They are made by hard effort, which is the price which all of us must pay to achieve any goal that is worthwhile. Vince Lombardi
Luis Lavena wrote:> On Nov 21, 2007 3:18 AM, James Tucker <jftucker at gmail.com> wrote: >> Yeah this is an unfortunate bug with the way that ''bin'' files are setup on windows. In particular, you can''t call exec on a text file containing nothing but ruby. The solution is to add ".bat" or ".cmd" to the binary name in the offending call to system / exec, lead it with a call to ruby. >> > > this is the way system() works. a shame :-PIt is actually possible to make it work: * Implement a program which scans for, and runs any shebang on the given argument (roughly emulating execve). * set PATHEXT+=. * Associate extensionless files with the program you wrote for step 1. Although that''s well beyond the scope of mongrel herself.> >> It''s probably worth noting at this point that the "-d" option doesn''t work either, so I am not sure the current cluster commands will work on windows. > > Yep, I keep telling this over and over, no mongrel_cluster for windows. >With regard to fork, IIRC win32-process adds this functionality.
On Nov 21, 2007 4:56 AM, James Tucker <jftucker at gmail.com> wrote:> Luis Lavena wrote: > > On Nov 21, 2007 3:18 AM, James Tucker <jftucker at gmail.com> wrote: > >> Yeah this is an unfortunate bug with the way that ''bin'' files are setup on windows. In particular, you can''t call exec on a text file containing nothing but ruby. The solution is to add ".bat" or ".cmd" to the binary name in the offending call to system / exec, lead it with a call to ruby. > >> > > > > this is the way system() works. a shame :-P > > It is actually possible to make it work: > > * Implement a program which scans for, and runs any shebang on the given argument (roughly emulating execve). > * set PATHEXT+=. > * Associate extensionless files with the program you wrote for step 1. > > Although that''s well beyond the scope of mongrel herself. >Is a bit more complicated than that, but as you said, is beyond mongrel scope ;-)> > > >> It''s probably worth noting at this point that the "-d" option doesn''t work either, so I am not sure the current cluster commands will work on windows. > > > > Yep, I keep telling this over and over, no mongrel_cluster for windows. > > > > With regard to fork, IIRC win32-process adds this functionality. >It does some funny things sometimes. And other weird ones since sometimes you cannot reproduce the failing procedure to report a bug :-P -- Luis Lavena Multimedia systems - Leaders are made, they are not born. They are made by hard effort, which is the price which all of us must pay to achieve any goal that is worthwhile. Vince Lombardi