This commit is contained in:
aidan 2025-02-23 23:26:52 -05:00
commit aa991e46e7
5 changed files with 20 additions and 0 deletions

2
apu.sh Normal file
View File

@ -0,0 +1,2 @@
sudo prime-select intel
sudo systemctl restart gdm3

13
checkVPN.sh Normal file
View File

@ -0,0 +1,13 @@
# Script checks if openvpn connection is alive by curling from VPN server host with 3 sec timeout
#!/bin/bash
# Check if VPN connection established
curl 10.8.0.1 -m 3
# Check the exit status
if [ $? -eq 0 ]; then
echo "Connection is alive"
else
sudo systemctl restart openvpn@client
echo "VPN Connection reset$?."
fi

2
gpu.sh Normal file
View File

@ -0,0 +1,2 @@
sudo prime-select nvidia
sudo systemctl restart gdm3

1
gpu_state Normal file
View File

@ -0,0 +1 @@
cat /sys/bus/pci/devices/0000:01:00.0/power_state

2
kill-gpu-processes Normal file
View File

@ -0,0 +1,2 @@
# Kill all processes running on any nvidia gpu on the system
kill $(nvidia-smi | awk '$5=="PID" {p=1} p {print $5}')