Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cant find value in cloud config #35

Closed
ykutovoy opened this issue Dec 23, 2021 · 11 comments
Closed

Cant find value in cloud config #35

ykutovoy opened this issue Dec 23, 2021 · 11 comments
Labels
solution Solution found and present.

Comments

@ykutovoy
Copy link

Screenshot
image

Describe the bug
After installing application getting this kind of errors.

Looks like app try to find config in some kind default location

Desktop (please complete the following information):

  • OS Description: Ubuntu 20.04.3 LTS
  • CPU: Intel(R) Core(TM) i5-3470 CPU @ 3.20GHz (2 cores)
  • Browser: any
  • Nextcloud version: 22.2.3
  • Database configuration: mysql 10.3.32 206,2 MB
  • Python version: 3.8.10 (default, Nov 26 2021)
  • MediaDC version: 0.1.8

Additional context
Could You add textbox in configuration section to point to config file manually, in case if app cannot find it by itself?

Where can i write correct path (file/variable)? to make tests.

@bigcat88
Copy link
Member

@ykutovoy
In future versions(probably 0.2.0, we are currently working on that technique) there will be no such things as reads from config at all.
In current versions we dont read from config directly, we call nextcloud's occ to do that.
Can you post here what occ return for that?
sudo -u www-data php /pathtonextcloufdoler/occ config:system:get datadirectory
if nextcloud is in /var/www then command will be something like that:
sudo -u www-data php /var/www/nextcloud/occ config:system:get datadirectory

@ykutovoy
Copy link
Author

For sure:

sudo -u www-data php --define apc.enable_cli=1 /var/www/html/cloud/occ config:system:get datadirectory
/media/oc_data/owncloud_data/

You can see that i've used inline definition --define apc.enable_cli=1
it is an issue for other app (face recognition) which conflicts with this definition

without this it drops like this:

sudo -u www-data php /var/www/html/cloud/occ config:system:get datadirectory
[sudo] password for *****:
An unhandled exception has been thrown:
OC\HintException: [0]: Memcache \OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?)

@ykutovoy
Copy link
Author

I'm ready to add path directly to file, if You will say where :)
Wile we waiting for the next release.

@bigcat88
Copy link
Member

For sure:

sudo -u www-data php --define apc.enable_cli=1 /var/www/html/cloud/occ config:system:get datadirectory
/media/oc_data/owncloud_data/

You can see that i've used inline definition --define apc.enable_cli=1 it is an issue for other app (face recognition) which conflicts with this definition

without this it drops like this:

sudo -u www-data php /var/www/html/cloud/occ config:system:get datadirectory
[sudo] password for *****:
An unhandled exception has been thrown:
OC\HintException: [0]: Memcache \OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?)

So you have partially broken NC instance(occ is a official tool) and ask why our app is no working =)
We will not fix this, when we will go away from use occ a, your problem will bee solved.

You can change file occ_cloud.py, line 87. This is code that call's occ.
Change success, result = php_call(OCC, '--no-warnings', occ_task, *params, decode=decode)
to
success, result = php_call('--define', 'apc.enable_cli=1', OCC, '--no-warnings', occ_task, *params, decode=decode)

@ykutovoy
Copy link
Author

image

Thank You now it works
unfortunately I'm just a USER (may be a bit advanced) :)

If it will be interesting for anybody, I can try to find that issue...
at the moment Yours app works perfect

@bigcat88 bigcat88 added the solution Solution found and present. label Dec 23, 2021
@bigcat88 bigcat88 pinned this issue Dec 23, 2021
@bigcat88 bigcat88 changed the title Application could not find cloud config file Cant find value in cloud config. apc.enable_cli, face recognition. Dec 23, 2021
@bigcat88 bigcat88 changed the title Cant find value in cloud config. apc.enable_cli, face recognition. Cant find value in cloud config Dec 23, 2021
@dagguh
Copy link

dagguh commented Jan 25, 2022

I've got the same symptoms. My NC is installed via snap. I can run occ like this:

-> % sudo snap run nextcloud.occ config:system:get datadirectory
/media/t5-ssd/nextcloud/data

@bigcat88
Copy link
Member

bigcat88 commented Feb 1, 2022

@dagguh for snap users it a bit different situation, it much more complex. we will start to support snap installations from 0.2.0 or 0.2.2 version, just be give us time.

@2br-2b
Copy link

2br-2b commented Feb 2, 2022

I can confirm. I have NC installed via Snap and I have the same issue. Looking forward to sorting out the 150+ gb of files in my photos!

@bigcat88
Copy link
Member

bigcat88 commented Dec 4, 2022

@2br-2b and others.
If you are still using snap please try beta version. #91

@2br-2b
Copy link

2br-2b commented Dec 7, 2022

Per #91 (comment), it seems that we'll have to wait until NC25 is released to test out the beta unless anyone wants to update from Git.

@andrey18106
Copy link
Member

Since MediaDC 0.3.0 version Configuration page removed with pre-compiled binaries added this issue is not actual. Closing as resolved.

If have any relates questions feel free to open a new issue in cloud_py_api as this part moved there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
solution Solution found and present.
Projects
None yet
Development

No branches or pull requests

5 participants