Compare commits

...

7 Commits

Author SHA1 Message Date
Milk.H f11bbe07b3 Merge pull request 'dns' (#2) from dns into main
Reviewed-on: #2
2023-01-18 11:29:39 +01:00
Milk.H 09c54c5d15 Merge branch 'main' into dns 2023-01-18 11:29:29 +01:00
Milk.H 98bbe721a8 Update 'dns/dnsmasq.md' 2023-01-18 11:28:12 +01:00
Milk.H 2addc0d117 Upload files to 'dns/images' 2023-01-18 11:24:32 +01:00
Milk.H 032318d5b6 Update 'dns/dnsmasq.md' 2023-01-18 11:24:10 +01:00
Milk.H f6ba03c80f Upload files to 'dns/images' 2023-01-18 11:18:31 +01:00
Milk.H 49c2cae2d4 added dns files 2023-01-18 11:10:59 +01:00
5 changed files with 73 additions and 0 deletions

73
dns/dnsmasq.md Normal file
View File

@ -0,0 +1,73 @@
disable named and systemd-resolved
<img src="images/dnsmasq.webp" alt="dnsmasq" width="250"/>
# DNS server auf Ubuntu mit Dnsmasq
Dnsmasq ist ein sehr Lightweight DNS server für Linux BetriebsSysteme
## Installieren sie dnsmasq und Nginx
wir machen ein update von das System dan werden wir beide Software installieren
```bash
sudo apt-get update && sudo apt-get upgrade
sudo apt-get install nginx dnsmasq
```
## Services ausschalten
```bash
sudo systemctl disable systemd-resolved
sudo systemctl disable named
sudo systemctl stop systemd-resolved
sudo systemctl stop named
```
### neue Resolv.conf file
```bash
sudo unlink /etc/resolv.conf
echo nameserver 8.8.8.8 | sudo tee /etc/resolv.conf
```
### dnsmasq neustarten
```bash
sudo systemctl restart dnsmasq
sudo systemctl status dnsmasq
```
### /etc/hosts file ändern
für DNS entries nimmt dnsmasq entries vom die datei /etc/hosts
machen sie eine neue Entry
```bash
sudo nano /etc/hosts
```
wenn ihre Server IP addresse änders ist setzen sie `192.168.100.1` als die server isolated IP addresse
```
our.server.ch 192.168.100.1
```
# Unser server als DNS einsetzen im windows
## mit isc-dhcp-server
![in DHCP doku](https://got.milkte.ch/milk/M123_Doku/src/branch/main/dhcp/ubuntu.md#isc-dhcp-server-installation-und-konfiguration)
im ubuntu isc-dhcp-server Doku setzen wir `domain-name-servers als 192.168.100.1`
## im Windows
im windows können wir das DNS manuel ändern durch ipv4 Konfiguration
![Windows ipv4 Konfiguration](images/dnsConf.png)
## nginx webserver
nginx ist ein Webserver, wir brauchen keine Configuration für die TestSeite
```bash
sudo systemctl start nginx
sudo systemctl enable nginx
```
gehen sie zu der Windows Virtuelle machine and öffnen sie ein Browser, geben sie ein http://our.server.ch, wenn sie es richtig gemacht haben kommen sie ein zu der NGinx test site
![nginx webserver auf dem domain "our.server.ch"](images/NGINX.png)
sie konnen auch pingen mit der Domain
![Pingen mit CMD](images/ping.png)

BIN
dns/images/NGINX.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

BIN
dns/images/dnsConf.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

BIN
dns/images/dnsmasq.webp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

BIN
dns/images/ping.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB