Domaine non accessible depuis install/desinstall pi-hole

Activer/désactiver le DHCP avec Pi-Hole ?

Il serait intéressant de se concentrer sur dnsmasq, ce n’est pas normal qu’il ne démarre pas.
Donc il faut le redémarrer puis regarder les logs.

C’est sur ma box OVH que j’ai désactivé/réactivé le DHCP

root@misantrope:/etc/dnsmasq.d# service dnsmasq status
● dnsmasq.service - dnsmasq - A lightweight DHCP and caching DNS server
Loaded: loaded (/lib/systemd/system/dnsmasq.service; enabled)
Drop-In: /run/systemd/generator/dnsmasq.service.d
└─50-dnsmasq-$named.conf, 50-insserv.conf-$named.conf
Active: active (running) since Sat 2018-02-03 13:01:32 UTC; 21min ago
Process: 3110 ExecStop=/etc/init.d/dnsmasq systemd-stop-resolvconf (code=exited, status=0/SUCCESS)
Process: 3237 ExecStartPost=/etc/init.d/dnsmasq systemd-start-resolvconf (code=exited, status=0/SUCCESS)
Process: 3229 ExecStart=/etc/init.d/dnsmasq systemd-exec (code=exited, status=0/SUCCESS)
Process: 3226 ExecStartPre=/usr/sbin/dnsmasq --test (code=exited, status=0/SUCCESS)
Main PID: 3236 (dnsmasq)
CGroup: /system.slice/dnsmasq.service
└─3236 /usr/sbin/dnsmasq -x /var/run/dnsmasq/dnsmasq.pid -u dnsmasq -7 /etc/dnsmasq.d,.dpkg-dist,.dpkg-old,.dpkg-new --local-service --trust-…

Feb 03 13:01:32 misantrope.org dnsmasq[3236]: using nameserver 80.67.169.12#53
Feb 03 13:01:32 misantrope.org dnsmasq[3236]: using nameserver 89.233.43.71#53
Feb 03 13:01:32 misantrope.org dnsmasq[3236]: using nameserver 85.214.20.141#53
Feb 03 13:01:32 misantrope.org dnsmasq[3236]: using nameserver 84.200.70.40#53
Feb 03 13:01:32 misantrope.org dnsmasq[3236]: using nameserver 91.239.100.100#53
Feb 03 13:01:32 misantrope.org dnsmasq[3236]: using nameserver 213.73.91.35#53
Feb 03 13:01:32 misantrope.org dnsmasq[3236]: using nameserver 89.234.186.18#53
Feb 03 13:01:32 misantrope.org dnsmasq[3236]: using nameserver 84.200.69.80#53
Feb 03 13:01:32 misantrope.org dnsmasq[3236]: read /etc/hosts - 5 addresses
Feb 03 13:01:32 misantrope.org systemd[1]: Started dnsmasq - A lightweight DHCP and caching DNS server.

:pensive:
Dnsmasq fonctionne très bien là…

Et si tu tentes un dig yunohost.org ?

root@misantrope:/etc/dnsmasq.d# dig yunohost.org

; <<>> DiG 9.9.5-9+deb8u15-Raspbian <<>> yunohost.org
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 10564
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;yunohost.org. IN A

;; ANSWER SECTION:
yunohost.org. 36 IN A 91.224.148.92

;; Query time: 53 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Sat Feb 03 13:26:23 UTC 2018
;; MSG SIZE rcvd: 57

A première vue tout fonctionne normalement.
Quid d’un ping yunohost.org ?

root@misantrope:/etc/dnsmasq.d# ping yunohost.org
PING yunohost.org (91.224.148.92) 56(84) bytes of data.
64 bytes from 91-224-148-92.tetaneutral.net (91.224.148.92): icmp_seq=1 ttl=58 time=56.6 ms

Donc ton YunoHost n’a pas de problème pour accéder à internet…

Le soucis que tu rencontres est donc, si j’ai bien compris, que tu peux accéder à ton YunoHost depuis ton réseau local, mais pas depuis l’extérieur ?

Yep c’est bien ca

Dans un tel cas la responsabilité est plutôt à chercher du côté de ton routeur ou de ta config dns publique.

Ton ip est 151.127.33.195 ?
Le cas échéant, c’est du côté de ton routeur qu’il faut chercher une mauvaise config

Yep c’est bien mon ip mais le routeur a été reinitialisé. Désolé de t’avoir fait chercher pour rien

Yosh!

J’ai donc une instance toute fraiche et a jour, un certificat SSL sur mon RPI3 et impossible d’installer Pi-Hole.
Est-il préférable de désactiver le DHCP sur la box avant l’install?

J’ai trouvé ca :

_common.sh: line 569: mail: command not found

Moulinette

Sur raspi, il faut installer le paquet mailutils pour avoir la commande mail.

J’ai installé mailutils et j’ai eu ca a la fin :

*** Please tell me who you are.

Run

