I am using podman-compose instead of docker-compose.
My docker-compose.yml had no problems when using docker-compose, but it makes an error with podman-compose.
docker-compose.yml:
version: "3.9"
services:
mysql:
image: docker.io/mysql
container_name: mysql
hostname: mysql
volumes:
- D:\mysql\test\data:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: "password"
MYSQL_TCP_PORT: 8026
ports:
- "8026:8026"
When podman-compose up:
['podman', '--version', '']
using podman version: 4.3.1
** excluding: set()
Traceback (most recent call last):
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\Scripts\podman-compose.exe\__main__.py", line 7, in <module>
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\site-packages\podman_compose.py", line 1775, in main
podman_compose.run()
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\site-packages\podman_compose.py", line 1024, in run
cmd(self, args)
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\site-packages\podman_compose.py", line 1248, in wrapped
return func(*args, **kw)
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\site-packages\podman_compose.py", line 1415, in compose_up
podman_args = container_to_args(compose, cnt, detached=args.detach)
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\site-packages\podman_compose.py", line 644, in container_to_args
podman_args.extend(get_mount_args(compose, cnt, volume))
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\site-packages\podman_compose.py", line 399, in get_mount_args
if is_str(volume): volume = parse_short_mount(volume, basedir)
File "C:\Users\ymy\AppData\Local\Programs\Python\Python310\lib\site-packages\podman_compose.py", line 129, in parse_short_mount
raise ValueError("unknown mount option "+opt)
ValueError: unknown mount option /var/lib/mysql
I think that it read colon(:) at Windows drive(D:) as delimeter so the last field /var/lib/mysql is read as options like ro, rw. But I don't know how I can solve this.
This page (https://github.com/containers/podman/blob/main/docs/tutorials/podman-for-windows.md) gives a definition for 'Unixy' Windows paths. my references then went from:
d:/path
to
/d/path
Have a look and let us know how you get on
Related
I have installed Odoo 12 in Ubuntu 18.04 LTS using WSL for windows 10 Pro.
Everything seems fine and service is running, but when I access the localhost I get Internal Server Error, and I get this error:
2019-09-05 06:52:07,596 309 ERROR ? werkzeug: Error on request:
Traceback (most recent call last):
File "/opt/odoo/.local/lib/python3.6/site-packages/werkzeug/serving.py", line 303, in run_wsgi
execute(self.server.app)
File "/opt/odoo/.local/lib/python3.6/site-packages/werkzeug/serving.py", line 291, in execute
application_iter = app(environ, start_response)
File "/opt/odoo/odoo/odoo/service/server.py", line 409, in app
return self.app(e, s)
File "/opt/odoo/odoo/odoo/service/wsgi_server.py", line 128, in application
return application_unproxied(environ, start_response)
File "/opt/odoo/odoo/odoo/service/wsgi_server.py", line 117, in application_unproxied
result = odoo.http.root(environ, start_response)
File "/opt/odoo/odoo/odoo/http.py", line 1320, in __call__
return self.dispatch(environ, start_response)
File "/opt/odoo/odoo/odoo/http.py", line 1293, in __call__
return self.app(environ, start_wrapped)
File "/opt/odoo/.local/lib/python3.6/site-packages/werkzeug/middleware/shared_data.py", line 220, in __call__
return self.app(environ, start_response)
File "/opt/odoo/odoo/odoo/http.py", line 1453, in dispatch
self.setup_db(httprequest)
File "/opt/odoo/odoo/odoo/http.py", line 1376, in setup_db
httprequest.session.db = db_monodb(httprequest)
File "/opt/odoo/odoo/odoo/http.py", line 1537, in db_monodb
dbs = db_list(True, httprequest)
File "/opt/odoo/odoo/odoo/http.py", line 1504, in db_list
dbs = odoo.service.db.list_dbs(force)
File "/opt/odoo/odoo/odoo/service/db.py", line 375, in list_dbs
with closing(db.cursor()) as cr:
File "/opt/odoo/odoo/odoo/sql_db.py", line 657, in cursor
return Cursor(self.__pool, self.dbname, self.dsn, serialized=serialized)
File "/opt/odoo/odoo/odoo/sql_db.py", line 171, in __init__
self._cnx = pool.borrow(dsn)
File "/opt/odoo/odoo/odoo/sql_db.py", line 540, in _locked
return fun(self, *args, **kwargs)
File "/opt/odoo/odoo/odoo/sql_db.py", line 608, in borrow
**connection_info)
File "/opt/odoo/.local/lib/python3.6/site-packages/psycopg2/__init__.py", line 126, in connect
conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
psycopg2.OperationalError: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"? - - -
PostgreSQL is installed using port 5433:
Ver Cluster Port Status Owner Data directory Log file
10 main 5433 online postgres /var/lib/postgresql/10/main /var/log/postgresql/postgresql-10-main.log
I changed the port in the conf file \etc\odoo-server.conf from False to 5433:
[options]
; This is the password that allows database operations:
; admin_passwd = admin
db_host = False
db_port = 5433
db_user = odoo
db_password = False
logfile = /var/log/odoo/odoo-server.log
addons_path = /opt/odoo/addons,/opt/odoo/odoo/addons
However, I get the same error. Seems Psycopg2 take the value as default port 5432 even I specified it in the .conf file.
Any help?
Thanks
Your distribution (like mine) probably makes the key in the /tmp directory.
A quick workaround I've been using is:
mkdir /var/run/postgresql
ln -s /tmp/.s.PGSQL.5432(or 5433) /var/run/postgresql/
I can't initialize my db on Ckan. I try to install Ckan 2.8 on ubuntu 16.04 and postgres 9.6 and I followed the instruction on the oficial page.
All is good but when I try to initialize my db, I can't.
This is the error.
Traceback (most recent call last):
File "/usr/lib/ckan/default/bin/paster", line 11, in <module>
sys.exit(run())
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 102, in run
invoke(command, command_name, options, args[1:])
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 141, in invoke
exit_code = runner.run(args)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 236, in run
result = self.command()
File "/usr/lib/ckan/default/src/ckan/ckan/lib/cli.py", line 363, in command
model.repo.init_db()
File "/usr/lib/ckan/default/src/ckan/ckan/model/__init__.py", line 188, in init_db
self.upgrade_db()
File "/usr/lib/ckan/default/src/ckan/ckan/model/__init__.py", line 266, in upgrade_db
mig.upgrade(self.metadata.bind, self.migrate_repository, version=version)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/migrate/versioning/api.py", line 186, in upgrade
return _migrate(url, repository, version, upgrade=True, err=err, **opts)
File "<decorator-gen-16>", line 2, in _migrate
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/migrate/versioning/util/__init__.py", line 160, in with_engine
return f(*a, **kw)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/migrate/versioning/api.py", line 366, in _migrate
schema.runchange(ver, change, changeset.step)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/migrate/versioning/schema.py", line 93, in runchange
change.run(self.engine, step)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/migrate/versioning/script/py.py", line 148, in run
script_func(engine)
File "/usr/lib/ckan/default/src/ckan/ckan/migration/versions/016_uuids_everywhere.py", line 69, in upgrade
drop_sequencies(migrate_engine)
File "/usr/lib/ckan/default/src/ckan/ckan/migration/versions/016_uuids_everywhere.py", line 186, in drop_sequencies
migrate_engine.execute('drop sequence %s_id_seq;' % sequence)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 2064, in execute
return connection.execute(statement, *multiparams, **params)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 939, in execute
return self._execute_text(object, multiparams, params)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1097, in _execute_text
statement, parameters
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1189, in _execute_context
context)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1402, in _handle_dbapi_exception
exc_info
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/sqlalchemy/util/compat.py", line 203, in raise_from_cause
reraise(type(exception), exception, tb=exc_tb, cause=cause)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1182, in _execute_context
context)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/sqlalchemy/engine/default.py", line 470, in do_execute
cursor.execute(statement, parameters)
sqlalchemy.exc.ProgrammingError: (psycopg2.ProgrammingError) no existe la secuencia «package_extra_revision_id_seq»
[SQL: 'drop sequence package_extra_revision_id_seq;']
I try to run:
paster db init -c /etc/ckan/default/production.ini
sudo ckan db init
I checked my db while the script was running and script created the sequence "package_extra_revision_id_seq" correctly. But when the script finishes the sequence "package_extra_revision_id_seq" no longer exists.
"CKAN 2.8 installing from source" paster db init is broken and not reported, so it won't work in anyway. Solution is to install CKAN 2.7 instead as dependencies are different and working.
https://docs.ckan.org/en/2.7/
Once installed, paster command for init database works
I'm using odoo 11 on localhost and recently i did database restore from
PgAdmin 4 and from there it completed successfully. But when i chose it from odoo login screen the screen get blank and not responds. find pic attached.
I tried this to reset javascript in the browser
localhost:8069/web?debug=
but still not working.
Here are the logs:
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Odoo 11.0\server\odoo\addons\base\ir\ir_cron.py", line 92, in _callback
self.env['ir.actions.server'].browse(server_action_id).run()
File "C:\Odoo 11.0\server\odoo\addons\base\ir\ir_actions.py", line 536, in run
res = func(action, eval_context=eval_context)
File "C:\Odoo 11.0\server\odoo\addons\base\ir\ir_actions.py", line 417, in run_action_code_multi
safe_eval(action.sudo().code.strip(), eval_context, mode="exec", nocopy=True) # nocopy allows to return 'action'
File "C:\Odoo 11.0\server\odoo\tools\safe_eval.py", line 370, in safe_eval
pycompat.reraise(ValueError, ValueError('%s: "%s" while evaluating\n%r' % (ustr(type(e)), ustr(e), expr)), exc_info[2])
File "C:\Odoo 11.0\server\odoo\tools\pycompat.py", line 85, in reraise
raise value.with_traceback(tb)
File "C:\Odoo 11.0\server\odoo\tools\safe_eval.py", line 347, in safe_eval
return unsafe_eval(c, globals_dict, locals_dict)
File "", line 1, in <module>
File "C:\Odoo 11.0\server\odoo\addons\mail\models\ir_autovacuum.py", line 13, in power_on
return super(AutoVacuum, self).power_on(*args, **kwargs)
File "C:\Odoo 11.0\server\odoo\addons\base\ir\ir_autovacuum.py", line 36, in power_on
self._gc_transient_models()
File "C:\Odoo 11.0\server\odoo\addons\base\ir\ir_autovacuum.py", line 20, in _gc_transient_models
model._transient_vacuum(force=True)
File "C:\Odoo 11.0\server\odoo\models.py", line 4048, in _transient_vacuum
self._transient_clean_rows_older_than(self._transient_max_hours * 60 * 60)
File "C:\Odoo 11.0\server\odoo\models.py", line 4009, in _transient_clean_rows_older_than
self.sudo().browse(ids).unlink()
File "C:\Odoo 11.0\server\odoo\models.py", line 2857, in unlink
cr.execute(query, (sub_ids,))
File "C:\Odoo 11.0\server\odoo\sql_db.py", line 155, in wrapper
return f(self, *args, **kwargs)
File "C:\Odoo 11.0\server\odoo\sql_db.py", line 232, in execute
res = self._obj.execute(query, params)
ValueError: <class 'psycopg2.IntegrityError'>: "null value in column "wizard_id" violates not-null constraint
DETAIL: Failing row contains (1, null, 8, null, null, 1, 2018-01-01 03:32:24.944104, 1, 2018-01-01 03:32:25.077112).
CONTEXT: SQL statement "UPDATE ONLY "public"."change_password_user" SET "wizard_id" = NULL WHERE $1 OPERATOR(pg_catalog.=) "wizard_id""
" while evaluating
'model.power_on()'
I think some method is not found and your odoo source code is old so get the latest code form odoo github: https://github.com/odoo/odoo
and then after in terminal throw update the all module like:
./odoo-bin -d your_database_name --db-filter your_database_name --addons-path your_all_addons_path_name -u all
this is helpfull tip
may be you have some missing files, try to restore also a folder named: filestore
that folder can be found in:
/home/$User/.local/share/Odoo/filestore
replace $User with your ubuntu username
When i am installing ZooKeeper Server on the NameNode with Ambari.It throw:
Traceback (most recent call last):
File "/var/lib/ambari-agent/cache/common-services/ZOOKEEPER/3.4.5.2.0/package/scripts/zookeeper_server.py", line 179, in <module>
ZookeeperServer().execute()
File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 219, in execute
method(env)
File "/var/lib/ambari-agent/cache/common-services/ZOOKEEPER/3.4.5.2.0/package/scripts/zookeeper_server.py", line 70, in install
self.configure(env)
File "/var/lib/ambari-agent/cache/common-services/ZOOKEEPER/3.4.5.2.0/package/scripts/zookeeper_server.py", line 49, in configure
zookeeper(type='server', upgrade_type=upgrade_type)
File "/usr/lib/python2.6/site-packages/ambari_commons/os_family_impl.py", line 89, in thunk
return fn(*args, **kwargs)
File "/var/lib/ambari-agent/cache/common-services/ZOOKEEPER/3.4.5.2.0/package/scripts/zookeeper.py", line 40, in zookeeper
conf_select.select(params.stack_name, "zookeeper", params.current_version)
File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/conf_select.py", line 266, in select
shell.checked_call(get_cmd("set-conf-dir", package, version), logoutput=False, quiet=False, sudo=True)
File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 70, in inner
result = function(command, **kwargs)
File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 92, in checked_call
tries=tries, try_sleep=try_sleep)
File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 140, in _call_wrapper
result = _call(command, **kwargs_copy)
File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 291, in _call
raise Fail(err_msg)
resource_management.core.exceptions.Fail: Execution of 'conf-select set-conf-dir --package zookeeper --stack-version 2.4.3.0-227 --conf-version 0' returned 1. zookeeper not installed or incorrect package name
I am searching from Google,they said "make sure have installed Zookeeper server",and i am installing now(failed).Where is going wrong?How to fix it?
CentOS 7.2,Ambari 2.2.2.0,Zookeeper 3.4.6.2.4,HDP 2.4.3.
i have installed openerp. i have created postgres database. While i open ¨localhost:8060¨ in browser, display the followin error:
Client Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/web/http.py", line 204, in dispatch
response["result"] = method(self, **self.params)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/web/controllers/main.py", line 761, in get_list
monodb = db_monodb(req)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/web/controllers/main.py", line 129, in db_monodb
return db_redirect(req, True)[0]
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/web/controllers/main.py", line 109, in db_redirect
dbs = db_list(req, True)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/web/controllers/main.py", line 90, in db_list
dbs = proxy.list(force)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/web/session.py", line 30, in proxy_method
result = self.session.send(self.service_name, method, *args)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/web/session.py", line 103, in send
raise xmlrpclib.Fault(openerp.tools.ustr(e), formatted_info)
Server Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/web/session.py", line 89, in send
return openerp.netsvc.dispatch_rpc(service_name, method, args)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/netsvc.py", line 292, in dispatch_rpc
result = ExportService.getService(service_name).dispatch(method, params)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/service/web_services.py", line 122, in dispatch
return fn(*params)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/service/web_services.py", line 359, in exp_list
cr = db.cursor()
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/sql_db.py", line 484, in cursor
return Cursor(self._pool, self.dbname, serialized=serialized)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/sql_db.py", line 182, in __init__
self._cnx = pool.borrow(dsn(dbname))
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/sql_db.py", line 377, in _locked
return fun(self, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/sql_db.py", line 440, in borrow
result = psycopg2.connect(dsn=dsn, connection_factory=PsycoConnection)
File "/usr/lib/python2.7/dist-packages/psycopg2/__init__.py", line 179, in connect
connection_factory=connection_factory, async=async)
OperationalError: FATAL: role "bala" does not exist
otherwise i started like following ¨openerp-server start¨, error following like
Traceback (most recent call last):
File "/usr/local/bin/openerp-server", line 5, in <module>
pkg_resources.run_script('openerp==7.0-20140110-002122', 'openerp-server')
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 499, in run_script
self.require(requires)[0].run_script(script_name, ns)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1235, in run_script
execfile(script_filename, namespace, namespace)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/EGG-INFO/scripts/openerp-server", line 5, in <module>
openerp.cli.main()
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/cli/__init__.py", line 51, in main
__import__(m)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/modules/module.py", line 133, in load_module
mod = imp.load_module('openerp.addons.' + module_part, f, path, descr)
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/l10n_si/__init__.py", line 22, in <module>
import account_wizard
File "/usr/local/lib/python2.7/dist-packages/openerp-7.0_20140110_002122-py2.7.egg/openerp/addons/l10n_si/account_wizard.py", line 22, in <module>
import tools
ImportError: No module named tools
Anyone help for error correction. i cannot clear this error even two days i spend for this.
OperationalError: FATAL: role "bala" does not exist
A user that you have told OpenERP to use does not exist in the database. You probably need to create it. I expect you missed one or more installation steps.
Look for a CREATE USER, CREATE ROLE, or createuser command in the instructions.
GRANT commands or a database ownership assignment may also be nececssary depending on what the user is supposed to be able to do.
(It might also be assumed that you'll know to create the user to connect to the DB as).