changing folder names to other languages - error on global "kopano" - python script
-
Hi Karsten
Are you sure the python-kopano package is installed? Please check you have not set a custom PYTHONHOME or PYTHONPATH.
It should be picked by kopano-server-packages. The search and backup programs are relying on this module.
Bo
-
**Hi Bo,
thanks for your reply!
yes, it is installed…root@kopano:/temp1/kopano/core-8.3.0~622_33.1-Ubuntu_16.04-amd64/installiert# apt search python-kopano Sortierung... Fertig Volltextsuche... Fertig python-kopano/now 8.3.0~622-33.1 all [Installiert,lokal] High-level Python bindings for Kopano root@kopano:/temp1/kopano/core-8.3.0~622_33.1-Ubuntu_16.04-amd64/installiert# apt search kopano-server-packages Sortierung... Fertig Volltextsuche... Fertig kopano-server-packages/now 8.3.0~622-33.1 all [Installiert,lokal] Metapackage to install the entire Kopano Core stack
I got empty results by checking pythonhome and pythonpyth.
root@kopano:~# $PYTHONHOME root@kopano:~# $PYTHONPATH root@kopano:~#
Karsten
-
Hi Karsten
Could you help me showing the contents of:
find /usr/ -iname *kopano*
Thanks
Bo
-
Hi Bo
root@kopano:/home/user# find /usr/ -iname *kopano* /usr/include/kopano /usr/bin/kopano-set-oof /usr/bin/kopano-passwd /usr/bin/kopano-stats /usr/bin/kopano-fsck /usr/lib/libgsoapck++-kopano-2.8.40.so /usr/lib/libvmime-kopano.so.1.0.0 /usr/lib/tmpfiles.d/kopano-tmpfiles.conf /usr/lib/debug/usr/bin/kopano-passwd /usr/lib/debug/usr/bin/kopano-stats /usr/lib/debug/usr/bin/kopano-fsck /usr/lib/debug/usr/lib/libgsoapck++-kopano-2.8.40.so /usr/lib/debug/usr/lib/libgsoap-kopano-2.8.40.so /usr/lib/debug/usr/lib/kopano /usr/lib/debug/usr/lib/libgsoapssl++-kopano-2.8.40.so /usr/lib/debug/usr/lib/libgsoapck-kopano-2.8.40.so /usr/lib/debug/usr/lib/libgsoap++-kopano-2.8.40.so /usr/lib/debug/usr/lib/libgsoapssl-kopano-2.8.40.so /usr/lib/debug/usr/libexec/kopano /usr/lib/debug/usr/sbin/kopano-server /usr/lib/debug/usr/sbin/kopano-spooler /usr/lib/debug/usr/sbin/kopano-archiver /usr/lib/debug/usr/sbin/kopano-dagent /usr/lib/debug/usr/sbin/kopano-admin /usr/lib/debug/usr/sbin/kopano-monitor /usr/lib/debug/usr/sbin/kopano-gateway /usr/lib/debug/usr/sbin/kopano-ical /usr/lib/libgsoap-kopano-2.8.40.so /usr/lib/kopano /usr/lib/libgsoapssl++-kopano-2.8.40.so /usr/lib/pkgconfig/kopano.pc /usr/lib/libgsoapck-kopano-2.8.40.so /usr/lib/libvmime-kopano.so.1 /usr/lib/python2.7/dist-packages/kopano_migration_pst /usr/lib/python2.7/dist-packages/kopano_search /usr/lib/python2.7/dist-packages/kopano_presence /usr/lib/python2.7/dist-packages/kopano /usr/lib/python2.7/dist-packages/kopano_backup /usr/lib/python2.7/dist-packages/kopano-0.1.egg-info /usr/lib/libgsoap++-kopano-2.8.40.so /usr/lib/libvmime-kopano.so /usr/lib/libgsoapssl-kopano-2.8.40.so /usr/libexec/kopano /usr/sbin/kopano-server /usr/sbin/kopano-webmeetings /usr/sbin/kopano-spooler /usr/sbin/kopano-search /usr/sbin/kopano-backup /usr/sbin/kopano-dagent /usr/sbin/kopano-mr-process /usr/sbin/kopano-archiver-aclset /usr/sbin/kopano-admin /usr/sbin/kopano-monitor /usr/sbin/kopano-migration-pst /usr/sbin/kopano-search-upgrade-findroots.py /usr/sbin/kopano-mr-accept /usr/sbin/kopano-autorespond /usr/sbin/kopano-archiver-aclsync /usr/sbin/kopano-gateway /usr/sbin/kopano-ical /usr/sbin/kopano-archiver-restore /usr/sbin/kopano-mailbox-permissions /usr/sbin/kopano-presence /usr/sbin/kopano-cachestat /usr/sbin/kopano-search-xapian-compact.py /usr/share/kopano-webmeetings /usr/share/kopano-spooler /usr/share/man/man7/kopano.7.gz /usr/share/man/man1/kopano-stats.1.gz /usr/share/man/man1/kopano-passwd.1.gz /usr/share/man/man1/kopano-set-oof.1.gz /usr/share/man/man1/kopano-fsck.1.gz /usr/share/man/man8/kopano-server.8.gz /usr/share/man/man8/kopano-monitor.8.gz /usr/share/man/man8/kopano-ical.8.gz /usr/share/man/man8/kopano-admin.8.gz /usr/share/man/man8/kopano-migration-pst.8.gz /usr/share/man/man8/kopano-mr-accept.8.gz /usr/share/man/man8/kopano-mailbox-permissions.8.gz /usr/share/man/man8/kopano-spooler.8.gz /usr/share/man/man8/kopano-autorespond.8.gz /usr/share/man/man8/kopano-dagent.8.gz /usr/share/man/man8/kopano-search.8.gz /usr/share/man/man8/kopano-gateway.8.gz /usr/share/man/man8/kopano-backup.8.gz /usr/share/man/man8/kopano-mr-process.8.gz /usr/share/man/man5/kopano-server.cfg.5.gz /usr/share/man/man5/kopano-ical.cfg.5.gz /usr/share/man/man5/kopano-ldap.cfg.5.gz /usr/share/man/man5/kopano-spooler.cfg.5.gz /usr/share/man/man5/kopano-dagent.cfg.5.gz /usr/share/man/man5/kopano-search.cfg.5.gz /usr/share/man/man5/kopano-unix.cfg.5.gz /usr/share/man/man5/kopano-migration-pst.cfg.5.gz /usr/share/man/man5/kopano-backup.cfg.5.gz /usr/share/man/man5/kopano-gateway.cfg.5.gz /usr/share/man/man5/kopano-monitor.cfg.5.gz /usr/share/kopano-dagent /usr/share/doc/kopano-webapp-plugin-spell-de-de /usr/share/doc/kopano-server /usr/share/doc/libgsoap-kopano-2-8-40 /usr/share/doc/kopano-webmeetings /usr/share/doc/kopano-spooler /usr/share/doc/kopano-search /usr/share/doc/kopano-webapp-plugin-contactfax /usr/share/doc/kopano-backup /usr/share/doc/kopano-webapp-plugin-pimfolder /usr/share/doc/kopano-dagent /usr/share/doc/kopano-webapp-plugin-titlecounter /usr/share/doc/kopano-webapp-plugin-gmaps /usr/share/doc/kopano-contacts /usr/share/doc/kopano-monitor /usr/share/doc/kopano-dbg /usr/share/doc/kopano-webapp-plugin-meetings /usr/share/doc/kopano-webapp-plugin-webappmanual /usr/share/doc/libvmime-kopano1 /usr/share/doc/kopano-migration-pst /usr/share/doc/kopano-bash-completion /usr/share/doc/kopano-server-packages /usr/share/doc/kopano-webapp-plugin-spell /usr/share/doc/kopano-webapp /usr/share/doc/kopano /usr/share/doc/kopano/example-config/kopano.inf /usr/share/doc/kopano/kopano.ldif.gz /usr/share/doc/kopano/kopano.schema.gz /usr/share/doc/kopano-gateway /usr/share/doc/kopano-ical /usr/share/doc/libgsoap-kopano-dbg /usr/share/doc/kopano-dev /usr/share/doc/kopano-client /usr/share/doc/kopano-utils /usr/share/doc/kopano-webapp-plugin-delayeddelivery /usr/share/doc/kopano-webapp-plugin-filepreviewer /usr/share/doc/kopano-presence /usr/share/doc/gsoap-kopano-dev /usr/share/doc/python-kopano /usr/share/doc/kopano-webapp-plugin-zdeveloper /usr/share/doc/kopano-common /usr/share/doc/gsoap-kopano-dbg /usr/share/doc/kopano-webapp-plugin-desktopnotifications /usr/share/doc/kopano-lang /usr/share/doc/gsoap-kopano /usr/share/doc/kopano-webapp-plugin-quickitems /usr/share/doc/gsoap-kopano-doc /usr/share/doc/kopano-webapp-plugin-folderwidgets /usr/share/doc/libvmime-kopano-dev /usr/share/python/runtime.d/kopano-spooler.rtupdate /usr/share/python/runtime.d/kopano-dagent.rtupdate /usr/share/lintian/overrides/kopano-webmeetings /usr/share/kopano-webapp /usr/share/kopano-webapp/plugins/desktopnotifications/resources/Kopano.ico /usr/share/kopano-webapp/kopano.php /usr/share/kopano-webapp/server/includes/bootstrap.kopano.php /usr/share/kopano-webapp/client/resources/css/kopano.css /usr/share/kopano-webapp/client/resources/images/kopano-logo_115x26.png /usr/share/kopano-webapp/client/resources/images/kopano-logo_220x52.png /usr/share/kopano-webapp/client/resources/fonts/kopanowebappdings.eot /usr/share/kopano-webapp/client/resources/fonts/KopanoWebAppDings.svg /usr/share/kopano-webapp/client/resources/fonts/kopanowebappdings.ttf /usr/share/kopano-webapp/client/resources/fonts/kopanowebappdings.woff2 /usr/share/kopano-webapp/client/resources/fonts/kopanowebappdings.woff /usr/share/kopano-webapp/client/kopano.js /usr/share/kopano /usr/share/locale/et/LC_MESSAGES/kopano.mo /usr/share/locale/hr/LC_MESSAGES/kopano.mo /usr/share/locale/el/LC_MESSAGES/kopano.mo /usr/share/locale/fi/LC_MESSAGES/kopano.mo /usr/share/locale/pt/LC_MESSAGES/kopano.mo /usr/share/locale/fr_BE/LC_MESSAGES/kopano.mo /usr/share/locale/da/LC_MESSAGES/kopano.mo /usr/share/locale/ko/LC_MESSAGES/kopano.mo /usr/share/locale/es/LC_MESSAGES/kopano.mo /usr/share/locale/pt_BR/LC_MESSAGES/kopano.mo /usr/share/locale/zh_TW/LC_MESSAGES/kopano.mo /usr/share/locale/de/LC_MESSAGES/kopano.mo /usr/share/locale/cs/LC_MESSAGES/kopano.mo /usr/share/locale/ja/LC_MESSAGES/kopano.mo /usr/share/locale/nl_BE/LC_MESSAGES/kopano.mo /usr/share/locale/gl/LC_MESSAGES/kopano.mo /usr/share/locale/ca/LC_MESSAGES/kopano.mo /usr/share/locale/fa/LC_MESSAGES/kopano.mo /usr/share/locale/nb/LC_MESSAGES/kopano.mo /usr/share/locale/uk/LC_MESSAGES/kopano.mo /usr/share/locale/it/LC_MESSAGES/kopano.mo /usr/share/locale/sv/LC_MESSAGES/kopano.mo /usr/share/locale/he/LC_MESSAGES/kopano.mo /usr/share/locale/fr/LC_MESSAGES/kopano.mo /usr/share/locale/sl/LC_MESSAGES/kopano.mo /usr/share/locale/zh_CN/LC_MESSAGES/kopano.mo /usr/share/locale/pl/LC_MESSAGES/kopano.mo /usr/share/locale/nl/LC_MESSAGES/kopano.mo /usr/share/locale/bg/LC_MESSAGES/kopano.mo /usr/share/locale/lt/LC_MESSAGES/kopano.mo /usr/share/locale/hu/LC_MESSAGES/kopano.mo /usr/share/locale/ru/LC_MESSAGES/kopano.mo /usr/share/locale/tr/LC_MESSAGES/kopano.mo root@kopano:/home/user#
Karsten
-
Hi Karsten
Python packages are missing. Could you try reinstalling python-kopano, maybe purging the package before reinstall.
Bo
-
Hi Bo, thanks for your help.
I purged the python-kopano package by:
apt-get purge python-kopano:Entfernen von kopano-server-packages (8.3.0~622-33.1) …
Entfernen von kopano-backup (8.3.0~622-33.1) …
Löschen der Konfigurationsdateien von kopano-backup (8.3.0~622-33.1) …
Entfernen von kopano-migration-pst (8.3.0~622-33.1) …
Löschen der Konfigurationsdateien von kopano-migration-pst (8.3.0~622-33.1) …
Entfernen von kopano-presence (8.3.0~622-33.1) …
Löschen der Konfigurationsdateien von kopano-presence (8.3.0~622-33.1) …
Entfernen von kopano-search (8.3.0~622-33.1) …
Löschen der Konfigurationsdateien von kopano-search (8.3.0~622-33.1) …
Entfernen von python-kopano (8.3.0~622-33.1) …
Trigger für man-db (2.7.5-1) werden verarbeitet …after purging I Reinstalled the packages:
dpkg -i ……reboot and tried the script. Sorry, no solution. As I looked for python-kopano:
root@kopano:/# find -iname python-kopano
./var/lib/dpkg/info/python-kopano.list
./var/lib/dpkg/info/python-kopano.md5sums
./var/lib/dpkg/info/python-kopano.postinst
./var/lib/dpkg/info/python-kopano.prerm
./usr/share/doc/python-kopano
./temp1/kopano/core-8.3.0~622_33.1-Ubuntu_16.04-amd64/installiert/python-kopano_8.3.0~622-33.1_all.deb
root@kopano:/#Maybe a mistake in the package of the installation?
Karsten
-
@kmeyer said in changing folder names to other languages - error on global "kopano" - python script:
oot@kopano:/# find -iname python-kopano
./var/lib/dpkg/info/python-kopano.list
./var/lib/dpkg/info/python-kopano.md5sums
./var/lib/dpkg/info/python-kopano.postinst
./var/lib/dpkg/info/python-kopano.prerm
./usr/share/doc/python-kopano
./temp1/kopano/core-8.3.0~622_33.1-Ubuntu_16.04-amd64/installiert/python-kopano_8.3.0~622-33.1_all.deb
root@kopano:/#The correct location according to the .deb package: /usr/lib/python2.7/dist-packages/kopano/
$ python ... >>> import kopano
Still does not work?
-
okay, there is the “/usr/lib/python2.7/dist-packages/kopano/” folder.
as I type
root@kopano:/usr/lib/python2.7# python
Python 2.7.12 (default, Nov 19 2016, 06:48:10)
[GCC 5.4.0 20160609] on linux2
Type “help”, “copyright”, “credits” or “license” for more information.
import kopano…there is no error.
as I try the script:
root@kopano:/temp1# python ./newfoldernames.py
Traceback (most recent call last):
File “./newfoldernames.py”, line 112, in <module>
main()
File “./newfoldernames.py”, line 74, in main
options, args = opt_args()
File “./newfoldernames.py”, line 12, in opt_args
parser = kopano.parser(‘skpfucm’)
NameError: global name ‘kopano’ is not definedmysterious?
-
@kmeyer said in changing folder names to other languages - error on global "kopano" - python script:
File “./newfoldernames.py”, line 12, in opt_args
parser = kopano.parser(‘skpfucm’)
NameError: global name ‘kopano’ is not definedIs the script modified? According to the script, the referred line is 13 (not 12)
https://stash.kopano.io/projects/KSC/repos/core-tools/browse/localize-folders.pyBo
-
Hi bo,
yes I had modified ist during our conversation. Now it works! Great!
Thanks! -
@kmeyer said in changing folder names to other languages - error on global "kopano" - python script:
Hi bo,
yes I had modified ist during our conversation. Now it works! Great!
Thanks!Great! You’re welcome.
Bo