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

Nextcloud Talk Install Fail #2310

Closed
tenorable opened this issue Dec 2, 2018 · 5 comments
Closed

Nextcloud Talk Install Fail #2310

tenorable opened this issue Dec 2, 2018 · 5 comments
Assignees

Comments

@tenorable
Copy link

Details:

  • Date | Sun 2 Dec 01:13:04 CST 2018
  • Bug report | N/A
  • DietPi version | v6.18.14 (Fourdee/master)
  • Img creator | DietPi Core Team
  • Pre-image | Raspbian Lite
  • SBC device | RPi 3 Model B+ (armv7l) (index=3)
  • Kernel version | Letsencrypt supports Free Noip.com Dynamic DNS #1159 SMP Sun Nov 4 17:50:20 GMT 2018
  • Distro | stretch (index=4)
  • Command | ncc maintenance:mode --off
  • Exit code | 127
  • Software title | DietPi-Software

Steps to reproduce:

  1. ...I have my files saved on an external drive. Copied the dietpi_userdata/nextcloud_data directory to the usb drive. Changed the nextcloud-config.php file to point to the usb drive. All seems to be working correctly, can upload and access files
  2. ...used the dietpi-software to install Nextcloud Talk

Expected behaviour:

  • ...Talk should be installed with the Turn server

Actual behaviour:

  • ...failed. Said there was no ncc command, and there isn't it is occ.

Extra details:

  • ...If I just add it from within Nextcloud, it seems to work ok.

Additional logs:

Log file contents:
/DietPi/dietpi/func/dietpi-globals: line 1366: ncc: command not found
@MichaIng
Copy link
Owner

MichaIng commented Dec 2, 2018

@tenorable
Thanks for your report. Will investigate.

The ncc command is added by us as global function as shortcut for sudo -u www-data php /var/www/nextcloud/occ

Did you install Nextcloud via dietpi-software as well?
€: Should have been, otherwise dietpi-software would have rerun Nextcloud install 🤔
Actually regardless how Nextcloud was installed: If it is placed in /var/www/nextcloud, then globals should create the above global function automatically: https://github.com/Fourdee/DietPi/blob/master/dietpi/func/dietpi-globals#L570

Btw: You can let DietPi install Nextcloud data dir to the desired location via: https://github.com/Fourdee/DietPi/blob/master/dietpi.txt#L226
This is safer, since, if Nextcloud is already installed, at least the skeleton files are indexed already within the database. Moving just the data dir will not adjust the related database entries, thus those files will not appear within Nextcloud until a rescan is done. Not sure if this is nowadays done regularly via cron background jobs, but in the past you needed to do this manually. So basically after moving data dir manually, you should have found an empty dir in Nextcloud web UI, while actually skeleton files are there.


Couldn't replicate on Stretch VM:

  • Installed Nextcloud
  • Installed Nextcloud Talk afterwards (separate run)
  • Everything went fine, coturn up, Nextcloud Talk app available.

🤔

To check:

ls -l /var/www/nextcloud/occ # Check whether file exists as expected, basically Nextcloud itself was installed successfully.
ncc --help # Check whether ncc global function was defined as expected
. /DietPi/dietpi/func/dietpi-globals # Re-source globals, if above fails
ncc --help # Recheck, whether ncc function is defined now
dietpi-software install 168 # Rerun Nextcloud Talk install, which should succeed, if above succeeded

@tenorable
Copy link
Author

tenorable commented Dec 2, 2018 via email

@MichaIng
Copy link
Owner

MichaIng commented Dec 3, 2018

@tenorable
Do calls from browser to browser work well? Then desktop browser to WebRTC capable mobile browser?
Does either the Nextcloud log or turn server log (/var/log/turn_*.log) give some hint?

Will try with fresh setup as well.

@tenorable
Copy link
Author

tenorable commented Dec 3, 2018 via email

@MichaIng
Copy link
Owner

MichaIng commented Dec 4, 2018

@tenorable
Okay did some local testing here, generally it works. On local network connection is very fast, though outside of local network via TURN server indeed takes longer. This highly depends on how the TURN server (your Nextcloud server) is connected to www, NAT, router and firewall setup.

The job of the TURN server is to navigate traffic through different NAT setups successfully, which is otherwise not always possible natively by P2P WebRTC video calls and such, even with STUN server usage (exchange each users local IP as well, besides the external IP only). But it does not work 100% reliable. I also faced issues when doing intercontinental calls e.g. and on Nextcloud forums there are by times similar reports as well, even with all settings done according to docs and Nextcloud Talk/Spreed devs themselves.
It's gotten already better and I guess will become more stable with increasing coturn and Nextcloud Talk versions, in terms of reliability and performance. Note that WebRTC is still a quite young technology, and also e.g. the browsers did implement this just recently, for sure all with slight differences that need to be handled.

Generally if you face issues, please report them here: https://help.nextcloud.com/t/howto-setup-nextcloud-talk-with-turn-server/30794?u=michaing We can then forward them to either coturn, Nextcloud Talk web or mobile app, depending on where it belongs to.

  • Our implementation is based on this HowTo (mine 👼), which again is based on official docs, discussions with devs and gathering all info/experiences I could.
  • There we have a larger audience and devs that we can reach.
  • If some new info/improvements about TURN server settings are found, I will immediately add them to our install code.

Only thing which is important to report here on DietPi GitHub/forum is that dietpi-software install process itself. Everything should finish without errors or course.


About performance as well:

  • Please check the notes about logging in the HowTo. By default coturn logs very much to /var/log/turn_*.log, which is not required besides for debugging. Sadly you cannot adjust the log level, just the log target (file and/or syslog and/or stout). And even with everything disabled and log file to /dev/null, on service start one /var/log/turn_*.log is created to log startup messages, obviously before the logging settings are applied.
  • Actually this is something we can improve in our install code:

Will mark this as closed, as initial issue is solved. Will open new issue for this and 2 other install code improvements.

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

No branches or pull requests

3 participants