Hive installation fails on Hadoop 2.7.3 through amabari - python-2.7

I am trying to install hive on hadoop 2.7.2 with hdp 2.5. My ambari version is 2.4. Every other component is working fine (HDFS,YARN, MR2, ZOOKEEPER etc.).
When i am trying to install hive with new MySql database through ambari UI it give me following error for HCat client installation:
Traceback (most recent call last): File "/var/lib/ambari-agent/cache/common-services/HIVE/0.12.0.2.0/package/scripts/hcat_client.py", line 85, in <module>
HCatClient().execute() File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 280, in execute
method(env) File "/var/lib/ambari-agent/cache/common-services/HIVE/0.12.0.2.0/package/scripts/hcat_client.py", line 35, in install
self.install_packages(env) File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 567, in install_packages
retry_count=agent_stack_retry_count) File "/usr/lib/python2.6/site-packages/resource_management/core/base.py", line 155, in __init__
self.env.run() File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 160, in run
self.run_action(resource, action) File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 124, in run_action
provider_action() File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 54, in action_install
self.install_package(package_name, self.resource.use_repos, self.resource.skip_repos) File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/yumrpm.py", line 49, in install_package
self.checked_call_with_retries(cmd, sudo=True, logoutput=self.get_logoutput()) File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 83, in checked_call_with_retries
return self._call_with_retries(cmd, is_checked=True, **kwargs) File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 91, in _call_with_retries
code, out = func(cmd, **kwargs) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 71, in inner
result = function(command, **kwargs) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 93, in checked_call
tries=tries, try_sleep=try_sleep) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 141, in _call_wrapper
result = _call(command, **kwargs_copy) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 294, in _call
raise Fail(err_msg) resource_management.core.exceptions.Fail: Execution of '/usr/bin/yum -d 0 -e 0 -y install hive_2_5_0_0_1245' returned 1. Error unpacking rpm package hive_2_5_0_0_1245-1.2.1000.2.5.0.0-1245.el6.noarch error: unpacking of archive failed on file /usr/hdp/2.5.0.0-1245/hive/conf: cpio: rename failed - Is a directory

Related

cannot install packages through pip

Python: 2.7.12
Pip: 8.1.1
When I sudo pip install pandas, it shows as follows:
Exception:
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 209, in main
status = self.run(options, args)
File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 317, in run
requirement_set.prepare_files(finder)
File "/usr/lib/python2.7/dist-packages/pip/req/req_set.py", line 360, in prepare_files
ignore_dependencies=self.ignore_dependencies))
File "/usr/lib/python2.7/dist-packages/pip/req/req_set.py", line 512, in _prepare_file
finder, self.upgrade, require_hashes)
File "/usr/lib/python2.7/dist-packages/pip/req/req_install.py", line 273, in populate_link
self.link = finder.find_requirement(self, upgrade)
File "/usr/lib/python2.7/dist-packages/pip/index.py", line 442, in find_requirement
all_candidates = self.find_all_candidates(req.name)
File "/usr/lib/python2.7/dist-packages/pip/index.py", line 400, in find_all_candidates
for page in self._get_pages(url_locations, project_name):
File "/usr/lib/python2.7/dist-packages/pip/index.py", line 545, in _get_pages
page = self._get_page(location)
File "/usr/lib/python2.7/dist-packages/pip/index.py", line 648, in _get_page
return HTMLPage.get_page(link, session=self.session)
File "/usr/lib/python2.7/dist-packages/pip/index.py", line 757, in get_page
"Cache-Control": "max-age=600",
File "/usr/share/python-wheels/requests-2.9.1-py2.py3-none-any.whl/requests/sessions.py", line 480, in get
return self.request('GET', url, **kwargs)
File "/usr/lib/python2.7/dist-packages/pip/download.py", line 378, in request
return super(PipSession, self).request(method, url, *args, **kwargs)
File "/usr/share/python-wheels/requests-2.9.1-py2.py3-none-any.whl/requests/sessions.py", line 468, in request
resp = self.send(prep, **send_kwargs)
File "/usr/share/python-wheels/requests-2.9.1-py2.py3-none-any.whl/requests/sessions.py", line 576, in send
r = adapter.send(request, **kwargs)
File "/usr/share/python-wheels/CacheControl-0.11.5-py2.py3-none-any.whl/cachecontrol/adapter.py", line 46, in send
resp = super(CacheControlAdapter, self).send(request, **kw)
File "/usr/share/python-wheels/requests-2.9.1-py2.py3-none-any.whl/requests/adapters.py", line 376, in send
timeout=timeout
File "/usr/share/python-wheels/urllib3-1.13.1-py2.py3-none-any.whl/urllib3/connectionpool.py", line 610, in urlopen
_stacktrace=sys.exc_info()[2])
File "/usr/share/python-wheels/urllib3-1.13.1-py2.py3-none-any.whl/urllib3/util/retry.py", line 228, in increment
total -= 1
TypeError: unsupported operand type(s) for -=: 'Retry' and 'int'
download .whl file for pandas
try
pip install pandas.whl
or upgrade or pip and repeat the command
pip install pandas
I think there is some problem with pip command. So you can install Anaconda for python 2.7 (Download). It comes with pip by default.
Once download will be completed (it is script file).
Give the permission to the script file.
sudo chmod 777 Anaconda2-5.1.0-Linux-x86_64.sh
Run the script file on terminal../Anaconda2-5.1.0-Linux-x86_64.sh or bash Anaconda2-5.1.0-Linux-x86_64.sh
Follow the instruction from point 4th to this document here

