Closed GoogleCodeExporter closed 9 years ago
Please provide the output of commands:
* whereis vzctl
* dpkg -l vzctl
Original comment by sibprogrammer
on 18 Jun 2011 at 2:44
root@XXXXXXX:~# whereis vzctl
vzctl: /usr/local/sbin/vzctl /usr/local/lib/vzctl
root@XXXXXXX:~# dpkg -l vzctl
No packages found matching vzctl.
Original comment by nshe...@gmail.com
on 18 Jun 2011 at 3:38
Looks like you compiled vzctl from sources. So you can add to the top of file
/opt/ovz-web-panel/utils/hw-daemon/hw-daemon.rb :
ENV['PATH'] += ':/usr/local/sbin'
Restart daemon and everything should be ok.
Original comment by sibprogrammer
on 19 Jun 2011 at 2:47
Here's the output of restarting the daemon
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# service owp restart
Stopping OpenVZ Web Panel server
Watchdog daemon was stopped.
Starting OpenVZ Web Panel
Starting watchdog daemon...
=> Booting WEBrick...
=> Rails 2.2.2 application started on http://0.0.0.0:3000
[2011-06-19 15:36:56] INFO WEBrick 1.3.1
[2011-06-19 15:36:56] INFO ruby 1.8.7 (2010-01-10) [x86_64-linux]
Syncing physical servers state...
/opt/ovz-web-panel/vendor/rails/railties/lib/commands/runner.rb:47:
/opt/ovz-web-panel/lib/hw_daemon_client.rb:48:in `exec': Command 'vzctl
--version ' execution failed with code 127 (HwDaemonExecException)
Output: sh: vzctl: command not found
from /opt/ovz-web-panel/app/models/hardware_server.rb:220:in
`sync_server_info'
from /opt/ovz-web-panel/app/models/hardware_server.rb:231:in `sync'
from (eval):1
from (eval):1:in `each'
from (eval):1
from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `eval'
from
/opt/ovz-web-panel/vendor/rails/railties/lib/commands/runner.rb:47
from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in
`gem_original_require'
from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'
from /opt/ovz-web-panel//script/runner:3
Adding that line to the file did not change the output of saving the
configuration.
Original comment by nshe...@gmail.com
on 19 Jun 2011 at 7:39
Show me exactly what do you have in the beginning of hw-daemon.rb file now.
Original comment by sibprogrammer
on 20 Jun 2011 at 5:27
That one line is the only thing in there. Is it just worth it to remove it
(OWP) and start again from scratch? This was an upgrade from 1.5
Original comment by nshe...@gmail.com
on 20 Jun 2011 at 5:37
This issue was closed by revision r912.
Original comment by sibprogrammer
on 20 Jun 2011 at 5:40
So how do i fix it?
Original comment by nshe...@gmail.com
on 20 Jun 2011 at 6:21
Replace your hw-daemon.rb with
http://ovz-web-panel.googlecode.com/svn/trunk/utils/hw-daemon/hw-daemon.rb
Original comment by sibprogrammer
on 20 Jun 2011 at 10:40
Still having the same issues, here's the output:
root@birmingham-new:~# cd /opt/ovz-web-panel/
app/ db/ lib/ public/ revision tmp/ version
CHANGELOG doc/ LICENSE Rakefile script/ utils/
config/ INSTALL log/ README test/ vendor/
root@birmingham-new:~# cd /opt/ovz-web-panel/
app/ db/ lib/ public/ revision tmp/ version
CHANGELOG doc/ LICENSE Rakefile script/ utils/
config/ INSTALL log/ README test/ vendor/
root@birmingham-new:~# cd /opt/ovz-web-panel/utils/
hw-daemon/ watchdog/ whmcs/
root@birmingham-new:~# cd /opt/ovz-web-panel/utils/hw-daemon/
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# ls
certs hw-daemon.ini.sample hw-daemon.pid
hw-daemon.ini hw-daemon.log hw-daemon.rb
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# service owp stop
Stopping OpenVZ Web Panel server
Watchdog daemon was stopped.
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# lsd
No command 'lsd' found, but there are 17 similar ones
lsd: command not found
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# ls
certs hw-daemon.ini.sample hw-daemon.pid
hw-daemon.ini hw-daemon.log hw-daemon.rb
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# mv hw-daemon.rb
hw-daemon.rb.bak
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# ls
certs hw-daemon.ini.sample hw-daemon.pid
hw-daemon.ini hw-daemon.log hw-daemon.rb.bak
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# man wget
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# wget
http://ovz-web-panel.googlecode.com/svn/trunk/utils/hw-daemon/hw-daemon.rb
--2011-06-21 10:12:10--
http://ovz-web-panel.googlecode.com/svn/trunk/utils/hw-daemon/hw-daemon.rb
Resolving ovz-web-panel.googlecode.com... 209.85.225.82
Connecting to ovz-web-panel.googlecode.com|209.85.225.82|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 5542 (5.4K) [text/plain]
Saving to: `hw-daemon.rb'
100%[======================================>] 5,542 --.-K/s in 0.04s
2011-06-21 10:12:13 (141 KB/s) - `hw-daemon.rb' saved [5542/5542]
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# ls
certs hw-daemon.ini.sample hw-daemon.pid hw-daemon.rb.bak
hw-daemon.ini hw-daemon.log hw-daemon.rb
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon# service owp start
Starting OpenVZ Web Panel
Starting watchdog daemon...
=> Booting WEBrick...
=> Rails 2.2.2 application started on http://0.0.0.0:3000
[2011-06-21 10:12:22] INFO WEBrick 1.3.1
[2011-06-21 10:12:22] INFO ruby 1.8.7 (2010-01-10) [x86_64-linux]
Starting the daemon...
/usr/lib/ruby/1.8/webrick/utils.rb:73:in `initialize': Address already in use -
bind(2) (Errno::EADDRINUSE)
from /usr/lib/ruby/1.8/webrick/utils.rb:73:in `new'
from /usr/lib/ruby/1.8/webrick/utils.rb:73:in `create_listeners'
from /usr/lib/ruby/1.8/webrick/utils.rb:70:in `each'
from /usr/lib/ruby/1.8/webrick/utils.rb:70:in `create_listeners'
from /usr/lib/ruby/1.8/webrick/server.rb:75:in `listen'
from /usr/lib/ruby/1.8/webrick/server.rb:63:in `initialize'
from /usr/lib/ruby/1.8/webrick/httpserver.rb:24:in `initialize'
from /opt/ovz-web-panel//utils/hw-daemon/hw-daemon.rb:151:in `new'
from /opt/ovz-web-panel//utils/hw-daemon/hw-daemon.rb:151:in `do_start'
from /opt/ovz-web-panel//utils/hw-daemon/hw-daemon.rb:118:in `initialize'
from /opt/ovz-web-panel//utils/hw-daemon/hw-daemon.rb:237:in `new'
from /opt/ovz-web-panel//utils/hw-daemon/hw-daemon.rb:237
Syncing physical servers state...
/opt/ovz-web-panel/vendor/rails/railties/lib/commands/runner.rb:47:
/opt/ovz-web-panel/lib/hw_daemon_client.rb:48:in `exec': Command 'vzctl
--version ' execution failed with code 127 (HwDaemonExecException)
Output: sh: vzctl: command not found
from /opt/ovz-web-panel/app/models/hardware_server.rb:220:in `sync_server_info'
from /opt/ovz-web-panel/app/models/hardware_server.rb:231:in `sync'
from (eval):1
from (eval):1:in `each'
from (eval):1
from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `eval'
from /opt/ovz-web-panel/vendor/rails/railties/lib/commands/runner.rb:47
from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'
from /opt/ovz-web-panel//script/runner:3
root@birmingham-new:/opt/ovz-web-panel/utils/hw-daemon#
Original comment by nshe...@gmail.com
on 21 Jun 2011 at 2:13
Daemon not dying on your machine. Do service owp stop. Then "ps auxww | grep
ruby" Then kill ruby processes. To force killing you can use kill -9 Or you can
simply reboot the machine.
Original comment by sibprogrammer
on 21 Jun 2011 at 2:49
We have puppet running on some of the VMs, which apparently also uses ruby, so
just to be clear, just kill anything owned by root, not anything else, correct?
the only entry I have now is:
root 31609 0.0 0.0 89648 2296 ? Sl Jun16 0:00
/usr/lib/phusion_passenger/ApplicationPoolServerExecutable 0
/usr/lib/phusion_passenger/passenger-spawn-server /usr/bin/ruby
/tmp/passenger.24698
Original comment by nshe...@gmail.com
on 21 Jun 2011 at 2:53
Kill ruby proccess for hw-daemon.rb. Check it twice before restart that process
is dead. If you still have questions, reboot server first.
Original comment by sibprogrammer
on 21 Jun 2011 at 3:04
Works, thanks for your help.
Original comment by nshe...@gmail.com
on 21 Jun 2011 at 4:22
Original issue reported on code.google.com by
nshe...@gmail.com
on 16 Jun 2011 at 7:35