User Tools

Site Tools


distros:ubuntu_desktop

This is an old revision of the document!


Information

  • Ubuntu 1)
  • Desktop 2)

Download

HOSTS

wget -O '/tmp/hosts-tmp' 'https://raw.githubusercontent.com/StevenBlack/hosts/master/alternates/fakenews-gambling/hosts' && sudo cp '/etc/hosts' '/etc/hosts-bak' && sudo mv '/tmp/hosts-tmp' '/etc/hosts' && sync
cat '/etc/hosts' | grep 'Date:'
sudo -e '/etc/hosts'

Software

Update

System

sudo apt update && sudo apt full-upgrade -y && sudo apt autoremove -y && sudo apt clean && sync

Firmware

sudo fwupdmgr refresh --force && sudo fwupdmgr update --verbose

Snaps

sudo snap refresh

General

sudo apt install evolution filezilla gimp keepassxc mpv transmission-gtk aria2 htop unar p7zip-full mesa-utils ffmpeg libsecret-tools lm-sensors libreoffice rhythmbox 

OpenVPN

network-manager-openvpn-gnome

ckb-next

Wine

wine winetricks

Tor Browser

torbrowser-launcher

Keybase

  • :!: This needs ran as a separate command and not combined with the above package installations
rm -Rf '/tmp/keybase_amd64.deb' && wget -O '/tmp/keybase_amd64.deb' 'https://prerelease.keybase.io/keybase_amd64.deb' && sudo apt install '/tmp/keybase_amd64.deb' && rm '/tmp/keybase_amd64.deb' && sync && run_keybase

Google Chrome

  • :!: TODO: This may need updated to run with apt instead of dpkg
wget -O '/tmp/google-chrome-stable_current_amd64.deb' 'https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb' && sudo dpkg --install '/tmp/google-chrome-stable_current_amd64.deb' || sudo apt install -f && rm '/tmp/google-chrome-stable_current_amd64.deb' && sync

Settings

Keyboard Shortcuts

bash -c "secret-tool lookup 'keepass' 'default' | keepassxc --pw-stdin ~/'Documents/keepass.kdbx'"
gnome-terminal --command "sudo sh -c 'apt update && apt full-upgrade -y && apt clean && apt autoremove -y && sync && snap refresh && wget -O '/etc/hosts' 'https://raw.githubusercontent.com/StevenBlack/hosts/master/alternates/fakenews-gambling/hosts' && sync && fstrim --all --verbose && sync && sleep '5''"

Keys

  • Listed respectively to above
  • Ctrl + Alt + Z
  • Pause or F7

Printer

  • HP OfficeJet Pro 8710, driverless, cups-filters
  • Print Color Mode: Device Gray
  • Administration → Set As Server Default
socket://192.168.1.164:9100

gedit

  • 4 Tab width
  • Insert Spaces for Tab mode

Network

Cloudflare

1.1.1.1,1.0.0.1
2606:4700:4700::1111,2606:4700:4700::1001

VPN.AC

  • See VPN.AC
  • :!: If using this VPN, disable IPv6 from NetworkManager

Rhythmbox

Terminal

  • 10-notch Transparency

GRUB

Config

sudo -e '/etc/default/grub' && sudo update-grub

amdgpu

  • Allows use of Overdrive options for overclocking and notably increasing the Power Limit
amdgpu.ppfeaturemask=0xffffffff

Verify

cat '/sys/module/amdgpu/parameters/ppfeaturemask' | grep '4294967295'

GNOME

Settings

All-in-one

  • Last updated: 2021/10/29
 gsettings set 'org.gnome.desktop.interface' 'enable-animations' 'false' && gsettings set 'org.gnome.desktop.peripherals.touchpad' 'send-events' 'disabled-on-external-mouse' && gsettings set 'org.gnome.desktop.peripherals.touchpad' 'natural-scroll' 'false' && gsettings set 'org.gnome.desktop.peripherals.mouse' 'accel-profile' 'flat' && gsettings set 'org.gnome.desktop.peripherals.touchpad' 'tap-to-click' 'false' && gsettings set 'org.gnome.desktop.peripherals.touchpad' 'tap-and-drag' 'false' && gsettings set 'org.gnome.desktop.peripherals.touchpad' 'disable-while-typing' 'false' && gsettings set 'org.gnome.desktop.peripherals.touchpad' 'click-method' 'areas' && gsettings set 'org.gnome.desktop.interface' 'clock-show-date' 'true' && gsettings set 'org.gnome.desktop.interface' 'clock-show-weekday' 'true'
gsettings set 'org.gnome.software' 'download-updates' 'false'
gsettings reset 'org.gnome.shell' 'app-picker-layout'

Individual

  • Last updated: 2021/10/29