git config --global user.email “you@example.com
git config --global user.name “Your Name”

to set your account’s default identity.
Omit --global to set the identity only in this repository.

fatal: unable to auto-detect email address (got ‘root@YunoHost.(none)’)
warning: etckeeper failed to commit changes in /etc using git

Par la suite j’ai installé Pihole puis de nouveau une erreur :

systemctl start dsnmasq
Job for dnsmasq.service failed. See’Sytem, etc

Donc sur systemctl status dnsmasq.service j’ai

● dnsmasq.service - dnsmasq - A lightweight DHCP and caching DNS server
Loaded: loaded (/lib/systemd/system/dnsmasq.service; enabled)
Drop-In: /run/systemd/generator/dnsmasq.service.d
└─50-dnsmasq-$named.conf, 50-insserv.conf-$named.conf
Active: active (running) since Sun 2018-02-04 22:50:14 UTC; 2min 7s ago
Process: 28994 ExecStartPost=/etc/init.d/dnsmasq systemd-start-resolvconf (code=exited, status=0/SUCCESS)
Process: 28985 ExecStart=/etc/init.d/dnsmasq systemd-exec (code=exited, status=0/SUCCESS)
Process: 28981 ExecStartPre=/usr/sbin/dnsmasq --test (code=exited, status=0/SUCCESS)
Main PID: 28993 (dnsmasq)
CGroup: /system.slice/dnsmasq.service
└─28993 /usr/sbin/dnsmasq -x /var/run/dnsmasq/dnsmasq.pid -u dnsmasq -7 /etc/dnsmasq.d,.dpkg-dist,.dpkg-old,.dpkg-new --loca…

Feb 04 22:50:14 YunoHost dnsmasq[28993]: using nameserver 80.67.188.188#53
Feb 04 22:50:14 YunoHost dnsmasq[28993]: using nameserver 80.67.169.40#53
Feb 04 22:50:14 YunoHost dnsmasq[28993]: using nameserver 141.255.128.101#53
Feb 04 22:50:14 YunoHost dnsmasq[28993]: using nameserver 141.255.128.100#53
Feb 04 22:50:14 YunoHost dnsmasq[28993]: using nameserver 91.239.100.100#53
Feb 04 22:50:14 YunoHost dnsmasq[28993]: using nameserver 89.234.141.66#53
Feb 04 22:50:14 YunoHost dnsmasq[28993]: using nameserver 80.67.169.12#53
Feb 04 22:50:14 YunoHost dnsmasq[28993]: using nameserver 84.200.70.40#53
Feb 04 22:50:14 YunoHost dnsmasq[28993]: read /etc/hosts - 5 addresses
Feb 04 22:50:14 YunoHost systemd[1]: Started dnsmasq - A lightweight DHCP and caching DNS server.

puis journalctl -xn j’ai :

root@YunoHost:~# journalctl -xn
– Logs begin at Wed 2017-01-25 19:26:56 UTC, end at Sun 2018-02-04 22:50:15 UTC. –
Feb 04 22:50:14 YunoHost slapd[26142]: <= mdb_equality_candidates: (sudoUser) not indexed
Feb 04 22:50:14 YunoHost slapd[26142]: <= mdb_equality_candidates: (sudoUser) not indexed
Feb 04 22:50:14 YunoHost slapd[26142]: <= mdb_equality_candidates: (sudoUser) not indexed
Feb 04 22:50:14 YunoHost slapd[26142]: <= mdb_substring_candidates: (sudoUser) not indexed
Feb 04 22:50:14 YunoHost sudo[29113]: root : TTY=unknown ; PWD=/var/cache/yunohost/from_file/pihole_ynh-64c24546378341b756e93f2155c95144ed05de42/scripts ; USER=root ; COMMAND=/
Feb 04 22:50:14 YunoHost sudo[29113]: pam_unix(sudo:session): session opened for user root by (uid=0)
Feb 04 22:50:14 YunoHost userdel[29117]: delete user ‘pihole’
Feb 04 22:50:14 YunoHost userdel[29117]: removed group ‘pihole’ owned by ‘pihole’
Feb 04 22:50:14 YunoHost userdel[29117]: removed shadow group ‘pihole’ owned by ‘pihole’
Feb 04 22:50:15 YunoHost sudo[29113]: pam_unix(sudo:session): session closed for user root

Le problème c’est que journalctl -xn est une commande inutile, et malheureusement c’est celle qui est conseillée…
Pour avoir le log il faut utiliser journalctl -u dnsmasq

Le serveur n’était plus accessible ce matin. J’ai donc reinstaller Yunohost et mailutils mais cette fois-ci je n’ai pas choisit (contrairement a hier soir) d’activer le serveur DHCP sur pi-hole. Donc cela fonctionne nikel.

Pour le reste il va falloir que je me renseigne un peu plus sur les config notamment si je laisse pihole gerer le DHCP.

En te remerciant :slight_smile: