HP RGS (Remote Graphics Software) Audio Troubleshooting in Linux

This document applies to administrators using HP RGS (sender). This is tested with version 7.7 but likely works with previous versions.

The only information I found online is a single Customer Advisory by HP:
HP Remote Graphics Software (RGS) - RGS audio does not work on RHEL6 or SLED11 systems for users with NFS mounted home directories due to root_squash option:

https://support.hp.com/ca-en/document/c06061809

This is pretty similar to what I have been facing, although we are using CentOS 7.6.

These are the steps I followed to get the audio working over RGS:

1. Added a Bash login script. Either ~/.bash_profile or ~/.bashrc

PULSE_DIR="/tmp/$( whoami )-pulse"
mkdir -p $PULSE_DIR && chmod 700 $PULSE_DIR
export PULSE_CONFIG_PATH=$PULSE_DIR
export PULSE_STATE_PATH=$PULSE_DIR
export PULSE_RUNTIME_PATH=$PULSE_DIR

This should move all PulseAudio sockets and tmp files off the network (~/.pulse/) and on the local hard drive.

2. Edit this file: /etc/opt/hpremote/rgsender/rgsenderconfig

This is the default config file for the RGS application on the Sender. Much of this can be left alone out of the box but the audio section required these changes to work in our environment:
Rgsender.Audio.IsEnabled=1
Rgsender.Audio.Linux.DeviceName=plughw:Loopback,1
Rgsender.Audio.Linux.RecorderApi=alsa

3. Edit the PuleAudio config file: /etc/pulse/default.pa
### Make some devices default
set-default-sink output alsa_output.platform-snd_aloop.0.analog-stereo
This will make your dummy device the default output device. After this, in Gnome Setttings > Sound, you *should* have the dummy loopback audio card listed as an output source.



Alternatively, this command should immediately set the default audio output to the dummy:
$ pactl set-default-sink 'alsa_output.platform-snd_aloop.0.analog-stereo'

4. Inserting the kernel module!

For whatever reason, even on identical HP Z workstations, there was no guarantee the dummy output kernel module was being inserted. First, check if it is:
$ lsmod | grep snd | grep aloop
It should return a similar result if already inserted:
snd_aloop	23337  5
If not, insert it yourself!:
$ sudo insmod /lib/modules/3.10.0-957.1.3.el7.x86_64/kernel/sound/drivers/snd-aloop.ko.xz
Keep in mind, the kernel version above may vary.




Authour: %MW - Orgburo Communications - March, 2020