Tips & Tricks

Here are some general tips and tricks to get the best out of your Linux experience

AMD Users:

You do not have to install any drivers. Just use what comes with the kernel and you’ll be golden. However, if you want the latest drivers and you’re on a release modeled distro (updates 6-12 mos.) use this PPA:

Open terminal and enter these commands:
sudo add-apt-repository ppa:paulo-miguel-dias/pkppa
sudo apt-get update

Manjaro/Arch/Antergos

Install Trizen (Arch User Repository tool)

$ git clone https://aur.archlinux.org/trizen-git.git
$ cd trizen-git
$ makepkg -si

Install NextCloud Sync Client

$ sudo pacman -S nextcloud-client

Install Network Tools Like Ex: Host

Like bind-utils in Debian based distro

$ sudo pacman -S bind-tools

$sudo pacman -S net-tools

Install For Network Drive Compatibility

$ sudo pacman -S smb4k
$ sudo pacman -S samba

$ sudo pacman -S gvfs-smb *allow Nautilus to connect to SMB servers*

Install Steam in Arch

Enable Multilib

$sudo nano /etc/pacman.conf

In the file you will see a line matching the below. Remove the # symbol from both lines. CTRL + x and save.

[multilib] 
Include = /etc/pacman.d/mirrorlist

Now run $ sudo pacman -Syu
Now sudo pacman -Ss steam (you will see steam now as an option to install)

SSH Key Errors

sign_and_send_pubkey: signing failed: agent refused operation

The file permissions are too open (0644).

The following command will solve it:

chmod 600 ~/.ssh/id_rsa

Pulse Audio & USB Audio Interface Fix

Pulse audio works great for most basic audio applications. However, with USB audio interfaces it’s defaults can cause issues with static or buzzing. Below are the instructions to fix that issue. Special thanks to the Arch Wiki for providing the core of the fix.


First type the below command and get the buffer size and fragment size

$ pactl list sinks

Note relevant buffer size and fragment size

Example pactl list sinks results Scarlett USB Interface 2i2

device.buffering.buffer_size = “705600”
device.buffering.fragment_size = “352800”

So default for PULSE is 44100 @16bits

44100 * 16 = 705600
BUT
we need Stereo so let’s multiple by 2 = 1,411,200 bps

So let’s divide our buffer size by the 1411200

device.buffering.buffer_size :: 705600/1411200 = 0.5 = 500ms
device.buffering.fragment_size :: 352800/1411200 = 0.25 = 250ms

But this is stereo so let’s divide buffer size by fragment size 500/250 = 2

Now let’s edit the config
device buffering buffer size 2 & buffering fragment size 250

$ sudo nano /etc/pulse/daemon.conf

default-fragments = 4
default-fragment-size-msec = 25

change to 2 & 250

remove the ‘;’ in front of the lines you change.

pulseaudio -k
pulseaudio -start

——————Other changes to Daemon.conf———————-

; daemonize = no
; fail = yes
; allow-module-loading = yes
; allow-exit = yes
; use-pid-file = yes
; system-instance = no
; local-server-type = user
; enable-shm = yes
; enable-memfd = yes
; shm-size-bytes = 0 # setting this 0 will use the system-default, usually 64 MiB
; lock-memory = no
; cpu-limit = no

high-priority = yes
nice-level = -15

realtime-scheduling = yes
realtime-priority = 5

; exit-idle-time = 20
; scache-idle-time = 20

; dl-search-path = (depends on architecture)

; load-default-script-file = yes
; default-script-file = /etc/pulse/default.pa

; log-target = auto
; log-level = notice
; log-meta = no
; log-time = no
; log-backtrace = 0

resample-method = speex-float-5
; avoid-resampling = false
; enable-remixing = yes
; remixing-use-all-sink-channels = yes
; enable-lfe-remixing = no
; lfe-crossover-freq = 0

flat-volumes = no

rlimit-fsize = -1
rlimit-data = -1
rlimit-stack = -1
rlimit-core = -1
rlimit-as = -1
rlimit-rss = -1
rlimit-nproc = -1
rlimit-nofile = 256
rlimit-memlock = -1
rlimit-locks = -1
rlimit-sigpending = -1
rlimit-msgqueue = -1
rlimit-nice = 31
rlimit-rtprio = 9
rlimit-rttime = 200000

default-sample-format = s24le
default-sample-rate = 96000
alternate-sample-rate = 44000
default-sample-channels = 2
default-channel-map = front-left,front-right

default-fragments = 2
default-fragment-size-msec = 250

enable-deferred-volume = yes
deferred-volume-safety-margin-usec = 1
deferred-volume-extra-delay-usec = 0