Beta-testing phase for YunoHost 3.0 on Debian Stretch

,

nano -l /etc/php/7.0/fpm/pool.d/sonerezh.conf
Deux lignes où il y a des # et non des ; , on change

service php7.0-fpm start
Ca démarre et tout marche sauf Nextcloud.

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 server log.

Je cherche pour Nextcloud.

Après suppression, tentative de réinstallation via la moulinette et j’ai des erreurs

Attention : E: Les paquets doivent être enlevés mais la désinstallation est désactivée.
Attention : Unable to install dependencies
Attention : !!
Attention : nextcloud’s script has encountered an error. Its execution was cancelled.
Attention : !!
Attention :
Attention : Removing database
Attention : ERROR 1064 (42000) at line 1: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ‘’ at line 1
Attention : Avoid deleting .
Attention : /etc/nginx/conf.d/cloud.toto.org.d/nextcloud.conf wasn’t deleted because it doesn’t exist.
Attention : /etc/php5/fpm/pool.d/nextcloud.conf wasn’t deleted because it doesn’t exist.
Attention : Failed to reload php5-fpm.service: Unit php5-fpm.service not found.
Attention : /etc/cron.d/nextcloud wasn’t deleted because it doesn’t exist.
Attention : The user nextcloud was not found
Succès ! La configuration de SSOwat a été générée
Erreur : Échec de l’installation

Après de rapides test seul nextcloud semble avoir un pb. Les autres fonctionnent( Shaarli, Wallabag, Gog, dokuwiki)

Je confirme que seul Nextcloud pose soucis.
Ca marche pour Amapach, Dokuwiki, FreshRSS, Kanboard, Shaarli, Roundcube,Wallabag, Sonerezh, WemaWema, Phpmyadmin.

Sur une nouvelle instance installée directement sous Debian 9 j’ai testé l’importation de sauvegardes. j’ai sauvegardé ma configuration Debian 8 puis réimporté sur le nouveau serveur

Pour installer Nextcloud j’ai du installer des extensions PHP supplémentaires:
php7.0-mbstring et php-xml
Ensuite, je n’ai pas pu me connecter à Nextcloud avec mon identifiant YunoHost de l’utilisateur importé. En ligne de commande (php occ…) j’ai tenté de supprimer l’utilisateur: erreur. J’ai supprimé “”“manuellement”"" (supprimer son dossier NC, ses infos dans la base de données) puis recréé avec php occ.. : ca marche
J’ai créé un nouvel utilisateur, la connexion à Nextcloud a tout de suite marché.

J’ai remarqué que je n’arrive plus à me connecter en SMTP sur ce nouveau serveur installé sur Debian 9. Que ce soit sur un utilisateur réimporté ou nouveau, j’ai une erreur “connexion refusée”.
Dans le firewall, le port 465 est bien ouvert, postfix et dovecot fonctionnent. Dans les logs, rien d’intéressant (fichier /var/log/mail.log)

May 12 15:20:00 hostname dovecot: imap-login: Login: user=<test>, method=PLAIN, rip=1.2.3.4, lip=4.3.2.1, mpid=3880, TLS, session=<Te4PHAJsGqVW0ejK>
May 12 15:20:00 hostname dovecot: imap(test): Connection closed in=0 out=349

Je vois pas trop d’ou ca vient. Les fichiers de configuration n’avaient pas été modifiés, j’ai regénéré les configurations.

Hello,

merci pour le feedback,

je n’ai pas moulte information à apporter, mais à propos de :

Est-ce que tu peux expliquer comment tu as trouvé / compris qu’il fallait installer ça ? :stuck_out_tongue:

Pour nextcloud qui ne marche pas

Les logs de nexcloud se trouvent dans

tail -f /home/yunohost.app/nextcloud/data/nextcloud.log

Et on a un long bloc d’erreur avec

"Exception: {“Exception”:“OC\\HintException”,“Message”:“Memcache \\OC\\Memcache\\APCu not available for local cache”

qui semble une erreur “connue” avec Php/Nextcloud.

J’ai trouvé !!! Nextcloud community
Script 100% auto install on Debian 9. Apache, MPM Event, php-fpm socket, Redis socket, APC

Il est indiqué dans le script :

apt-get install php7.0-apcu -y

Effectivement ce n’était pas là sur la machine.
J’ai installé, rédémarré nginx

Et nextcloud marche !!!

Any issue with Nextcloud on YunoHost 3.0 Debian Stretch

This is the solution : apcu module is missing (was their in 2.7 instance, file /etc/php5/cli/conf.d/20-apcu.ini exists)
install the missing module via

sudo apt-get install php7.0-apcu -y
restart nginx
sudo service nginx restart

Nextcloud normally works now (without 500 error or Internal Error message).

C’était dans les logs d’installation, je l’avais fait en ligne de commande avec --verbose. Lorsque le script a tenté de démarrer Nextcloud, il a répondu qqchose du type :

PHP module XML not installed
PHP module MB not installed 

Ces erreurs ont fait annuler l’installation.

C’est bizarre, chez moi php7.0-apcu est déjà installé, et je n’ai pas eu ton erreur @genma.

J’ai toujours pas compris pourquoi la connexion au serveur en smtp ne fonctionne pas, je regarde…

Chez moi le module Xml était installé; pas le module mbstring…

Hi
I am facing 2 problems after the update to YunoHost 3.0.

  1. Fail2ban is failing. I have tried yunohost service regen-conf fail2ban ,but it still fail.
  2. I can not send the email form the email clients like Thnderbird,k-9 mail etc. But I can send emails form web clients like Roundcube. The incoming of emails messages is working fine.

I have backup of my system. How should I restore fail2ban and dovecot from the backup? And is there better way to make the service work again as normal?

@genma @Gildas

Les joies de l’informatique…
J’ai le même message que Genma dans les log, sauf que installer php7.0-apcu et redémarrer nginx ne change rien.

php7.0-mbstring et php-xml sont bien installé chez moi.

EDIT : OK,c’est bon ça fonctionne. Il manquait juste un petit : systemctl reload php7.0-fpm.service
Donc

apt-get install php7.0-apcu -y
service nginx restart
systemctl reload php7.0-fpm.service

THX @Aleks @genma @Gildas

2 Likes

I installed Rainloop, and I have the same problem as you.
I can’t send mail with SMTP, but Rainloop works. I also tried the mail app of Nextcloud which needs SMTP and IMAP to connect, it didn’t work.

I think it would be better to understand why it’s failing rather than trying to restore your backup to just fix your particular setup, that’s the point of the beta :wink:

Can you provide logs of stuff like service fail2ban status ? Not sure about the whole email thing, but I expect if might be due to stuff we changed in the postfix conf …

I found where’s the problem: The SMTP server now listen to port 587 with STARTTLS instead of 993 and SSL/TLS

A priori, je ne suis pas le seul à avoir le soucis : https://github.com/YunoHost-Apps/nextcloud_ynh/issues/110

J’ai également désinstallé NextCloud puis réinstallé, et je peux bien m’y connecter aussi.

Thanks a lot
This works, I remember I tried with STARTTLS but before it did not work(I think I might have changed the setting of other account,my mistake). But now it works.

Here is the log for fail2ban

