You are not logged in.
Heyyyy people, I've installed Arch roughly 5 months ago, and since then, I am having troubles with YouTube videos, they randomly freeze and display the loading symbol, it freezes for about 30 seconds, and then it keeps playing, it happens with every browser, I've tried to clear the cache, deleted the folders of each browser in the .cache folder at home, but none of that worked, which is strange because it only happens with Linux and not with Windows, and it's kind of annoying, any ideas? currently using the amdgpu driver.
Last edited by Edgar025 (2024-12-26 23:15:53)
Offline
https://wiki.archlinux.org/title/PulseA … do_no_play ?
Please post the output of
find /etc/systemd -type l -exec test -f {} \; -print | awk -F'/' '{ printf ("%-40s | %s\n", $(NF-0), $(NF-1)) }' | sort -f
This works fine:
mpv 'https://www.youtube.com/watch?v=v2AC41dglnM' # you'll need yt-dlp
Offline
dbus-org.freedesktop.nm-dispatcher.service | system
dbus-org.freedesktop.timesync1.service | system
display-manager.service | system
getty@tty1.service | getty.target.wants
NetworkManager-wait-online.service | network-online.target.wants
NetworkManager.service | multi-user.target.wants
p11-kit-server.socket | sockets.target.wants
pipewire.socket | sockets.target.wants
pulseaudio.socket | sockets.target.wants
remote-fs.target | multi-user.target.wants
systemd-timesyncd.service | sysinit.target.wants
systemd-userdbd.socket | sockets.target.wants
xdg-user-dirs-update.service | default.target.wants
and the /etc/pulse/daemon.conf file shows;
default-sample-rate = 44100
alternate-sample-rate = 48000
Last edited by Edgar025 (2024-12-18 16:25:09)
Offline
Please use [code][/code] tags. Edit your post in this regard.
The replace pulseaudio w/ pipewire-pulse and see wheter the issue remains.
Offline
it's working like a charm now! I've been watching some videos and the problem did not occur, you are a genius, I would never have thought it was an audio related issue, thanks!!!
Offline
\o/
Please always remember to mark resolved threads by editing your initial posts subject - so others will know that there's no task left, but maybe a solution to find.
Thanks.
Offline
I was wrong, the issue is still happening but luckily not as often
Last edited by Edgar025 (2024-12-19 12:58:12)
Offline
When "still happening" what outputs do you get from
sudo fuser -v /dev/snd/*
pactl list sinks
pactl list sink-inputs
sudo journalctl -b | curl -F 'file=@-' 0x0.st
Offline
USER PID ACCESS COMMAND
/dev/snd/controlC0: edgar 753 F.... pipewire
edgar 758 F.... wireplumber
/dev/snd/controlC1: edgar 758 F.... wireplumber
/dev/snd/pcmC0D0c: edgar 753 F...m pipewire
/dev/snd/pcmC0D0p: edgar 753 F...m pipewire
/dev/snd/seq: edgar 753 F.... pipewire
Sink #56
State: RUNNING
Name: alsa_output.pci-0000_00_1f.3.analog-stereo
Description: Built-in Audio Analog Stereo
Driver: PipeWire
Sample Specification: s32le 2ch 48000Hz
Channel Map: front-left,front-right
Owner Module: 4294967295
Mute: no
Volume: front-left: 39472 / 60% / -13.21 dB, front-right: 39472 / 60% / -13.21 dB
balance 0.00
Base Volume: 65536 / 100% / 0.00 dB
Monitor Source: alsa_output.pci-0000_00_1f.3.analog-stereo.monitor
Latency: 0 usec, configured 0 usec
Flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY
Properties:
alsa.card = "0"
alsa.card_name = "HDA Intel PCH"
alsa.class = "generic"
alsa.components = "HDA:10ec0887,1458a182,00100302"
alsa.device = "0"
alsa.driver_name = "snd_hda_intel"
alsa.id = "ALC887-VD Analog"
alsa.long_card_name = "HDA Intel PCH at 0xf7f20000 irq 135"
alsa.mixer_name = "Realtek ALC887-VD"
alsa.name = "ALC887-VD Analog"
alsa.resolution_bits = "16"
alsa.subclass = "generic-mix"
alsa.subdevice = "0"
alsa.subdevice_name = "subdevice #0"
alsa.sync.id = "00000000:00000000:00000000:00000000"
api.alsa.card.longname = "HDA Intel PCH at 0xf7f20000 irq 135"
api.alsa.card.name = "HDA Intel PCH"
api.alsa.path = "front:0"
api.alsa.pcm.card = "0"
api.alsa.pcm.stream = "playback"
audio.channels = "2"
audio.position = "FL,FR"
card.profile.device = "4"
device.api = "alsa"
device.class = "sound"
device.id = "49"
device.profile.description = "Analog Stereo"
device.profile.name = "analog-stereo"
device.routes = "2"
factory.name = "api.alsa.pcm.sink"
media.class = "Audio/Sink"
device.description = "Built-in Audio"
node.name = "alsa_output.pci-0000_00_1f.3.analog-stereo"
node.nick = "ALC887-VD Analog"
node.pause-on-idle = "false"
object.path = "alsa:acp:PCH:4:playback"
port.group = "playback"
priority.driver = "1009"
priority.session = "1009"
factory.id = "19"
clock.quantum-limit = "8192"
client.id = "47"
node.driver = "true"
node.loop.name = "data-loop.0"
library.name = "audioconvert/libspa-audioconvert"
object.id = "56"
object.serial = "56"
node.max-latency = "16384/48000"
api.alsa.period-size = "1024"
api.alsa.period-num = "32"
api.alsa.headroom = "0"
api.acp.auto-port = "false"
api.acp.auto-profile = "false"
api.alsa.card = "0"
api.alsa.use-acp = "true"
api.dbus.ReserveDevice1 = "Audio0"
api.dbus.ReserveDevice1.Priority = "-20"
device.bus = "pci"
device.bus_path = "pci-0000:00:1f.3"
device.enum.api = "udev"
device.form_factor = "internal"
device.icon_name = "audio-card-analog-pci"
device.name = "alsa_card.pci-0000_00_1f.3"
device.nick = "HDA Intel PCH"
device.plugged.usec = "9299470"
device.product.id = "0xa2f0"
device.product.name = "200 Series PCH HD Audio"
device.subsystem = "sound"
sysfs.path = "/devices/pci0000:00/0000:00:1f.3/sound/card0"
device.vendor.id = "0x8086"
device.vendor.name = "Intel Corporation"
device.string = "0"
Ports:
analog-output-lineout: Line Out (type: Line, priority: 9000, availability group: Legacy 4, available)
analog-output-headphones: Headphones (type: Headphones, priority: 9900, availability group: Legacy 5, available)
Active Port: analog-output-headphones
Formats:
pcm
Sink Input #124
Driver: PipeWire
Owner Module: n/a
Client: 123
Sink: 56
Sample Specification: float32le 2ch 48000Hz
Channel Map: front-left,front-right
Format: pcm, format.sample_format = "\"float32le\"" format.rate = "48000" format.channels = "2" format.channel_map = "\"front-left,front-right\""
Corked: no
Mute: no
Volume: front-left: 64226 / 98% / -0.53 dB, front-right: 64226 / 98% / -0.53 dB
balance 0.00
Buffer Latency: 0 usec
Sink Latency: 0 usec
Resample method: PipeWire
Properties:
client.api = "pipewire-pulse"
pulse.server.type = "unix"
application.name = "Chromium"
application.process.id = "1440"
application.process.user = "edgar"
application.process.host = "archlinux"
application.process.binary = "chromium"
application.language = "C.UTF-8"
window.x11.display = ":0"
application.process.machine_id = "1e6c1b0488064a328b581f98d7c947ed"
application.process.session_id = "2"
application.icon_name = "chromium-browser"
media.name = "Playback"
node.rate = "1/48000"
node.latency = "512/48000"
stream.is-live = "true"
node.name = "Chromium"
node.want-driver = "true"
node.autoconnect = "true"
media.class = "Stream/Output/Audio"
port.group = "stream.0"
adapt.follower.spa-node = ""
object.register = "false"
factory.id = "7"
clock.quantum-limit = "8192"
node.loop.name = "data-loop.0"
library.name = "audioconvert/libspa-audioconvert"
client.id = "82"
object.id = "83"
object.serial = "124"
pulse.attr.maxlength = "4194304"
pulse.attr.tlength = "8192"
pulse.attr.prebuf = "6152"
pulse.attr.minreq = "2048"
node.driver-id = "56"
module-stream-restore.id = "sink-input-by-application-name:Chromium"
Sink Input #617
Driver: PipeWire
Owner Module: n/a
Client: 616
Sink: 56
Sample Specification: float32le 2ch 44100Hz
Channel Map: front-left,front-right
Format: pcm, format.sample_format = "\"float32le\"" format.rate = "44100" format.channels = "2" format.channel_map = "\"front-left,front-right\""
Corked: yes
Mute: no
Volume: front-left: 65535 / 100% / -0.00 dB, front-right: 65535 / 100% / -0.00 dB
balance 0.00
Buffer Latency: 0 usec
Sink Latency: 0 usec
Resample method: PipeWire
Properties:
client.api = "pipewire-pulse"
pulse.server.type = "unix"
application.name = "spotify"
application.process.id = "11540"
application.process.user = "edgar"
application.process.host = "archlinux"
application.process.binary = "spotify"
application.language = "C.UTF-8"
window.x11.display = ":0"
application.process.machine_id = "1e6c1b0488064a328b581f98d7c947ed"
application.process.session_id = "2"
media.role = "music"
media.name = "Spotify"
node.rate = "1/44100"
node.latency = "8192/44100"
stream.is-live = "true"
node.name = "spotify"
node.want-driver = "true"
node.autoconnect = "true"
media.class = "Stream/Output/Audio"
port.group = "stream.0"
adapt.follower.spa-node = ""
object.register = "false"
factory.id = "7"
clock.quantum-limit = "8192"
node.loop.name = "data-loop.0"
library.name = "audioconvert/libspa-audioconvert"
client.id = "94"
object.id = "89"
object.serial = "617"
pulse.attr.maxlength = "4194304"
pulse.attr.tlength = "640064"
pulse.attr.prebuf = "0"
pulse.attr.minreq = "7056"
module-stream-restore.id = "sink-input-by-media-role:music"
Sink Input #879
Driver: PipeWire
Owner Module: n/a
Client: 878
Sink: 56
Sample Specification: float32le 2ch 48000Hz
Channel Map: front-left,front-right
Format: pcm, format.sample_format = "\"float32le\"" format.rate = "48000" format.channels = "2" format.channel_map = "\"front-left,front-right\""
Corked: no
Mute: no
Volume: front-left: 64226 / 98% / -0.53 dB, front-right: 64226 / 98% / -0.53 dB
balance 0.00
Buffer Latency: 0 usec
Sink Latency: 0 usec
Resample method: PipeWire
Properties:
client.api = "pipewire-pulse"
pulse.server.type = "unix"
application.name = "Chromium"
application.process.id = "1440"
application.process.user = "edgar"
application.process.host = "archlinux"
application.process.binary = "chromium"
application.language = "C.UTF-8"
window.x11.display = ":0"
application.process.machine_id = "1e6c1b0488064a328b581f98d7c947ed"
application.process.session_id = "2"
application.icon_name = "chromium-browser"
media.name = "Playback"
node.rate = "1/48000"
node.latency = "1024/48000"
stream.is-live = "true"
node.name = "Chromium"
node.want-driver = "true"
node.autoconnect = "true"
media.class = "Stream/Output/Audio"
port.group = "stream.0"
adapt.follower.spa-node = ""
object.register = "false"
factory.id = "7"
clock.quantum-limit = "8192"
node.loop.name = "data-loop.0"
library.name = "audioconvert/libspa-audioconvert"
client.id = "71"
object.id = "90"
object.serial = "879"
pulse.attr.maxlength = "4194304"
pulse.attr.tlength = "16384"
pulse.attr.prebuf = "12296"
pulse.attr.minreq = "4096"
node.driver-id = "56"
module-stream-restore.id = "sink-input-by-application-name:Chromium"
Offline
Sanity checks:
Do you get freezes
1. when playing a local mp4 in the browser
2. when playing a youtube video w/ mpv (requires yt-dlp, you can just pass the youtube URL as parameter)
3. in firefox
4. when playing videos in 240p or 360p ?
Offline
I will check the list one by one
Offline
alright, I've tried most of the items
1- Playing a local video does not freeze
2- Playing a video with the command mpv URL works fine and in the command line gives the following output
● Video --vid=1 (h264 1920x1080 50 fps) [default]
● Audio --aid=1 --alang=eng (opus 2ch 48000 Hz) [default]
File tags:
Date: 20241220
Uploader: hessenschau
Channel_URL: https://www.youtube.com/channel/UCPhsnKyNcH3huafz_wNG_5A
AO: [pipewire] 48000Hz stereo 2ch floatp
VO: [gpu] 1920x1080 yuv420p
Track switched:
● Video --vid=1 (h264 [High] 1920x1080 50 fps) [default]
○ Audio --aid=1 --alang=eng (opus 2ch 48000 Hz) [default]
Track switched:
● Video --vid=1 (h264 [High] 1920x1080 50 fps) [default]
● Audio --aid=1 --alang=eng (opus 2ch 48000 Hz) [default]
AO: [pipewire] 48000Hz stereo 2ch floatp
[ffmpeg] tls: Error in the pull function.
[ffmpeg] tls: IO error: Connection reset by peer
[ffmpeg] https: Will reconnect at 1294881 in 0 second(s), error=Connection reset by peer.
AV: 00:02:37 / 00:02:43 (96%) A-V: 0.000 Cache: 5.5s/1018KB
Exiting... (Quit)
[edgar@archlinux ~]$ mpv https://www.youtube.com/watch?v=Je22SgH8TCk
● Video --vid=1 (av1 640x360 30 fps) [default]
● Audio --aid=1 --alang=eng (opus 2ch 48000 Hz) [default]
File tags:
Date: 20150326
Uploader: Bibliothek der Sachgeschichten
Channel_URL: https://www.youtube.com/channel/UC-AqkKGLHRbEnhIvYGarysA
AO: [pipewire] 48000Hz stereo 2ch floatp
VO: [gpu] 640x360 yuv420p
[input] No key binding found for key 'n'.
AV: 00:10:53 / 00:10:54 (100%) A-V: 0.000 Cache: 0.9s/56KB
Exiting... (Quit)
4- Videos playing at 360p get freeze
Offline
Does video playback in yewtu.be freeze?
Offline
on yewtu.be everything works fine, no freeze so far
Offline
Adblocker related?
Tried to play youtube.com in the por… private mode of your browser (w/ extensions disabled and lots of ads)?
Offline
adblocker is disabled on youtube since I have youtube premium so I don't need it, I'll try it on incognito mode and report you the result
Offline
playing on incognito mode hasn't changed anything :,( mannn it's so frustrating because ironically I am most of the time on youtube watching videos
Offline
Can you tether your phone's internet to your pc and see if the problem exists with different connection. I hear Youtube is ramping up anti scraping protections perhaps your IP is getting throttled
Last edited by ugjka (2024-12-21 21:25:33)
Offline
* Playing a video with the command mpv URL works fine
* Videos playing at 360p get freeze
It's probably something on the youtube site itself, stat counter comments, etc.?
Aynthing showing up in the performance tool of your browsers web inspector?
Speaking of which: did you actually check the FF performance?
Offline
* Playing a video with the command mpv URL works fine
* Videos playing at 360p get freezeIt's probably something on the youtube site itself, stat counter comments, etc.?
Aynthing showing up in the performance tool of your browsers web inspector?
Speaking of which: did you actually check the FF performance?
I don't use Firefox because it hangs at random times, and videos freeze on every browser I've tried, including Brave, I've changed a couple of items in the chromium performance settings, I suspect it's a graphics card's driver related issue because it all started to happen when I switched to archlinux
Offline
videos freeze on every browser I've tried, including Brave
Which are all blink/chromium though?
Please *test* firefox, nobody's telling you to swear off some religion but we want to isolate the problem as much as possible.
I suspect it's a graphics card's driver related issue because
* it doesn't affect mpv ?
* it doesn't affect yewtu.be ?
* it does affect 360p videos which you could play on 10% of one core ?
Offline
videos freeze on every browser I've tried, including Brave
Which are all blink/chromium though?
Please *test* firefox, nobody's telling you to swear off some religion but we want to isolate the problem as much as possible.I suspect it's a graphics card's driver related issue because
* it doesn't affect mpv ?
* it doesn't affect yewtu.be ?
* it does affect 360p videos which you could play on 10% of one core ?
I've tried the following browsers: Microsoft Edge, Firefox, Chrome, Chromium, Brave and it's all the same story
but I will give Firefox a try again although it hangs at times, not only while playing videos but also browsing the web in general
Offline
Ftr: Microsoft Edge, Chrome, Chromium, Brave are effectively all the same browser.
Let's say you're hitting this w/ FF as well, check the web inspector for the limiting factor, largest consumer (likely network or RAM, maybe CPU, increadibly unlikely the GPU)
Also try to log out of youtube and watch the videos like a peasant, ie. with an adblocker
Btw: does the original stall duration of ~30s remain after replacing PA or has the nature of the freeze shifted in any way?
Offline
you have a point! I will be trying Firefox again and I'll report to you later
Offline
Alright I've been testing Firefox these days and it works pretty decently (better than chromium/chrome), not 100% but I have to accept that open source is not 100% perfect, I'll mark the issue as solved, thanks for your time
Last edited by Edgar025 (2024-12-26 23:16:18)
Offline