jamesyonan / brenda

Blender render farm software for Amazon Web Services
Other
246 stars 67 forks source link

Error after executing brenda-tool ssh uptime #7

Closed dalekurt closed 10 years ago

dalekurt commented 10 years ago

I have brenda running on an AWS Ec2 instance (Amazon Linux AMI). I executed the command brenda-tool ssh uptime and got the following:

$brenda-tool ssh uptime Exception in thread Thread-1: Traceback (most recent call last): File "/usr/lib64/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/usr/lib64/python2.6/site-packages/brenda/tool.py", line 61, in worker output = utils.system_return_output(cmd, capture_stderr=capture_stderr) File "/usr/lib64/python2.6/site-packages/brenda/utils.py", line 116, in system_return_output output = subprocess.check_output(cmd, stderr=subprocess.STDOUT) AttributeError: 'module' object has no attribute 'check_output'

Exception in thread Thread-2: Traceback (most recent call last): File "/usr/lib64/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/usr/lib64/python2.6/site-packages/brenda/tool.py", line 61, in worker output = utils.system_return_output(cmd, capture_stderr=capture_stderr) File "/usr/lib64/python2.6/site-packages/brenda/utils.py", line 116, in system_return_output output = subprocess.check_output(cmd, stderr=subprocess.STDOUT) AttributeError: 'module' object has no attribute 'check_output'

Exception in thread Thread-3: Traceback (most recent call last): File "/usr/lib64/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/usr/lib64/python2.6/site-packages/brenda/tool.py", line 61, in worker output = utils.system_return_output(cmd, capture_stderr=capture_stderr) File "/usr/lib64/python2.6/site-packages/brenda/utils.py", line 116, in system_return_output output = subprocess.check_output(cmd, stderr=subprocess.STDOUT) AttributeError: 'module' object has no attribute 'check_output'

Exception in thread Thread-4: Traceback (most recent call last): File "/usr/lib64/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/usr/lib64/python2.6/site-packages/brenda/tool.py", line 61, in worker output = utils.system_return_output(cmd, capture_stderr=capture_stderr) File "/usr/lib64/python2.6/site-packages/brenda/utils.py", line 116, in system_return_output output = subprocess.check_output(cmd, stderr=subprocess.STDOUT) AttributeError: 'module' object has no attribute 'check_output'

Exception in thread Thread-5: Traceback (most recent call last): File "/usr/lib64/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/usr/lib64/python2.6/site-packages/brenda/tool.py", line 61, in worker output = utils.system_return_output(cmd, capture_stderr=capture_stderr) File "/usr/lib64/python2.6/site-packages/brenda/utils.py", line 116, in system_return_output output = subprocess.check_output(cmd, stderr=subprocess.STDOUT) AttributeError: 'module' object has no attribute 'check_output'

Exception in thread Thread-6: Traceback (most recent call last): File "/usr/lib64/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/usr/lib64/python2.6/site-packages/brenda/tool.py", line 61, in worker output = utils.system_return_output(cmd, capture_stderr=capture_stderr) File "/usr/lib64/python2.6/site-packages/brenda/utils.py", line 116, in system_return_output output = subprocess.check_output(cmd, stderr=subprocess.STDOUT) AttributeError: 'module' object has no attribute 'check_output'

Exception in thread Thread-7: Traceback (most recent call last): File "/usr/lib64/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/usr/lib64/python2.6/site-packages/brenda/tool.py", line 61, in worker output = utils.system_return_output(cmd, capture_stderr=capture_stderr) File "/usr/lib64/python2.6/site-packages/brenda/utils.py", line 116, in system_return_output output = subprocess.check_output(cmd, stderr=subprocess.STDOUT) AttributeError: 'module' object has no attribute 'check_output'

Exception in thread Thread-8: Traceback (most recent call last): File "/usr/lib64/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/usr/lib64/python2.6/site-packages/brenda/tool.py", line 61, in worker output = utils.system_return_output(cmd, capture_stderr=capture_stderr) File "/usr/lib64/python2.6/site-packages/brenda/utils.py", line 116, in system_return_output output = subprocess.check_output(cmd, stderr=subprocess.STDOUT) AttributeError: 'module' object has no attribute 'check_output'

jamesyonan commented 10 years ago

I think the problem is that the AMI you are using has Python 2.6 installed, but 2.7 is required by Brenda because the check_output method of subprocess was only added in Python 2.7. I would advise to use the standard Brenda AMI, as it is known to have the correct versions of dependencies.

James

dalekurt commented 10 years ago

Okay, I have an EC2 instance which is the render farm manager. It currently has python 2.6.9 installed on the instance. The instance was launched using the Amazon Linux AMI (t1.micro). I will update python to version 2.7.

What is the AMI ID for the standard brenda AMI?

My plan is to build a web interface for brenda, so this instance will be the render farm manager and host for the web app.

dalekurt commented 10 years ago

Thanks James, I'm now using the AMI brenda-0.5.3 (ami-0529086c) for launching the render farm manager.

I'm getting the following error when executing brenda-run status

$ brenda-run status Active Instances ami-0529086c 0:25:20 ec2-54-86-89-XXX.compute-1.amazonaws.com ami-0529086c 0:00:40 ec2-54-86-47-XXX.compute-1.amazonaws.com ami-0529086c 0:00:40 ec2-54-86-5-XXX.compute-1.amazonaws.com Spot Requests Traceback (most recent call last): File "/usr/local/bin/brenda-run", line 169, in main() File "/usr/local/bin/brenda-run", line 158, in main run.status(opts, conf) File "/usr/local/lib/python2.7/dist-packages/brenda/run.py", line 146, in status print " %s %s %s %s $%s %s %s" % (r.id, r.region, r.type, r.create_time, r.price, r.state, r.status) AttributeError: 'SpotInstanceRequest' object has no attribute 'status'

dalekurt commented 10 years ago

The EC2 instance (manager) that I launched based on the AMI ami-0529086c get terminated along with the other spot instance when I execute brenda-run -T stop

How may I prevent this other than building my own AMI from scratch?

dalekurt commented 10 years ago

I've launched a new AMI (ami-018c9568) and provisioned it for brenda. This EC2 instance has python 2.7 as required by brenda.

Install Dependencies $ sudo apt-get update $ sudo apt-get install git s3cmd python-boto python-dev libcurl4-gnutls-dev

Install Brenda $ git clone http://github.com/jamesyonan/brenda.git $ cd brenda $ sudo python setup.py install

Thanks!