gsettings set 'org.gnome.desktop.interface' 'enable-animations' 'false'
gsettings set 'org.gnome.desktop.peripherals.touchpad' 'send-events' 'disabled-on-external-mouse'
gsettings set 'org.gnome.desktop.peripherals.touchpad' 'natural-scroll' 'false'
gsettings set 'org.gnome.desktop.peripherals.mouse' 'accel-profile' 'flat'
gsettings set 'org.gnome.desktop.peripherals.touchpad' 'tap-to-click' 'false'
gsettings set 'org.gnome.desktop.peripherals.touchpad' 'tap-and-drag' 'false'
gsettings set 'org.gnome.desktop.peripherals.touchpad' 'disable-while-typing' 'false'
gsettings set 'org.gnome.desktop.peripherals.touchpad' 'click-method' 'areas'
gsettings set 'org.gnome.desktop.interface' 'clock-show-date' 'true'
gsettings set 'org.gnome.desktop.interface' 'clock-show-weekday' 'true'
Other
  • The first depend on GNOME Software existing
  • The second needs GNOME 40+ and isn't applicable on Ubuntu 21.04
gsettings set 'org.gnome.software' 'download-updates' 'false'
gsettings reset 'org.gnome.shell' 'app-picker-layout'

Hostname

  • Change x to computer name
hostnamectl set-hostname 'x'

Keybase

  • :!: Run after initial install
run_keybase

KeePassXC

Settings

  • General → [ ] Load previous databases on startup
  • Security → [x] Use DuckDuckGo service to download website icons

Add Database Password to GNOME Keyring

secret-tool store --label='KeePass' 'keepass' 'default'

lm_sensors

  • --auto is quicker, but more things are detected by doing the full scan
sudo sensors-detect
sudo sensors-detect --auto

mpv

mkdir -p ~/'.config/mpv' && nano ~/'.config/mpv/mpv.conf'
profile=gpu-hq
scale=ewa_lanczossharp
cscale=ewa_lanczossharp
video-sync=display-resample
interpolation
tscale=oversample

NetworkManager

  • wifi.powersave can be 2 for disabled, or 3 for enabled
  • :!: ethernet.cloned-mac-address=random breaks USB Tethering with iOS/iPhones
sudo -e '/etc/NetworkManager/conf.d/99-custom.conf'
[device-mac-randomization]
wifi.scan-rand-mac-address=yes

[connection-mac-randomization]
wifi.cloned-mac-address=random

[connection]
wifi.powersave=2
[connection-mac-randomization]
ethernet.cloned-mac-address=random

Laptop Power Management

Secure Shell

  • See Client notes to generate/restore public key

Uncomplicated Firewall

  • See ufw for more notes
sudo ufw reset && sudo ufw default deny && sudo ufw logging off && sudo ufw enable && sudo systemctl enable 'ufw'
sudo ufw allow 'ssh'

Drive Maintenance

Trim

  • :!: Enable only if a SSD is being used for Linux
sudo systemctl enable 'fstrim.timer' --now && sudo systemctl start 'fstrim' && sync && sudo systemctl status 'fstrim' -l

XFS Scrub

  • :!: This is only necessary if XFS is being used on any persistent drives, and requires xfsprogs to be installed
sudo apt install 'xfsprogs' -y && sync
sudo systemctl enable 'xfs_scrub_all.timer' --now && sudo systemctl start 'xfs_scrub_all' && sync && sudo systemctl status 'xfs_scrub_all' -l

UTC

  • Set RTC to UTC
  • :!: Needed if Windows is installed first
  • :!: Windows should also be set to UTC
sudo timedatectl set-local-rtc '0'

Verify

timedatectl | grep local

Wine

Xorg

Nightwane

  • :!: With Fedora 34 as of 2021/05/12, the amdgpu Xorg DDX driver has the screen more warm/yellowish and breaks calibration
  • :!: This doesn't happen with modesetting on Xorg, nor at all with GNOME on Wayland
  • Since amdgpu is installed and used by-default on Xorg, removing it causes modesetting to be used instead
  • :!: TODO: Test if this is necessary on Ubuntu 21.04+
sudo apt remove 'xserver-xorg-video-amdgpu' && sync

Mozilla Firefox

  • See Firefox if old configuration is needed, otherwise use Firefox Sync

Server

  • For workstations that run servers as a secondary directive
  • For headless servers, use Ubuntu Server

Automatic Updates

Service

sudo -e '/etc/systemd/system/ubuntu-up.service'
[Service]
Type=oneshot
ExecStartPre='/usr/bin/apt' clean
ExecStart='/usr/bin/apt' update
ExecStart='/usr/bin/apt' full-upgrade -y
ExecStart='/usr/bin/apt' autoremove -y
ExecStartPost='/usr/bin/sync'
ExecStartPost='/usr/bin/systemctl' reboot

Timer

  • 03:00 Oak
sudo -e '/etc/systemd/system/ubuntu-up.timer' && sudo systemctl daemon-reload && sudo systemctl enable 'ubuntu-up.timer' --now
[Unit]
Description=Software Package Maintenance and Updater
After=network-online.target
Wants=network-online.target

[Timer]
OnCalendar=*-*-* 03:00:00
Persistent=true

[Install]
WantedBy=timers.target
/var/www/wiki/data/attic/distros/ubuntu_desktop.1635552003.txt.gz · Last modified: 2021/10/29 20:00 by Sean Rhone