distros:fedora_server
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
distros:fedora_server [2023/07/15 14:21] – I love writing commands like that :p Sean Rhone | distros:fedora_server [2024/02/01 14:36] – Sean Rhone | ||
---|---|---|---|
Line 2: | Line 2: | ||
* Fedora Server ((https:// | * Fedora Server ((https:// | ||
- | * 30 | + | * 39 |
+ | |||
+ | ====== Installation Notes ====== | ||
+ | |||
+ | * Do not create a separate '' | ||
====== Download ====== | ====== Download ====== | ||
* https:// | * https:// | ||
+ | |||
+ | ====== PackageKit ====== | ||
+ | |||
+ | * :!: PackageKit was caught using hundreds of MB of RAM while not actively using it ((PackageKit was using 600MB idle on a 8GB server '' | ||
+ | * Apparently it only provides the package name for commands not found | ||
+ | |||
+ | sudo dnf remove PackageKit* | ||
+ | |||
+ | ====== HOSTS ====== | ||
+ | |||
+ | * https:// | ||
+ | * Unified hosts + fakenews + gambling + porn + social | ||
+ | |||
+ | ===== Initial ===== | ||
+ | |||
+ | * Only run once | ||
+ | |||
+ | ls '/ | ||
+ | |||
+ | ===== Update ===== | ||
+ | |||
+ | **** | ||
+ | |||
+ | ls '/ | ||
+ | |||
+ | ===== Restore Backup ===== | ||
+ | |||
+ | **** | ||
+ | |||
+ | ls '/ | ||
====== DNF ====== | ====== DNF ====== | ||
Line 12: | Line 46: | ||
* Disables Delta RPMs with '' | * Disables Delta RPMs with '' | ||
- | | + | echo ' |
+ | |||
+ | sudo -e '/ | ||
====== Software ====== | ====== Software ====== | ||
===== Update ===== | ===== Update ===== | ||
+ | |||
+ | * :!: See [[distros: | ||
+ | |||
+ | sudo dnf autoremove -y && sudo dnf distro-sync -y && sync | ||
+ | |||
+ | ===== Firmware ===== | ||
**** | **** | ||
- | sudo dnf clean ' | + | sudo fwupdmgr refresh |
===== GNU nano ===== | ===== GNU nano ===== | ||
Line 32: | Line 74: | ||
===== General ===== | ===== General ===== | ||
- | | + | |
- | p7zip unar aria2 | + | |
policycoreutils-devel | policycoreutils-devel | ||
- | ====== Laptop Server | + | ====== Settings ====== |
+ | |||
+ | ===== Laptop Server ===== | ||
* This tells '' | * This tells '' | ||
Line 46: | Line 90: | ||
sudo -e '/ | sudo -e '/ | ||
- | ====== USB Backups ====== | + | ===== Network |
- | ===== Drive Mount ===== | + | ==== Anaconda |
- | * Expects single-partition flash drive with ext4 | + | * [[notes:dns_servers# |
- | * TODO: If multiple drives beyond sda main and sdb USB are ever involved, use UUID instead | + | |
- | sudo mkdir -p '/mnt/ | + | < |
- | # USB Backup | + | < |
- | | + | |
- | ===== Service ===== | + | ==== systemd-resolved |
- | | + | |
+ | * [[notes: | ||
- | | + | |
- | Type=oneshot | + | |
- | ExecStart='/usr/bin/rsync' -r '/home/espionage724/backups' | + | |
- | ===== Timer ===== | + | < |
+ | [Resolve] | ||
+ | DNS=9.9.9.9# | ||
+ | DNSOverTLS=yes</ | ||
- | * See server-specific configurations to make use of this | + | === NetworkManager === |
- | | + | |
- | | + | |
- | Description=USB Backup | + | |
- | + | ||
- | [Timer] | + | |
- | OnCalendar=*-*-* 04:00:00 | + | |
- | Persistent=true | + | |
- | + | ||
- | [Install] | + | |
- | WantedBy=timers.target | + | |
- | ===== SELinux ===== | + | sudo nmcli connection modify ' |
- | ==== Switch to Permissive ==== | + | sudo nmcli connection modify ' |
- | **** | + | ===== Hostname ===== |
- | | + | |
+ | * Likely not needed if set through Anaconda | ||
- | ==== Clear Audit Log ==== | + | hostnamectl set-hostname ' |
- | su | + | ===== lm_sensors ===== |
- | | + | |
- | ==== Start Services ==== | + | sudo -e '/ |
- | **** | + | ===== Secure Shell ===== |
- | | + | |
- | ==== Create Policy | + | ===== Drive Maintenance ===== |
- | **** | + | ==== Trim ==== |
- | + | ||
- | sudo audit2allow -a -M ' | + | |
- | + | ||
- | ==== Install Policy | + | |
**** | **** | ||
- | sudo semodule -i 'usb-b.pp' | + | sudo systemctl enable |
- | ==== Switch to Enforcing | + | ===== UTC ===== |
- | **** | + | |
+ | | ||
- | sudo setenforce | + | sudo timedatectl set-local-rtc |
- | ==== Clean Up ==== | + | ==== Verify |
**** | **** | ||
- | | + | |
====== Automatic Updates ====== | ====== Automatic Updates ====== | ||
===== Service ===== | ===== Service ===== | ||
- | |||
- | * TODO: If this ever fails because of the modular repo not being available, look into auto-restart | ||
sudo -e '/ | sudo -e '/ | ||
Line 145: | Line 177: | ||
===== Timer ===== | ===== Timer ===== | ||
- | * 06:10 Kraityn | + | * '' |
- | * 06:20 Alira | + | |
- | * 06:30 Oak | + | |
sudo -e '/ | sudo -e '/ | ||
Line 158: | Line 188: | ||
[Timer] | [Timer] | ||
- | OnCalendar=*-*-* | + | OnCalendar=*-*-* |
Persistent=true | Persistent=true | ||
Line 166: | Line 196: | ||
====== Notable Folders and Commands ====== | ====== Notable Folders and Commands ====== | ||
- | ===== YUM/DNF Repos ===== | + | |
- | + | ||
- | **** | + | |
- | + | ||
- | / | + | |
- | + | ||
- | ===== fstrim ===== | + | |
- | + | ||
- | **** | + | |
- | + | ||
- | sudo fstrim -v --all | + | |
- | + | ||
- | ===== SELinux Re-label ===== | + | |
- | + | ||
- | **** | + | |
- | + | ||
- | sudo touch '/ | + | |
- | + | ||
- | ===== Show CPU Frequency ===== | + | |
- | + | ||
- | grep ' | + | |
- | + | ||
- | watch -n 0.1 grep \'cpu MHz\' '/ | + | |
- | + | ||
- | ===== Partition Information ===== | + | |
- | + | ||
- | **** | + | |
- | + | ||
- | df -hT | + | |
- | + | ||
- | ===== Optimal GCC compiler flags ===== | + | |
- | + | ||
- | **** | + | |
- | + | ||
- | gcc -v -E -x c -march=native -mtune=native - < /dev/null 2>&1 | grep cc1 | perl -pe 's/ -mno-\S+// | + | |
- | + | ||
- | ===== FirewallD ===== | + | |
- | + | ||
- | ==== List Active Rules ==== | + | |
- | + | ||
- | **** | + | |
- | + | ||
- | sudo firewall-cmd --list-all | + | |
- | + | ||
- | ==== List Available Services ==== | + | |
- | + | ||
- | **** | + | |
- | + | ||
- | sudo firewall-cmd --get-service | + | |
- | + | ||
- | ==== Reload ==== | + | |
- | + | ||
- | **** | + | |
- | + | ||
- | sudo firewall-cmd --reload | + | |
- | + | ||
- | ==== Add/Remove Service ==== | + | |
- | + | ||
- | * Add '' | + | |
- | + | ||
- | sudo firewall-cmd --add-service=x | + | |
- | + | ||
- | sudo firewall-cmd --remove-service=x | + | |
- | + | ||
- | ==== Add/Remove Port ==== | + | |
- | * Add '' | + | ===== Firewalld ===== |
- | * Change '' | + | |
- | | + | |
- | sudo firewall-cmd --remove-port=x/ |
/var/www/wiki/data/pages/distros/fedora_server.txt · Last modified: 2024/05/10 22:03 by Sean Rhone