Cannot start RIDE.py in ubuntu after the installation

Could you please help to solve this problem.
I have installed Python2.7, Selenium2Library, WXPython; Robot Framework...
when I want to start the Ride I got the following error.
:~$ ride.py
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/robotide/__init__.py", line 74, in main
_run(inpath, not noupdatecheck, debug_console)
File "/usr/local/lib/python2.7/dist-packages/robotide/__init__.py", line 100, in _run
ride = RIDE(inpath, updatecheck)
File "/usr/local/lib/python2.7/dist-packages/robotide/application/application.py", line 42, in __init__
wx.App.__init__(self, redirect=False)
File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk2/wx/_core.py", line 8628, in __init__
self._BootstrapApp()
File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk2/wx/_core.py", line 8196, in _BootstrapApp
return _core_.PyApp__BootstrapApp(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/robotide/application/application.py", line 47, in OnInit
self.settings = RideSettings()
File "/usr/local/lib/python2.7/dist-packages/robotide/preferences/settings.py", line 316, in __init__
user_path = initialize_settings(default_path)
File "/usr/local/lib/python2.7/dist-packages/robotide/preferences/settings.py", line 29, in initialize_settings
SETTINGS_DIRECTORY, path, dest_file_name)
File "/usr/local/lib/python2.7/dist-packages/robotide/preferences/settings.py", line 46, in _copy_or_migrate_user_settings
SettingsMigrator(source_path, settings_path).migrate()
File "/usr/local/lib/python2.7/dist-packages/robotide/preferences/settings.py", line 94, in migrate
self.merge()
File "/usr/local/lib/python2.7/dist-packages/robotide/preferences/settings.py", line 98, in merge
self._write_merged_settings(self._default_settings, self._user_path)
File "/usr/local/lib/python2.7/dist-packages/robotide/preferences/settings.py", line 186, in _write_merged_settings
'Could not open settings file "%s" for writing' % path)
RuntimeError: Could not open settings file "/home/said/.robotframework/ride/settings.cfg" for writing
The error message is clear:
RuntimeError: Could not open settings file "/home/said/.robotframework/ride/settings.cfg" for writing
Possible solutions:
cd ; pwd ;
/home/said
rm -rf .robotframework
or
sudo chown -R said:said .robotframework

aws no credentials error

I am trying to setup dynamic thumbnail service thumbor and to support s3 as storage, I need to setup this community powered pip library for aws.
Its working well on my local environment but when I am trying to host it on one of our servers, I am getting NoCredentialsError. I am assuming this is because of difference versions of botocore (latest one and one installed by pip library). Here is error log:
File "/usr/local/lib/python2.7/dist-packages/botocore/session.py", line 774, in get_component
# client config from the session
File "/usr/local/lib/python2.7/dist-packages/botocore/session.py", line 174, in <lambda>
self._components.lazy_register_component(
File "/usr/local/lib/python2.7/dist-packages/botocore/session.py", line 453, in get_data
- agent_version is the value of the `user_agent_version`
File "/usr/local/lib/python2.7/dist-packages/botocore/loaders.py", line 119, in _wrapper
data = func(self, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/botocore/loaders.py", line 364, in load_data
DataNotFoundError: Unable to load data for: _endpoints
2016-04-24 12:14:34 tornado.application:ERROR Future exception was never retrieved: Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/tornado/gen.py", line 230, in wrapper
yielded = next(result)
File "/usr/local/lib/python2.7/dist-packages/thumbor/handlers/imaging.py", line 31, in check_image
exists = yield gen.maybe_future(self.context.modules.storage.exists(kw['image'][:self.context.config.MAX_ID_LENGTH]))
File "/usr/local/lib/python2.7/dist-packages/tornado/concurrent.py", line 455, in wrapper
future.result()
File "/usr/local/lib/python2.7/dist-packages/tornado/concurrent.py", line 215, in result
raise_exc_info(self._exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornado/concurrent.py", line 443, in wrapper
result = f(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/tc_aws/aws/storage.py", line 107, in exists
self.storage.get(file_abspath, callback=return_data)
File "/usr/local/lib/python2.7/dist-packages/tornado/concurrent.py", line 455, in wrapper
future.result()
File "/usr/local/lib/python2.7/dist-packages/tornado/concurrent.py", line 215, in result
raise_exc_info(self._exc_info)
File "/usr/local/lib/python2.7/dist-packages/tornado/concurrent.py", line 443, in wrapper
result = f(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/tc_aws/aws/bucket.py", line 44, in get
Key=self._clean_key(path),
File "/usr/local/lib/python2.7/dist-packages/tornado_botocore/base.py", line 97, in call
return self._make_api_call(operation_name=self.operation, api_params=kwargs, callback=callback)
File "/usr/local/lib/python2.7/dist-packages/tornado_botocore/base.py", line 60, in _make_api_call
operation_model=operation_model, request_dict=request_dict, callback=callback)
File "/usr/local/lib/python2.7/dist-packages/tornado_botocore/base.py", line 54, in _make_request
request_dict=request_dict, operation_model=operation_model, callback=callback)
File "/usr/local/lib/python2.7/dist-packages/tornado_botocore/base.py", line 32, in _send_request
request = self.endpoint.create_request(request_dict, operation_model)
File "/usr/local/lib/python2.7/dist-packages/botocore/endpoint.py", line 126, in create_request
operation_name=operation_model.name)
File "/usr/local/lib/python2.7/dist-packages/botocore/hooks.py", line 226, in emit
return self._emit(event_name, kwargs)
File "/usr/local/lib/python2.7/dist-packages/botocore/hooks.py", line 209, in _emit
response = handler(**kwargs)
File "/usr/local/lib/python2.7/dist-packages/botocore/signers.py", line 90, in handler
return self.sign(operation_name, request)
File "/usr/local/lib/python2.7/dist-packages/botocore/signers.py", line 124, in sign
signer.add_auth(request=request)
File "/usr/local/lib/python2.7/dist-packages/botocore/auth.py", line 626, in add_auth
raise NoCredentialsError
NoCredentialsError: Unable to locate credentials
Could it be fixed with proper ordering in which I install libraries? Because the pip library removes existing newer version of botocore and installs an older version.
EDIT:
I am running processes with supervisor and it seems process cant access aws credentials
EDIT 2:
The issue got resolved with proper configuration of supervisor. The user for process started by supervisor did not have access to config file
The issue got resolved with proper configuration of supervisor. The user for subprocess started by supervisor did not have access to aws config file. So it was working with local environment or creating process separately but not with supervisor.

Error when starting Jupyter Notebook (iPython)

I am running Python 2.7 and have installed Jupyter Notebook using pip install.
When I try to launch the notebook from the command line by typing in
jupyter notebook
I get the following error message:
Traceback (most recent call last):
File "C:\Python27\lib\runpy.py", line 162, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "C:\Python27\lib\runpy.py", line 72, in _run_code
exec code in run_globals
File "C:\Python27\scripts\jupyter-notebook.exe\__main__.py", line 9, in <modul
e>
File "C:\Python27\lib\site-packages\jupyter_core\application.py", line 267, in
launch_instance
return super(JupyterApp, cls).launch_instance(argv=argv, **kwargs)
File "C:\Python27\lib\site-packages\traitlets\config\application.py", line 591
, in launch_instance
app.initialize(argv)
File "<decorator-gen-7>", line 2, in initialize
File "C:\Python27\lib\site-packages\traitlets\config\application.py", line 75,
in catch_config_error
return method(app, *args, **kwargs)
File "C:\Python27\lib\site-packages\notebook\notebookapp.py", line 1017, in in
itialize
super(NotebookApp, self).initialize(argv)
File "<decorator-gen-6>", line 2, in initialize
File "C:\Python27\lib\site-packages\traitlets\config\application.py", line 75,
in catch_config_error
return method(app, *args, **kwargs)
File "C:\Python27\lib\site-packages\jupyter_core\application.py", line 243, in
initialize
self.migrate_config()
File "C:\Python27\lib\site-packages\jupyter_core\application.py", line 169, in
migrate_config
migrate()
File "C:\Python27\lib\site-packages\jupyter_core\migrate.py", line 227, in mig
rate
if migrate_config(name, env):
File "C:\Python27\lib\site-packages\jupyter_core\migrate.py", line 200, in mig
rate_config
cfg = loaders[ext](src).load_config()
File "C:\Python27\lib\site-packages\traitlets\config\loader.py", line 432, in
load_config
self._read_file_as_dict()
File "C:\Python27\lib\site-packages\traitlets\config\loader.py", line 464, in
_read_file_as_dict
py3compat.execfile(conf_filename, namespace)
File "C:\Python27\lib\site-packages\ipython_genutils\py3compat.py", line 278,
in execfile
exec(compiler(scripttext, filename, 'exec'), glob, loc)
File "C:\Users\Stuart\.ipython\profile_default\ipython_notebook_config.py", li
ne 102
c.NotebookApp.notebook_dir = u'C:\Users\Stuart\Documents\iPython'
^
IndentationError: unexpected indent
I can run
jupyter notebook --help
without issue so I am not sure whether it is installed incorrectly or there is some other reason why it is not running.
Could someone please suggest why I may be receiving this error message and how I can run the notebook properly?

How to install neo4django in virtual environment

I receive the error below when trying to install neo4django in my virtual environment. Not sure what the problem is. The server is running on my machine and py2neo works with the restful api, but not neo4django.
I'm running ubuntu 12.0.4 with the latest version of neo4j installed (1.9-M01) and jdk 1.7 (openjkd) installed with JAVA_HOME pointing to: /usr/lib/jvm/java-7-openjdk-amd64
Traceback (most recent call last): File "manage.py", line 10, in
execute_from_command_line(sys.argv) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/django/core/management/init.py",
line 443, in execute_from_command_line
utility.execute() File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/django/core/management/init.py",
line 382, in execute
self.fetch_command(subcommand).run_from_argv(self.argv) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/django/core/management/base.py",
line 196, in run_from_argv
self.execute(*args, **options.dict) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/django/core/management/base.py",
line 232, in execute
output = self.handle(*args, **options) File "/home/alan/workspace/neowiki/neowiki/nodes/management/commands/testcmd.py",
line 10, in handle
pete = Person.objects.create(name='Pete') File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/db/models/manager.py",
line 41, in create
return self.get_query_set().create(*kwargs) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/db/models/query.py",
line 747, in create
return super(NodeQuerySet, self).create(*kwargs) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/django/db/models/query.py",
line 377, in create
obj.save(force_insert=True, using=self.db) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/db/models/base.py",
line 325, in save
return super(NodeModel, self).save(using=using, **kwargs) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/django/db/models/base.py",
line 463, in save
self.save_base(using=using, force_insert=force_insert, force_update=force_update) File
"/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/db/models/base.py",
line 340, in save_base
self._save_neo4j_node(using) File "", line 2, in _save_neo4j_node File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/db/models/base.py",
line 115, in trans_method
ret = func(*args, **kw) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/db/models/base.py",
line 370, in _save_neo4j_node
typesToIndex=type_names_to_index) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/neo4jclient.py",
line 179, in gremlin_tx
return self.gremlin(script, tx=True, **params) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/neo4jclient.py",
line 168, in gremlin
params) File "/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4django/neo4jclient.py",
line 153, in send_script
script_rv = ext.execute_script(s, params=params, **execute_kwargs) File
"/home/alan/workspace/neowiki/venv/local/lib/python2.7/site-packages/neo4jrestclient/client.py",
line 1960, in call
raise StatusException(response.status, msg) neo4jrestclient.request.StatusException: Error [400]: Bad Request. Bad
request syntax or unsupported method. Invalid data sent:
org.codehaus.groovy.control.MultipleCompilationErrorsException:
startup failed: Script4.groovy: 94: unable to resolve class
org.neo4j.cypher.javacompat.CypherParser # line 94, column 1.
import org.neo4j.cypher.javacompat.CypherParser ^
1 error
My requirements.txt includes:
-e git://github.com/scholrly/neo4django.git#eefdf6a122fdbe26c62b6563f9ff6b30a4de2f93#egg=neo4django-dev
neo4jrestclient==1.7.0
Any help is greatly appreciated!
From what I can see, your installation is fine. The problem is the version of Neo4j.
So far, we only support Neo4j 1.6-1.8. While I try to support all major releases in use, I typically extend support for milestones closer to a general release. For example, I didn't extend support to Neo4j 1.8 until it hit milestone 6.
Is there a particular reason you're using 1.9M01, or would the most recent stable release (1.8GA) suffice?