WSL: WSL2 - GUI Chrome example doesn't work
Version
Microsoft Windows [Version 10.0.22000.376]
WSL Version
- WSL 2
- WSL 1
Kernel Version
5.10.60.1-microsoft-standard-WSL2
Distro Version
Ubuntu 20.04
Other Software
No response
Repro Steps
- Follow this link https://docs.microsoft.com/en-us/windows/wsl/tutorials/gui-apps#install-google-chrome-for-linux to download & install chrome
- Run Chrome.
❯ google-chrome
[0106/195412.988599:ERROR:file_io_posix.cc(144)] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2)
[0106/195412.988637:ERROR:file_io_posix.cc(144)] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq: No such file or directory (2)
[1] 15843 trace trap google-chrome
Expected Behavior
Chrome launches?
Actual Behavior
Getting error.
Diagnostic Logs
No response
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 4
- Comments: 34
I did the same. I did a
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deband then
sudo apt install ./google-chrome-stable_current_amd64.debBut running either google-chrome or google-chrome-stable is giving me the same error mentioned by @shinebayar-g .
Any fix possible ?
Thanks.
Can you check if using wayland solves the issue ?
If its running then:
wsl -v)?Can’t really ignore them, as the errors result in the google-chrome process terminating, IIRC.
@shinebayar-g enable those options is not advisable. WSL kernel can’t manage the CPU, it’s just a Windows process. Here’s output from a WSL Ubuntu instance:
and Chrome works fine. There are a bunch of errors on launch related to
dbussince it’s not running. Here’s Chrome with your GitHub bug showing:What I did different was using apt to install the package. This way all dependencies are resolved at installation time:
sudo apt install ./google-chrome-stable_current_amd64.debI tried the same as well @elsaco , just to see what the feedback is. I got this message logged :
[21:21:0217/094950.009879:VERBOSE1:chrome_crash_reporter_client.cc(191)] GetCollectStatsConsent(): settings_consent: 0 so returning that [21:21:0217/094950.025942:VERBOSE1:chrome_crash_reporter_client.cc(191)] GetCollectStatsConsent(): settings_consent: 0 so returning that [1:1:0217/094950.077132:VERBOSE1:cdm_registration.cc(225)] Registering bundled Widevine 4.10.2391.0 [36:36:0217/094950.077112:VERBOSE1:cdm_registration.cc(225)] Registering bundled Widevine 4.10.2391.0 [1:1:0217/094950.082114:INFO:cpu_info.cc(53)] Available number of cores: 16 [36:36:0217/094950.082114:INFO:cpu_info.cc(53)] Available number of cores: 16 [1:1:0217/094950.082548:VERBOSE1:zygote_main_linux.cc(217)] ZygoteMain: initializing 2 fork delegates [36:36:0217/094950.082476:VERBOSE1:zygote_main_linux.cc(217)] ZygoteMain: initializing 0 fork delegates [1:1:0217/094950.085778:VERBOSE1:nacl_fork_delegate_linux.cc(153)] NaClForkDelegate::Init() [1:1:0217/094950.116669:VERBOSE1:nacl_fork_delegate_linux.cc(153)] NaClForkDelegate::Init() [21:21:0217/094950.155754:VERBOSE1:chrome_browser_cloud_management_controller.cc(86)] DM token = none [21:21:0217/094950.155812:VERBOSE1:chrome_browser_cloud_management_controller.cc(92)] Enrollment token = [21:21:0217/094950.155818:VERBOSE1:chrome_browser_cloud_management_controller.cc(93)] Client ID = QSlVC9KTzny1790KGxGn8QELTVYHowever, the browser window doesn’t open up in my case and I am unsure as on to how to proceed / interpret this log message to fix this issue.
Same issue with microsoft-edge-beta_98.0.1108.27-1_amd64.deb exact same error msg
$ microsoft-edge [0125/133112.740044:ERROR:file_io_posix.cc(144)] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq: No such file or directory (2) [0125/133112.740130:ERROR:file_io_posix.cc(144)] open /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq: No such file or directory (2) Trace/breakpoint trap
wsl --list --verbose NAME STATE VERSION Ubuntu-20.04 Running 2
Both Chrome and Edge still doesn’t work unless launched with args as “–ozone-platform=wayland” like @kedevked mentions Looking forward to be resolved let me @AwesomeYuer know
@andrew-baker-oneadvanced in the case of google-chrome process terminating there must be something else beside those
cpufreqstartup errors. Here’s a list of all the Chrome errors on my WLS instance, most of them due to non-working dbus service:However, the browser window opens up and if functional:
To gather more information use
google-chrome --enable-logging --v=1and feedback will be logged in.config/google-chrome/chrome-debug.logfile. Verbosity can be increased for even more feedback.Seems like you’ve been facing https://github.com/microsoft/wslg/issues/820 and the fix is already available as Pre-release. See here as the workaround for now.
Which version of chrome are you running? I had this problem on v98, but after updating to v99 it worked again