fail2ban.service - Fail2Ban Service
   Loaded: loaded (/lib/systemd/system/fail2ban.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since XXXXXXXXXXXXXXX; 45s ago
     Docs: man:fail2ban(1)
  Process: 28723 ExecStart=/usr/bin/fail2ban-client -x start (code=exited, status=255)
 Main PID: 2016 (code=killed, signal=TERM)

XXXXXX 00:37:58 domain.tld systemd[1]: fail2ban.service: Control process exited, code=exited status=255
XXXXXX 00:37:58 domain.tld systemd[1]: Failed to start Fail2Ban Service.
XXXXXX 00:37:58 domain.tld systemd[1]: fail2ban.service: Unit entered failed state.
XXXXXX 00:37:58 domain.tld systemd[1]: fail2ban.service: Failed with result 'exit-code'.
XXXXXX 00:37:58 domain.tld systemd[1]: fail2ban.service: Service hold-off time over, scheduling restart.
XXXXXX 00:37:58 domain.tld systemd[1]: Stopped Fail2Ban Service.
XXXXXX 00:37:58 domain.tld systemd[1]: fail2ban.service: Start request repeated too quickly.
XXXXXX 00:37:58 domain.tld systemd[1]: Failed to start Fail2Ban Service.
XXXXXX 00:37:58 domain.tld systemd[1]: fail2ban.service: Unit entered failed state.
XXXXXX 00:37:58 domain.tld systemd[1]: fail2ban.service: Failed with result 'exit-code'.

Meh, unfortunately this output doesnt help too much (systemd likes to dump dozens of line which tells nothing about what the actual problem is)

Can you try tail -n 100 /var/log/fail2ban.log ?

Here if this logs help :stuck_out_tongue:

iptables -F fail2ban-ssh
iptables -X fail2ban-ssh returned 100
2018-05-09 18:15:49,556 fail2ban.jail   [18723]: INFO    Jail 'ssh' stopped
2018-05-09 18:15:49,799 fail2ban.server [18723]: INFO    Exiting Fail2ban
2018-05-09 18:15:54,218 fail2ban.server [7025]: INFO    Changed logging target to /var/log/fail2ban.log for Fail2ban v0.8.13
2018-05-09 18:15:54,219 fail2ban.jail   [7025]: INFO    Creating new jail 'ssh'
2018-05-09 18:15:55,565 fail2ban.jail   [7025]: INFO    Jail 'ssh' uses pyinotify
2018-05-09 18:15:56,927 fail2ban.jail   [7025]: INFO    Initiated 'pyinotify' backend
2018-05-09 18:15:56,928 fail2ban.filter [7025]: INFO    Added logfile = /var/log/auth.log
2018-05-09 18:15:56,929 fail2ban.filter [7025]: INFO    Set maxRetry = 6
2018-05-09 18:15:56,930 fail2ban.filter [7025]: INFO    Set findtime = 600
2018-05-09 18:15:56,931 fail2ban.actions[7025]: INFO    Set banTime = 600
2018-05-09 18:15:56,969 fail2ban.jail   [7025]: INFO    Creating new jail 'pam-generic'
2018-05-09 18:15:56,969 fail2ban.jail   [7025]: INFO    Jail 'pam-generic' uses pyinotify
2018-05-09 18:15:56,975 fail2ban.jail   [7025]: INFO    Initiated 'pyinotify' backend
2018-05-09 18:15:56,976 fail2ban.filter [7025]: INFO    Added logfile = /var/log/auth.log
2018-05-09 18:15:56,977 fail2ban.filter [7025]: INFO    Set maxRetry = 6
2018-05-09 18:15:56,978 fail2ban.filter [7025]: INFO    Set findtime = 600
2018-05-09 18:15:56,979 fail2ban.actions[7025]: INFO    Set banTime = 600
2018-05-09 18:15:56,985 fail2ban.jail   [7025]: INFO    Creating new jail 'postfix'
2018-05-09 18:15:56,985 fail2ban.jail   [7025]: INFO    Jail 'postfix' uses pyinotify
2018-05-09 18:15:56,991 fail2ban.jail   [7025]: INFO    Initiated 'pyinotify' backend
2018-05-09 18:15:56,992 fail2ban.filter [7025]: INFO    Added logfile = /var/log/mail.log
2018-05-09 18:15:56,993 fail2ban.filter [7025]: INFO    Set maxRetry = 3
2018-05-09 18:15:56,994 fail2ban.filter [7025]: INFO    Set findtime = 600
2018-05-09 18:15:56,994 fail2ban.actions[7025]: INFO    Set banTime = 600
2018-05-09 18:15:57,012 fail2ban.jail   [7025]: INFO    Creating new jail 'sasl'
2018-05-09 18:15:57,012 fail2ban.jail   [7025]: INFO    Jail 'sasl' uses pyinotify
2018-05-09 18:15:57,019 fail2ban.jail   [7025]: INFO    Initiated 'pyinotify' backend
2018-05-09 18:15:57,020 fail2ban.filter [7025]: INFO    Added logfile = /var/log/mail.log
2018-05-09 18:15:57,021 fail2ban.filter [7025]: INFO    Set maxRetry = 3
2018-05-09 18:15:57,022 fail2ban.filter [7025]: INFO    Set findtime = 600
2018-05-09 18:15:57,022 fail2ban.actions[7025]: INFO    Set banTime = 600
2018-05-09 18:15:57,029 fail2ban.jail   [7025]: INFO    Creating new jail 'dovecot'
2018-05-09 18:15:57,029 fail2ban.jail   [7025]: INFO    Jail 'dovecot' uses pyinotify
2018-05-09 18:15:57,035 fail2ban.jail   [7025]: INFO    Initiated 'pyinotify' backend
2018-05-09 18:15:57,036 fail2ban.filter [7025]: INFO    Added logfile = /var/log/mail.log
2018-05-09 18:15:57,037 fail2ban.filter [7025]: INFO    Set maxRetry = 3
2018-05-09 18:15:57,038 fail2ban.filter [7025]: INFO    Set findtime = 600
2018-05-09 18:15:57,039 fail2ban.actions[7025]: INFO    Set banTime = 600
2018-05-09 18:15:57,057 fail2ban.jail   [7025]: INFO    Creating new jail 'nginx'
2018-05-09 18:15:57,057 fail2ban.jail   [7025]: INFO    Jail 'nginx' uses pyinotify
2018-05-09 18:15:57,063 fail2ban.jail   [7025]: INFO    Initiated 'pyinotify' backend
2018-05-09 18:15:57,405 fail2ban.filter [7025]: INFO    Set maxRetry = 6
2018-05-09 18:15:57,407 fail2ban.filter [7025]: INFO    Set findtime = 600
2018-05-09 18:15:57,407 fail2ban.actions[7025]: INFO    Set banTime = 600
2018-05-09 18:15:57,439 fail2ban.jail   [7025]: INFO    Creating new jail 'yunohost'
2018-05-09 18:15:57,439 fail2ban.jail   [7025]: INFO    Jail 'yunohost' uses pyinotify
2018-05-09 18:15:57,445 fail2ban.jail   [7025]: INFO    Initiated 'pyinotify' backend
2018-05-09 18:15:57,534 fail2ban.filter [7025]: INFO    Set maxRetry = 6
2018-05-09 18:15:57,535 fail2ban.filter [7025]: INFO    Set findtime = 600
2018-05-09 18:15:57,536 fail2ban.actions[7025]: INFO    Set banTime = 600
2018-05-09 18:15:57,541 fail2ban.jail   [7025]: INFO    Jail 'ssh' started
2018-05-09 18:15:57,545 fail2ban.jail   [7025]: INFO    Jail 'pam-generic' started
2018-05-09 18:15:57,548 fail2ban.jail   [7025]: INFO    Jail 'postfix' started
2018-05-09 18:15:57,550 fail2ban.jail   [7025]: INFO    Jail 'sasl' started
2018-05-09 18:15:57,554 fail2ban.jail   [7025]: INFO    Jail 'dovecot' started
2018-05-09 18:15:57,558 fail2ban.jail   [7025]: INFO    Jail 'nginx' started
2018-05-09 18:15:57,560 fail2ban.jail   [7025]: INFO    Jail 'yunohost' started
2018-05-09 18:15:57,839 fail2ban.filter [7025]: ERROR   Error in FilterPyinotify callback: 'module' object has no attribute '_strptime_time'
2018-05-10 04:24:07,026 fail2ban.actions[7025]: WARNING [dovecot] Ban 37.24.153.115
2018-05-10 04:34:06,703 fail2ban.actions[7025]: WARNING [dovecot] Unban 37.24.153.115

After the last ban it never worked.

Sounds like it has to do with :

Is this “pyinotify” thing something you added manually ? (Never heard of this before)