Ping All Ips in a Subnet

Ping all Ip’s in a Subnet

bash: for i in $(seq 1 254); do ping -c1 -t 1 192.168.11.$i; done

namp:

nmap -n -sP 10.0.0.0/24

Tags: bash, cli, ping, nmap

[Read more]

How to Delete Varlogjournal

How to delete /var/log/journal

Yes you can delete everything inside of /var/log/journal/* but do not delete the directory itself. You can also query journalctl to find out how much disk space it’s consuming:

$ journalctl –disk-usage Journals take up 3.8G on disk. You can control the size of this directory using this parameter in your /etc/systemd/journald.conf:

SystemMaxUse=50M You can force a log rotation:

$ sudo systemctl kill –kill-who=main –signal=SIGUSR2 systemd-journald.service NOTE: You might need to restart the logging service to force a log rotation, if the above signaling method does not do it. You can restart the service like so:

[Read more]

Change Prometheus Interface

Change Prometheus Interface

On some Boxes i have Prometheus listen on IPv6 and i also only want to use the Internal IP Addresses.

/etc/systemd/system/prometheus-node-exporter.conf

[Service] Environment=ARGS=–web.listen-address=x.x.x.x:9101

Tags: monitoring, prometheus

[Read more]

Docker_cheatsheet

docker cheatsheet

docker version – zeigt die version an

docker search – sucht

docker pull – holt sich den container

docker run CONTAINER PROGRAMM – startet PROGRAMM in CONTAINER

docker run learn/tutorial apt-get install -y ping

First use docker ps -l to find the ID of the container you created by installing ping.

docker commit 698 learn/ping

docker run learn/ping ping google.com

docker inspect efe

docker images

docker push

docker push learn/ping

[Read more]