[Support] Linuxserver.io - Nextcloud


Recommended Posts

2 minutes ago, skois said:

I created a template to fill when someone have a problem, so we get as much info as we can and also avoid multiple posts asking to post this and that.

If you have anything else in mind to add to template or change, please tell me.

Because this forum don't render markdown, here is the link of the template.

 

https://github.com/stavros-k/unraid_issue_templates/blob/2385d08395a78bfcec5491617c95ea1f8d758ef5/Issue Tempalte.md

That’s actually a great idea, was thinking last night as to whether something like that would help. 
 

Will let you know how testing goes later :) 

 

Thanks, 

 

Myles

Link to comment

hi skois i did post what was happening with the cloud server as i can not load anything up there and tells me i dont have perrmission to do that , and i am a newbe to linux and unraid i do not know what info you require (still trying to get my head around it all)

but thanks for your reply 

 

Members

 3

33 posts

Posted Friday at 04:58 PM

hi guys i seem to be having a problem with nextcould , i load any files to it as it says i dont have permission to do that , strange as i am admin and the only one on there and i seem to have this error message , i hope you guys can help many thanks in advance 

 

 

 

Security & setup warnings

It's important for the security and performance of your instance that everything is configured correctly. To help you with that we are doing some automatic checks. Please see the linked documentation for more information.

There are some errors regarding your setup.

Your web server is not yet properly set up to allow file synchronisation, because the WebDAV interface seems to be broken.

SQLite is currently being used as the backend database. For larger installations we recommend that you switch to a different database backend. This is particularly recommended when using the desktop client for file synchronisation. To migrate to another database use the command line tool: 'occ db:convert-type', or see the documentation ↗.

The "Strict-Transport-Security" HTTP header is not set to at least "15552000" seconds. For enhanced security, it is recommended to enable HSTS as described in the security tips ↗.

Your web server is not properly set up to resolve "/.well-known/webfinger". Further information can be found in the documentation.

Your web server is not properly set up to resolve "/.well-known/nodeinfo". Further information can be found in the documentation.

Your web server is not properly set up to resolve "/.well-known/caldav". Further information can be found in the documentation.

Your web server is not properly set up to resolve "/.well-known/carddav". Further information can be found in the documentation.

Your installation has no default phone region set. This is required to validate phone numbers in the profile settings without a country code. To allow numbers without a country code, please add "default_phone_region" with the respective ISO 3166-1 code ↗ of the region to your config file.

Please double check the installation guides ↗, and check for any errors or warnings in the log.

Check the security of your Nextcloud over our security scan ↗.

Link to comment

Great idea @skois, let me populate your template.

 

What problem you experience:

Access to Nextcloud using reverse-prox stopped working. I am getting the error message attached.

 

What error messages you get:

Internal Server Error The server encountered an internal error and was unable to complete your request. Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report. More details can be found in the webserver log.

 

When I do this I get this message.

Why trying to access Nextcloud using the internal or external address.

 

What steps did you make and what was the outcome:

1. I got the internal access working with the copy of /mnt/user/appdata/nextcloud/wwwn/extcloud/config/config.php that I took before configuring reverse proxy.

 

2. A ping to the external address of nextcloud is working.

 

My setup is as follows:

(Names included in repository names)

 

Docker Repositories:

linuxserver/nextcloud

linuxserver/swag

linuxserver/mariadb

 

Network:

NETWORK ID          NAME                DRIVER              SCOPE
2399deb73d7d        br0                 macvlan             local
a84faa728ce0        bridge              bridge              local
e77748455f75        host                host                local
196eb99381ce        none                null                local
75f705533666        proxynet              bridge              local

That should be fine. All three dockers use the proxynet bridge network.

 

Docker Logs:

Nextcloud Log


-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 20-config: executing...
[cont-init.d] 20-config: exited 0.
[cont-init.d] 30-keygen: executing...
using keys found in /config/keys
[cont-init.d] 30-keygen: exited 0.
[cont-init.d] 40-config: executing...
[cont-init.d] 40-config: exited 0.
[cont-init.d] 50-install: executing...
[cont-init.d] 50-install: exited 0.
[cont-init.d] 60-memcache: executing...
[cont-init.d] 60-memcache: exited 0.
[cont-init.d] 70-aliases: executing...
[cont-init.d] 70-aliases: exited 0.
[cont-init.d] 99-custom-files: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-files: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.

 

Mariadb Log

-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 30-config: executing...
[cont-init.d] 30-config: exited 0.
[cont-init.d] 40-initialise-db: executing...
[cont-init.d] 40-initialise-db: exited 0.
[cont-init.d] 90-warning: executing...

******************************************************
******************************************************
* *
* *
* This image will soon be rebased *
* from ubuntu to alpine. *
* Please be aware, this may cause issues *
* It is strongly recommended to make backups *
* of your config and databases before *
* updating your image to the alpine base. *
* *
* *
******************************************************
******************************************************
[cont-init.d] 90-warning: exited 0.
[cont-init.d] 99-custom-scripts: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-scripts: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
210323 16:26:04 mysqld_safe Logging to syslog.
210323 16:26:04 mysqld_safe Starting mysqld daemon with databases from /config/databases

 

Swag Log

-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 20-config: executing...
[cont-init.d] 20-config: exited 0.
[cont-init.d] 30-keygen: executing...
using keys found in /config/keys
[cont-init.d] 30-keygen: exited 0.
[cont-init.d] 50-config: executing...
Variables set:
PUID=99
PGID=100
TZ=Europe/Berlin
URL=mydomain.de
SUBDOMAINS=nextcloud
EXTRA_DOMAINS=
ONLY_SUBDOMAINS=true
VALIDATION=http
CERTPROVIDER=
DNSPLUGIN=
EMAIL=(removed)
STAGING=false

Using Let's Encrypt as the cert provider
SUBDOMAINS entered, processing
SUBDOMAINS entered, processing
Only subdomains, no URL in cert
Sub-domains processed are: -d nextcloud.mydomain.de
E-mail address entered: (removed)
http validation is selected
Certificate exists; parameters unchanged; starting nginx
Starting 2019/12/30, GeoIP2 databases require personal license key to download. Please retrieve a free license key from MaxMind,
and add a new env variable "MAXMINDDB_LICENSE_KEY", set to your license key.
[cont-init.d] 50-config: exited 0.
[cont-init.d] 60-renew: executing...
The cert does not expire within the next day. Letting the cron script handle the renewal attempts overnight (2:08am).
[cont-init.d] 60-renew: exited 0.
[cont-init.d] 70-templates: executing...
[cont-init.d] 70-templates: exited 0.
[cont-init.d] 99-custom-files: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-files: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
Server ready

 

App Logs

 

Nextcloud

Only one entry, when accessing using the local address and the old config.php (see above). No other log entries since problem started.

{"reqId":"qCxQnN2R0QsphV1xEzAw","level":3,"time":"2021-03-23T15:45:00+00:00","remoteAddr":"","user":"--","app":"cron","method":"","url":"--","message":{"Exception":"TypeError","Message":"Argument 1 passed to OC\\DB\\SchemaWrapper::__construct() must be an instance of OC\\DB\\Connection, instance of OC\\DB\\ConnectionAdapter given, called in /config/www/nextcloud/apps/spreed/lib/BackgroundJob/CheckReferenceIdColumn.php on line 59","Code":0,"Trace":[{"file":"/config/www/nextcloud/apps/spreed/lib/BackgroundJob/CheckReferenceIdColumn.php","line":59,"function":"__construct","class":"OC\\DB\\SchemaWrapper","type":"->"},{"file":"/config/www/nextcloud/lib/public/BackgroundJob/Job.php","line":80,"function":"run","class":"OCA\\Talk\\BackgroundJob\\CheckReferenceIdColumn","type":"->"},{"file":"/config/www/nextcloud/lib/public/BackgroundJob/TimedJob.php","line":61,"function":"execute","class":"OCP\\BackgroundJob\\Job","type":"->"},{"file":"/config/www/nextcloud/cron.php","line":128,"function":"execute","class":"OCP\\BackgroundJob\\TimedJob","type":"->"}],"File":"/config/www/nextcloud/lib/private/DB/SchemaWrapper.php","Line":41,"CustomMessage":"--"},"userAgent":"--","version":"21.0.0.18"}

 

occ status

An unhandled exception has been thrown:
ParseError: syntax error, unexpected 'nextcloud' (T_STRING), expecting ')' in /config/www/nextcloud/config/config.php:20
Stack trace:
#0 /config/www/nextcloud/lib/private/Config.php(68): OC\Config->readData()
#1 /config/www/nextcloud/lib/base.php(149): OC\Config->__construct()
#2 /config/www/nextcloud/lib/base.php(569): OC::initPaths()
#3 /config/www/nextcloud/lib/base.php(1076): OC::init()
#4 /config/www/nextcloud/console.php(49): require_once('/config/www/nex...')
#5 /config/www/nextcloud/occ(11): require_once('/config/www/nex...')

 

occ maintenance:mode

An unhandled exception has been thrown:
ParseError: syntax error, unexpected 'nextcloud' (T_STRING), expecting ')' in /config/www/nextcloud/config/config.php:20
Stack trace:
#0 /config/www/nextcloud/lib/private/Config.php(68): OC\Config->readData()
#1 /config/www/nextcloud/lib/base.php(149): OC\Config->__construct()
#2 /config/www/nextcloud/lib/base.php(569): OC::initPaths()
#3 /config/www/nextcloud/lib/base.php(1076): OC::init()
#4 /config/www/nextcloud/console.php(49): require_once('/config/www/nex...')
#5 /config/www/nextcloud/occ(11): require_once('/config/www/nex...')

 

config.php

<?php
$CONFIG = array (
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'datadirectory' => '/data',
  'instanceid' => '(removed)',
  'passwordsalt' => '(removed)',
  'secret' => '(removed)',
  'trusted_domains' =>
  array (
    0 => '192.168.178.18:444',
    1 => 'nextcloud.mydomain.de',
  ),
  'dbtype' => 'mysql',
  'version' => '21.0.0.18',
  'overwrite.cli.url' => 'https://nextcloud.mydomain.de',
  'trusted_proxies' =>
  array (
    0 => 'swag',
  ),
  'overwritehost’ => 'nextcloud.mydomain.de’,
  'overwriteprotocol’ => 'https’,
  'dbname' => 'nextcloud',
  'dbhost' => '192.168.178.18:3306',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'nextcloud',
  'dbpassword' => '(removed)',
  'installed' => true,
  'maintenance' => false,
  'default_language' => 'de',
  'default_locale' => 'de_DE',
  'default_phone_region' => 'DE',
  'auth.bruteforce.protection.enabled' => true,
  'app_install_overwrite' =>
  array (
    0 => 'bruteforcesettings',
  ),
);

 

Based on my findings, the MariaDB connection is working and I suspect the config.php to be the culprit. But happy to hear your expert opinions and finfings. Thanks a million in advance for your support!!!

 

Addition:

After removing the lines

  'overwritehost’ => 'nextcloud.mydomain.de’,
  'overwriteprotocol’ => 'https’,

from config.php nextcloud was working again using the external address 🙂 not sure I uderstand why and the implecations when keeping those lines out...

 

nextcloud internal server error.png

Edited by NielsS
Link to comment
21 minutes ago, NielsS said:

occ status

An unhandled exception has been thrown:
ParseError: syntax error, unexpected 'nextcloud' (T_STRING), expecting ')' in /config/www/nextcloud/config/config.php:20
Stack trace:
#0 /config/www/nextcloud/lib/private/Config.php(68): OC\Config->readData()
#1 /config/www/nextcloud/lib/base.php(149): OC\Config->__construct()
#2 /config/www/nextcloud/lib/base.php(569): OC::initPaths()
#3 /config/www/nextcloud/lib/base.php(1076): OC::init()
#4 /config/www/nextcloud/console.php(49): require_once('/config/www/nex...')
#5 /config/www/nextcloud/occ(11): require_once('/config/www/nex...')

OK, lets start with this, by the eye the syntax looks right.
Try opening config file with nano.  either by using unraid's terminal or docker console.
At line 20 (its the array with the 'swag'). check if there is any space after or anything out of the ordinary.
Try actually deleting the array block and rewriting manually. Save file and restart nextcloud. Try again occ status.
See if it spits any errors for the config file

 

 

PS. i just show you have some weird characters in the config. You have ’ instead of ' . I don't know which symbol is that, but i wouldn't see it in this font here. I copied to another editor.

So here is what i found. Fix those and you should be fine

 

Screenshot 2021-03-23 184146.jpg

  • Like 1
Link to comment
19 minutes ago, skois said:

OK, lets start with this, by the eye the syntax looks right.
Try opening config file with nano.  either by using unraid's terminal or docker console.
At line 20 (its the array with the 'swag'). check if there is any space after or anything out of the ordinary.
Try actually deleting the array block and rewriting manually. Save file and restart nextcloud. Try again occ status.
See if it spits any errors for the config file

 

 

PS. i just show you have some weird characters in the config. You have ’ instead of ' . I don't know which symbol is that, but i wouldn't see it in this font here. I copied to another editor.

So here is what i found. Fix those and you should be fine

 

Screenshot 2021-03-23 184146.jpg

Indeed @skois, after removing both lines it worked with the external address and adding them with the correct characters, it was working again as well. You rock - thanks a million for your time and help!

I hope my piloting your template was also beneficial for you. Let's hope the problem of the other two with similar problems are eaqually easy to sort. I keep fingers crossed.

  • Like 1
Link to comment
1 minute ago, NielsS said:

Indeed @skois, after removing both lines it worked with the external address and adding them with the correct characters, it was working again as well. You rock - thanks a million for your time and help!

I hope my piloting your template was also beneficial for you. Let's hope the problem of the other two with similar problems are eaqually easy to sort. I keep fingers crossed.

Happy its working! Also if you keep getting the error you linked on nextcloud.log, its from the Talk app, try disabling if you dont use it

Link to comment
1 hour ago, cwebb said:

hi skois i did post what was happening with the cloud server as i can not load anything up there and tells me i dont have perrmission to do that , and i am a newbe to linux and unraid i do not know what info you require (still trying to get my head around it all)

but thanks for your reply 

 

Members

 3

33 posts

Posted Friday at 04:58 PM

hi guys i seem to be having a problem with nextcould , i load any files to it as it says i dont have permission to do that , strange as i am admin and the only one on there and i seem to have this error message , i hope you guys can help many thanks in advance 

 

 

 

Security & setup warnings

It's important for the security and performance of your instance that everything is configured correctly. To help you with that we are doing some automatic checks. Please see the linked documentation for more information.

There are some errors regarding your setup.

Your web server is not yet properly set up to allow file synchronisation, because the WebDAV interface seems to be broken.

SQLite is currently being used as the backend database. For larger installations we recommend that you switch to a different database backend. This is particularly recommended when using the desktop client for file synchronisation. To migrate to another database use the command line tool: 'occ db:convert-type', or see the documentation ↗.

The "Strict-Transport-Security" HTTP header is not set to at least "15552000" seconds. For enhanced security, it is recommended to enable HSTS as described in the security tips ↗.

Your web server is not properly set up to resolve "/.well-known/webfinger". Further information can be found in the documentation.

Your web server is not properly set up to resolve "/.well-known/nodeinfo". Further information can be found in the documentation.

Your web server is not properly set up to resolve "/.well-known/caldav". Further information can be found in the documentation.

Your web server is not properly set up to resolve "/.well-known/carddav". Further information can be found in the documentation.

Your installation has no default phone region set. This is required to validate phone numbers in the profile settings without a country code. To allow numbers without a country code, please add "default_phone_region" with the respective ISO 3166-1 code ↗ of the region to your config file.

Please double check the installation guides ↗, and check for any errors or warnings in the log.

Check the security of your Nextcloud over our security scan ↗.

I did read that. That all it says it's some setup warnings, This shouldn't cause any problems you referring. 
Check 2 posts above.

Link to comment
21 hours ago, skois said:

Open terminal on unraid and do

* "docker network ls" -> Does proxynet appears?
Go to mariadb, nextcloud and swag docker and click edit.
* Are all of them on "proxynet" or they have defaulted back to bridge or anything else.
Go to /mnt/user/nextcloud (the folder you mapped as /data for nextcloud)
* Get the nextcloud.log (this is the log that gives you some info about nc instance)

 

* When you visit localip:port (nextcloud ui) does it work?  or neither external or internal works?

Please also attach config.php from /mnt/user/appdata/nextcloud/wwwn/extcloud/config/config.php

 

When you say "Unable to connect" it says just that? Or maybe it's "Internal Server Error" 

* Can you grab a screenshot please

Hi Skois,

 

I ran "docker network ls" and proxy net appeared.

 

Mariadb, nextcloud and swag are all on "proxynet"

 

when I visit localip:port I can't connect either.

 

I'll fill the template to hopefully help in troubleshooting efforts:

 

What problem you experience - unable to access nextcloud UI via reverse proxy or localip:port

 

What error messages you get: image.png.ba5400f95beadcbea5436fe47e5195f9.png

 

My set is as follows -

 

name:

nextcloud

mariadb

swag

 

repository:

linuxserver/mariadb

linuxserver/nextcloud

linuxserver/swag

 

Network -

 

nextcloud - "proxynet"

mariadb - "proxynet"

swag - "proxynet"

 

root@LewisServer:~# docker network ls
NETWORK ID          NAME                DRIVER              SCOPE
7c2cb36628ae        br0                 macvlan             local
72623318ff91        bridge              bridge              local
8b453a111711        host                host                local
74282ed633f2        none                null                local
17997a39d39e        proxynet            bridge              local

 

Logs -

 

Nextcloud:

 

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 01-envfile: executing...
[cont-init.d] 01-envfile: exited 0.
[cont-init.d] 10-adduser: executing...

-------------------------------------
_ ()
| | ___ _ __
| | / __| | | / \
| | \__ \ | | | () |
|_| |___/ |_| \__/


Brought to you by linuxserver.io
-------------------------------------

To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 20-config: executing...
[cont-init.d] 20-config: exited 0.
[cont-init.d] 30-keygen: executing...
using keys found in /config/keys
[cont-init.d] 30-keygen: exited 0.
[cont-init.d] 40-config: executing...
[cont-init.d] 40-config: exited 0.
[cont-init.d] 50-install: executing...
[cont-init.d] 50-install: exited 0.
[cont-init.d] 60-memcache: executing...
[cont-init.d] 60-memcache: exited 0.
[cont-init.d] 70-aliases: executing...
[cont-init.d] 70-aliases: exited 0.
[cont-init.d] 99-custom-files: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-files: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.

 

mariadb:

 

Brought to you by linuxserver.io
-------------------------------------

To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 30-config: executing...
[cont-init.d] 30-config: exited 0.
[cont-init.d] 40-initialise-db: executing...
[cont-init.d] 40-initialise-db: exited 0.
[cont-init.d] 90-warning: executing...

******************************************************
******************************************************
* *
* *
* This image will soon be rebased *
* from ubuntu to alpine. *
* Please be aware, this may cause issues *
* It is strongly recommended to make backups *
* of your config and databases before *
* updating your image to the alpine base. *
* *
* *
******************************************************
******************************************************
[cont-init.d] 90-warning: exited 0.
[cont-init.d] 99-custom-scripts: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-scripts: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
210323 19:19:30 mysqld_safe Logging to syslog.
210323 19:19:31 mysqld_safe Starting mysqld daemon with databases from /config/databases

 

swag:


[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 01-envfile: executing...
[cont-init.d] 01-envfile: exited 0.
[cont-init.d] 10-adduser: executing...
usermod: no changes

-------------------------------------
_ ()
| | ___ _ __
| | / __| | | / \
| | \__ \ | | | () |
|_| |___/ |_| \__/


Brought to you by linuxserver.io
-------------------------------------

To support the app dev(s) visit:
Certbot: https://supporters.eff.org/donate/support-work-on-certbot

To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 20-config: executing...
[cont-init.d] 20-config: exited 0.
[cont-init.d] 30-keygen: executing...
using keys found in /config/keys
[cont-init.d] 30-keygen: exited 0.
[cont-init.d] 50-config: executing...
Variables set:
PUID=99
PGID=100
TZ=Europe/London
URL=******************.net
SUBDOMAINS=nextcloud
EXTRA_DOMAINS=
ONLY_SUBDOMAINS=true
VALIDATION=http
CERTPROVIDER=
DNSPLUGIN=
EMAIL=*****_*****@hotmail.co.uk
STAGING=false

Using Let's Encrypt as the cert provider
SUBDOMAINS entered, processing
SUBDOMAINS entered, processing
Only subdomains, no URL in cert
Sub-domains processed are: -d nextcloud.*************.net
E-mail address entered: *****_*****@hotmail.co.uk
http validation is selected
Certificate exists; parameters unchanged; starting nginx
Starting 2019/12/30, GeoIP2 databases require personal license key to download. Please retrieve a free license key from MaxMind,
and add a new env variable "MAXMINDDB_LICENSE_KEY", set to your license key.
[cont-init.d] 50-config: exited 0.
[cont-init.d] 60-renew: executing...
The cert does not expire within the next day. Letting the cron script handle the renewal attempts overnight (2:08am).
[cont-init.d] 60-renew: exited 0.
[cont-init.d] 70-templates: executing...
[cont-init.d] 70-templates: exited 0.
[cont-init.d] 99-custom-files: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-files: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
Server ready

 

App Logs -

 

The text in this file is very very long and not formatted in lines at all, I have attached the log file.

 

occ status:   - installed: true
  - version: 20.0.7.1
  - versionstring: 20.0.7
  - edition:

occ maintenance:mode - Maintenance mode is currently disabled

 

app config -

 

<?php
$CONFIG = array (
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'datadirectory' => '/data',
  'instanceid' => '***************',
  'passwordsalt' => '*********************************',
  'secret' => '**************************************************************',
  'trusted_domains' =>
  array (
    0 => '192.168.1.139:444',
    1 => 'nextcloud.*************.net',
  ),
  'dbtype' => 'mysql',
  'version' => '20.0.7.1',
  'overwrite.cli.url' => 'https://nextcloud.*************.net',
  'overwritehost' => 'nextcloud.****************.net',
  'overwriteprotocol' => 'https',
  'dbname' => 'nextcloud',
  'dbhost' => '192.168.1.139:3306',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'nextcloud',
  'dbpassword' => '**********',
  'installed' => true,
  'trusted_proxies' => ['swag'],
);

 

apologies for the long post !

 

Thanks, -Myles

 

 

nextcloud.log

Link to comment
2 hours ago, Myleslewis said:

Hi Skois,

 

I ran "docker network ls" and proxy net appeared.

 

Mariadb, nextcloud and swag are all on "proxynet"

 

when I visit localip:port I can't connect either.

 

I'll fill the template to hopefully help in troubleshooting efforts:

 

What problem you experience - unable to access nextcloud UI via reverse proxy or localip:port

 

What error messages you get: image.png.ba5400f95beadcbea5436fe47e5195f9.png

 

My set is as follows -

 

name:

nextcloud

mariadb

swag

 

repository:

linuxserver/mariadb

linuxserver/nextcloud

linuxserver/swag

 

Network -

 

nextcloud - "proxynet"

mariadb - "proxynet"

swag - "proxynet"

 

root@LewisServer:~# docker network ls
NETWORK ID          NAME                DRIVER              SCOPE
7c2cb36628ae        br0                 macvlan             local
72623318ff91        bridge              bridge              local
8b453a111711        host                host                local
74282ed633f2        none                null                local
17997a39d39e        proxynet            bridge              local

 

Logs -

 

Nextcloud:

 

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 01-envfile: executing...
[cont-init.d] 01-envfile: exited 0.
[cont-init.d] 10-adduser: executing...

-------------------------------------
_ ()
| | ___ _ __
| | / __| | | / \
| | \__ \ | | | () |
|_| |___/ |_| \__/


Brought to you by linuxserver.io
-------------------------------------

To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 20-config: executing...
[cont-init.d] 20-config: exited 0.
[cont-init.d] 30-keygen: executing...
using keys found in /config/keys
[cont-init.d] 30-keygen: exited 0.
[cont-init.d] 40-config: executing...
[cont-init.d] 40-config: exited 0.
[cont-init.d] 50-install: executing...
[cont-init.d] 50-install: exited 0.
[cont-init.d] 60-memcache: executing...
[cont-init.d] 60-memcache: exited 0.
[cont-init.d] 70-aliases: executing...
[cont-init.d] 70-aliases: exited 0.
[cont-init.d] 99-custom-files: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-files: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.

 

mariadb:

 

Brought to you by linuxserver.io
-------------------------------------

To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 30-config: executing...
[cont-init.d] 30-config: exited 0.
[cont-init.d] 40-initialise-db: executing...
[cont-init.d] 40-initialise-db: exited 0.
[cont-init.d] 90-warning: executing...

******************************************************
******************************************************
* *
* *
* This image will soon be rebased *
* from ubuntu to alpine. *
* Please be aware, this may cause issues *
* It is strongly recommended to make backups *
* of your config and databases before *
* updating your image to the alpine base. *
* *
* *
******************************************************
******************************************************
[cont-init.d] 90-warning: exited 0.
[cont-init.d] 99-custom-scripts: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-scripts: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
210323 19:19:30 mysqld_safe Logging to syslog.
210323 19:19:31 mysqld_safe Starting mysqld daemon with databases from /config/databases

 

swag:


[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 01-envfile: executing...
[cont-init.d] 01-envfile: exited 0.
[cont-init.d] 10-adduser: executing...
usermod: no changes

-------------------------------------
_ ()
| | ___ _ __
| | / __| | | / \
| | \__ \ | | | () |
|_| |___/ |_| \__/


Brought to you by linuxserver.io
-------------------------------------

To support the app dev(s) visit:
Certbot: https://supporters.eff.org/donate/support-work-on-certbot

To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 20-config: executing...
[cont-init.d] 20-config: exited 0.
[cont-init.d] 30-keygen: executing...
using keys found in /config/keys
[cont-init.d] 30-keygen: exited 0.
[cont-init.d] 50-config: executing...
Variables set:
PUID=99
PGID=100
TZ=Europe/London
URL=******************.net
SUBDOMAINS=nextcloud
EXTRA_DOMAINS=
ONLY_SUBDOMAINS=true
VALIDATION=http
CERTPROVIDER=
DNSPLUGIN=
EMAIL=*****_*****@hotmail.co.uk
STAGING=false

Using Let's Encrypt as the cert provider
SUBDOMAINS entered, processing
SUBDOMAINS entered, processing
Only subdomains, no URL in cert
Sub-domains processed are: -d nextcloud.*************.net
E-mail address entered: *****_*****@hotmail.co.uk
http validation is selected
Certificate exists; parameters unchanged; starting nginx
Starting 2019/12/30, GeoIP2 databases require personal license key to download. Please retrieve a free license key from MaxMind,
and add a new env variable "MAXMINDDB_LICENSE_KEY", set to your license key.
[cont-init.d] 50-config: exited 0.
[cont-init.d] 60-renew: executing...
The cert does not expire within the next day. Letting the cron script handle the renewal attempts overnight (2:08am).
[cont-init.d] 60-renew: exited 0.
[cont-init.d] 70-templates: executing...
[cont-init.d] 70-templates: exited 0.
[cont-init.d] 99-custom-files: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-files: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
Server ready

 

App Logs -

 

The text in this file is very very long and not formatted in lines at all, I have attached the log file.

 

occ status:   - installed: true
  - version: 20.0.7.1
  - versionstring: 20.0.7
  - edition:

occ maintenance:mode - Maintenance mode is currently disabled

 

app config -

 

<?php
$CONFIG = array (
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'datadirectory' => '/data',
  'instanceid' => '***************',
  'passwordsalt' => '*********************************',
  'secret' => '**************************************************************',
  'trusted_domains' =>
  array (
    0 => '192.168.1.139:444',
    1 => 'nextcloud.*************.net',
  ),
  'dbtype' => 'mysql',
  'version' => '20.0.7.1',
  'overwrite.cli.url' => 'https://nextcloud.*************.net',
  'overwritehost' => 'nextcloud.****************.net',
  'overwriteprotocol' => 'https',
  'dbname' => 'nextcloud',
  'dbhost' => '192.168.1.139:3306',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'nextcloud',
  'dbpassword' => '**********',
  'installed' => true,
  'trusted_proxies' => ['swag'],
);

 

apologies for the long post !

 

Thanks, -Myles

 

 

nextcloud.log 33.96 kB · 1 download

Could you please go to /mnt/user/nextcloud and do an "ls -la"  (You can hide the usernames if you want. Seems like you missing the .htaccess file.

 

Also try opening a console in nextcloud dokcer and do "occ maintenance:update:htaccess"
See if that helps
Also post the swag config file if the above don't help.

Edited by skois
Link to comment
19 hours ago, skois said:

Could you please go to /mnt/user/nextcloud and do an "ls -la"  (You can hide the usernames if you want. Seems like you missing the .htaccess file.

 

Also try opening a console in nextcloud dokcer and do "occ maintenance:update:htaccess"
See if that helps
Also post the swag config file if the above don't help.

Hi Skois,

 

I've done occ maintenance:update:htaccess and it's updated it but the problem still persists.

 

To do an ls -la, am I right in saying that I need to use the unraid terminal and navigate to that directory. If so, I apologise but how do I change the directory in the unraid terminal.

 

I don't know if it's of relevance, but when I click on the nextcloud icon on the docker tab and click Web UI it only navigates to localip and not localip:port.

 

Thanks,

 

Myles

Link to comment
6 minutes ago, Myleslewis said:

Hi Skois,

 

I've done occ maintenance:update:htaccess and it's updated it but the problem still persists.

 

To do an ls -la, am I right in saying that I need to use the unraid terminal and navigate to that directory. If so, I apologise but how do I change the directory in the unraid terminal.

 

I don't know if it's of relevance, but when I click on the nextcloud icon on the docker tab and click Web UI it only navigates to localip and not localip:port.

 

Thanks,

 

Myles

Hmm, post a screenshot of your nextcloud docker "edit page"

Open unraid terminal do "cd /mnt/user/nextcloud" and then "ls -la"

Link to comment
5 minutes ago, Myleslewis said:

image.thumb.png.efc23f0a36a8fd57f11ca8507a2f4363.png

 

Hi Skois,

 

Above is my docker template, and I did actually try cd /mnt/user/nextcloud first but realised it's case sensitive :P my bad !

 

Here is the output:

image.png.39c6d9322e22291fd97ca96954c38d2b.png

 

Thanks,

 

Myles

Hmm, permissions seems different from mine, first do again "cd /mnt/user/NextCloud" and now do "cat .htaccess"
Then go to Unraid WebUI -> Tools -> New Permissions -> User Shares (select NextCloud) -> Start. 
Restart docker and try agian.
 

Link to comment
18 minutes ago, skois said:

Hmm, permissions seems different from mine, first do again "cd /mnt/user/NextCloud" and now do "cat .htaccess"
Then go to Unraid WebUI -> Tools -> New Permissions -> User Shares (select NextCloud) -> Start. 
Restart docker and try agian.
 

Hi Skois,

 

This is the output of cat .htaccess:

image.png.5cfc73dc071c8e7b4e8207a597bb81fc.png

 

Also I've done the new permissions process and still same issue :/

 

Which swag config is you want to see ? The one specific to nextcloud subdomain or one of these:

 

image.png.e1f977ecee59c61e7a523de8c74a8146.png

 

Thanks, -Myles

 

Link to comment
12 minutes ago, Myleslewis said:

Which swag config is you want to see ? The one specific to nextcloud subdomain or one of these:

 

 

The nextcloud subdomain,

Can you please do a 'ls -la' on nextcloud folder again? After using the permission tool

 

Also open nextcloud docker console an do 'occ integrity:check-core'

Also Go to Docker tab -> Top right corner click advanced -> Right next to nextcloud docker hit force update

Edited by skois
Link to comment
1 minute ago, skois said:

The nextcloud subdomain,

Can you please do a ls -la on nextcloud folder again? After the permission tool

Hi Skois,

 

image.png.083eb05c6b8b8971ed93b5722e03d697.png

 

Here is my log without the commented out text:

 

server {
    listen 443 ssl;
    listen [::]:443 ssl;

    server_name nextcloud.*;

    include /config/nginx/ssl.conf;

    client_max_body_size 0;

    location / {
        include /config/nginx/proxy.conf;
        resolver 127.0.0.11 valid=30s;
        set $upstream_app nextcloud;
        set $upstream_port 443;
        set $upstream_proto https;
        proxy_pass $upstream_proto://$upstream_app:$upstream_port;

        proxy_max_temp_file_size 0;
    }
}

Link to comment
Just now, Myleslewis said:

Hi Skois,

 

image.png.083eb05c6b8b8971ed93b5722e03d697.png

 

Here is my log without the commented out text:

 

server {
    listen 443 ssl;
    listen [::]:443 ssl;

    server_name nextcloud.*;

    include /config/nginx/ssl.conf;

    client_max_body_size 0;

    location / {
        include /config/nginx/proxy.conf;
        resolver 127.0.0.11 valid=30s;
        set $upstream_app nextcloud;
        set $upstream_port 443;
        set $upstream_proto https;
        proxy_pass $upstream_proto://$upstream_app:$upstream_port;

        proxy_max_temp_file_size 0;
    }
}

I added some more info on previous post, refresh page and check the rest :)

Link to comment
1 minute ago, Myleslewis said:

 

output of cat /mnt/user/appdata/nextcloud/www/nextcloud/.user.ini

 

image.png.7ff7d3d31d3aed3998dcebbab2ef3926.png

Ok, here for sure something is wrong.
delete everything that starts with php_
You can put those on /mnt/user/appdata/nextcloud/php/php-local.ini

Restart docker and see if that helps

Link to comment
1 minute ago, Myleslewis said:

image.thumb.png.d817b7570d1841e9f83be2775c727100.png

 

Heres what I get in chrome in incognito mode.

 

Beginning to think a complete removal and fresh install is going to be needed soon !

Wait, this domain points to duckdns? 
Does duckdns have your correct public ip?  I'm trying to ping and it doesn't respond.
Also did you port forwarded the ports on your router?

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.