[Bug 1236619] Re: gvfs smb / cifs file copy performance is terribly slow

2020-06-02 Thread Jean-Pierre van Riel
Apologies, launchpad didn't keep the neatly tab separated column format,
but hopefully the script can help others to test.

Attached png of side-by-side comparison of script output.

Only the latency for accessing a single 4K block doesn't seem to differ
too much, but for every other mult-block sequential IO read, in terms of
latency, bandwidth and IOPS, GVFS is over 10 times slower than CIFS.

While I know fuse mounts (userspace filesystems) will be understandably
slower than kernel space mounts, more than 10 times slower is
significant and indicates there's inefficiencies / room for improvement.

** Attachment added: "GVFS-SMB vs CIFS"
   
https://bugs.launchpad.net/ubuntu/+source/gvfs/+bug/1236619/+attachment/5379760/+files/gvfs-smb_vs_cifs_seq_read_benchmark_ubuntu_18.04.4.png

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gvfs in Ubuntu.
https://bugs.launchpad.net/bugs/1236619

Title:
  gvfs smb / cifs file copy performance is terribly slow

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gvfs/+bug/1236619/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1236619] Re: gvfs smb / cifs file copy performance is terribly slow

2020-06-02 Thread Jean-Pierre van Riel
Hi, to report, also noticed gvfs smb mount being over 10x slower in many
cases depending on the read IO pattern. Seems GVFS alls a lot of
latency. Summary of benchmark via fio:

GVFS SMB:
=

name  type  size  block_size  latency_(ms) bandwidth_(kb)  IOPS
      --   --  
4k_4k_seq_readread  4k4k  7.597604 100 25
512k_4k_seq_read  read  512k  4k  12.608847148437  312 
78.001219
4m_64k_seq_read   read  4m64k 58.59852259375   1082
16.91779
8m_256k_seq_read  read  8m256k252.2923598125   1010
3.948667
16m_1m_seq_read   read  16m   1m  1079.9320893125  946 
0.924481

CIFS:
=

name  type  size  block_size  latency_(ms)bandwidth_(kb)  IOPS
      --  --  
4k_4k_seq_readread  4k4k  7.226365250 62.5
512k_4k_seq_read  read  512k  4k  0.35290271875   9481
2370.37037
4m_64k_seq_read   read  4m64k 4.14038503125   15003   
234.432234
8m_256k_seq_read  read  8m256k17.80018796875  14148   
55.267703
16m_1m_seq_read   read  16m   1m  83.7329983125   12145   
11.860638

Bash script to test this (depends on fio, jq and column)

#json_benchmark_result_summary=''
tempfile=$(mktemp /tmp/read_test..ndjson)
echo "# Using temp file: $tempfile"

function seq_read_benchmark() {
  local total_size="$1"
  local block_size="$2"
  echo "# Testing sequential read of $total_size size in $block_size."
  sleep 1
  fio --name="${total_size}_${block_size}_seq_read" 
--filename="${total_size}_${block_size}_seq_read_test.bin" --rw=read 
--iodepth=1 --max-jobs=1 --size="$total_size" --bs="$block_size" 
--output-format=json >> "$tempfile"
  rm "${total_size}_${block_size}_seq_read_test.bin"
}

seq_read_benchmark 4k 4k  # 1 block read
seq_read_benchmark 512k 4k  # 128 x 4k blocks read
seq_read_benchmark 4m 64k  # 64 x 64k blocks read
seq_read_benchmark 8m 256k  # 32 x 128k blocks read
seq_read_benchmark 16m 1m # 16 x 1m blocks read

# Reshaping JSON with jq: 
https://programminghistorian.org/en/lessons/json-and-jq#output-a-csv-csv
# How to format a JSON string as a table using jq?: 
https://stackoverflow.com/a/39144364/5472444
jq -s -r 
'(["name","type","size","block_size","latency_(ms)","bandwidth_(kb)","IOPS"] | 
(., map(length*"-"))), (.[] | .jobs[] | [.jobname, ."job options".rw, ."job 
options".size, ."job options".bs, (.read.lat_ns.mean/100), .read.bw, 
.read.iops]) | @tsv' "$tempfile" | column -t

# Convert JSON lines to JSON array using jq: 
https://stackoverflow.com/a/61867230/5472444
#jq -s '[.[] | .jobs[] | {name: .jobname, type: ."job options".rw, size: ."job 
options".size, "block size": ."job options".bs, "latency (ms)": 
(.read.lat_ns.mean/100), "bandwidth (kb)": .read.bw, IOPS: .read.iops}]' 
"$tempfile" > read_test_summary.json

# Cleanup
rm "$tempfile"

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gvfs in Ubuntu.
https://bugs.launchpad.net/bugs/1236619

Title:
  gvfs smb / cifs file copy performance is terribly slow

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gvfs/+bug/1236619/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1716857] Re: nvidia-drm.modeset=1, gdm3 and optimus laptop results in no external monitors detected by Xorg

2020-05-03 Thread Jean-Pierre van Riel
Another correction. For the one workaround, switching to discrete
graphics in the BIOS only seemed to get past the initial gnome login.
But resuming from DPMS off/suspend, the same error loop happens even
when hybrid graphics is disabled in the BIOS.

Even worse, seems hardware acceleration ends up being disabled:

$ journalctl --no-hostname -b -p warning _COMM=gnome-shell
-- Logs begin at Wed 2019-02-06 14:13:52 SAST, end at Sun 2020-05-03 16:09:45 
SAST. --
May 03 14:51:40 org.gnome.Shell.desktop[2284]: glamor: 'wl_drm' not supported
May 03 14:51:40 org.gnome.Shell.desktop[2284]: Missing Wayland requirements for 
glamor GBM backend
May 03 14:51:40 org.gnome.Shell.desktop[2284]: Failed to initialize glamor, 
falling back to sw
...
May 03 14:53:25 gnome-shell[6549]: setup_framebuffers: assertion 'width > 0' 
failed

The "EGL failed to allocate resources" error stops happening probably
because gnome-shell isn't even using hardware acceleration now.

I've also disabled all gnome shell extensions to avoid noise/errors in
the logs and will try weed out the problem better.

I checked `grep -C2 -E '(EE)|(WW)' /var/log/Xorg.0.log` and things seem
fine:

[45.181] (II) NVIDIA dlloader X Driver  440.59  Thu Jan 30 01:08:17 UTC 2020
[45.181] (II) NVIDIA Unified Driver for all Supported NVIDIA GPUs
--
[45.182] (II) LoadModule: "ramdac"
[45.182] (II) Module "ramdac" already built-in
[45.183] (WW) Falling back to old probe method for modesetting
[45.183] (II) NVIDIA(0): Creating default Display subsection in Screen 
section
"Default Screen Section" for depth/fbbpp 24/32
--
[46.392] (==) NVIDIA(0): Silken mouse enabled
[46.392] (==) NVIDIA(0): DPMS enabled
[46.393] (WW) NVIDIA(0): Option "PrimaryGPU" is not used
[46.393] (II) Loading sub module "dri2"
[46.393] (II) LoadModule: "dri2"

Note, I've done no customisation to X config - trying to stick to
defaults.

xrandr confirms only one provider / hybrid is indeed off and Intel not
in use:

$ xrandr --listproviders 
Providers: number : 1
Provider 0: id: 0x218 cap: 0x1, Source Output crtcs: 4 outputs: 6 associated 
providers: 0 name:NVIDIA-0

I'm guessing the Lenovo P53 impliments a mux/switch to connect the
laptop panel to the NVidia card so that Intel is disabled in this mode.

And double checking, also no i915 modules are loaded:

$ lsmod | grep '^drm'
drm_kms_helper180224  1 nvidia_drm
drm   491520  10 drm_kms_helper,nvidia_drm

So there seems to be, on current Ubuntu 18.04.4 LTS (fully up to date as
of today), a 4K / UHD 60Hz issue with Nvidia, as seen in X log

[45.228] (II) NVIDIA GLX Module  440.59  Thu Jan 30 01:05:38 UTC
2020

Lastly, I think due to `needs_root_rights=yes` in
/etc/X11/Xwrapper.config, X logs to /var/log/Xorg.0.log again instead of
the X without root which used to log at  ~/.local/share/xorg/Xorg.0.log

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gdm3 in Ubuntu.
https://bugs.launchpad.net/bugs/1716857

Title:
  nvidia-drm.modeset=1, gdm3 and optimus laptop results in no external
  monitors detected by Xorg

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gdm3/+bug/1716857/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1716857] Re: nvidia-drm.modeset=1, gdm3 and optimus laptop results in no external monitors detected by Xorg

2020-05-03 Thread Jean-Pierre van Riel
Here's the script I run to workaround the intital failure of gnome to
use the external display after unlocking or resuming from DPMS
suspend/off.

** Attachment added: "fix-hdmi-uhd.sh"
   
https://bugs.launchpad.net/ubuntu/+source/gdm3/+bug/1716857/+attachment/5365719/+files/fix-hdmi-uhd.sh

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gdm3 in Ubuntu.
https://bugs.launchpad.net/bugs/1716857

Title:
  nvidia-drm.modeset=1, gdm3 and optimus laptop results in no external
  monitors detected by Xorg

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gdm3/+bug/1716857/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1716857] Re: nvidia-drm.modeset=1, gdm3 and optimus laptop results in no external monitors detected by Xorg

2020-05-03 Thread Jean-Pierre van Riel
Apologies, continuing the comment above (mistakenly posted when adding
the log attachment). Let me retry.

Failure loop observed:

- Failed to blit shared framebuffer: EGL failed to allocate resources for the 
requested operation.
- Failed to set CRTC mode 3840x2160: No such file or directory

To summarise and share my experience of it on a Lenovo P53 and some
quirks/workarounds:

- `sudo ubuntu-drivers autoinstall` got Nvidia 440.59 drivers installed.
- However, Nvidia modeset was not enabled as yet.

$ sudo cat /sys/module/nvidia_drm/parameters/modeset
N

- Blank external screen occurs with modeset=0 (disabled)
- Then, using `prime-select nvidia`, I tried to ensure nvidia was primary
- `prime-select nvidia` sets `options nvidia-drm modeset=1` but it's not 
effective, even after I rebooted

~$ cat /lib/modprobe.d/nvidia-kms.conf
# This file was generated by nvidia-prime
# Set value to 0 to disable modesetting
options nvidia-drm modeset=1

- To make it effective, because modeset is done during initramfs part of boot, 
I ran `sudo update-initramfs -u -k all`. 
- It seems the prime-select option fails to trigger a intiramfs update 
(probably should be filed as a separate bug)
- Regardless, the blank screen issue occured on my Lenovo P53 with or without 
Nvidia KMS modeset enabled
- But one benefit of KMS modeset for Nvida is now the external display gets 
properly recognised.  /sys/class/drm/card1-HDMI-A-1/ now exists (was missing 
with Ubuntu 18.04.4 LTS default proprietary install) including the EDID data 
being read properly and X getting the actual DPI of the screen correctly.

Without nvidia modeset, as seen in `journalctl -b _COMM=gdm-x-session |
grep -C2 -E '(EE)|(WW)'`:

(WW) NVIDIA(0): Unable to get display device for DPI computation.

With nvidia modeset:

(II) NVIDIA(0): Validated MetaModes:
(II) NVIDIA(0): "DFP-3:nvidia-auto-select"
(II) NVIDIA(0): Virtual screen size determined to be 3840 x 2160
(--) NVIDIA(0): DPI set to (139, 140); computed from "UseEdidDpi" X config

I've also found two workarounds to my issue.

1. Run a script that sets the frequency to 30HZ and then back to 60HZ
2. Switch to discrete only graphics in the BIOS

In most cases, when one is using a 2nd display, there's usually a
powersource available so the complexity of hybrid graphics isn't worth
it and I went with simply disabling hybrid graphics in the BIOS.

It's quite interesting that toggling the display refresh rate down to
30HZ and then back up to 60HZ seems to work around the problem of gnome-
shell mutter's "EGL failed to allocate resources for the requested
operation" bug.

To conclude, even with the root access workaround in place:

$ tail -n 2 /etc/X11/Xwrapper.config
# Added by xserver-xorg-video-nvidia-440
needs_root_rights=yes

I still had external display connection issues with 4K 60Hz.

This might need to be logged as different bug? I'm unsure it's GDM3s
fault given the root workaround was in place, but it's highly
related/similar.

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gdm3 in Ubuntu.
https://bugs.launchpad.net/bugs/1716857

Title:
  nvidia-drm.modeset=1, gdm3 and optimus laptop results in no external
  monitors detected by Xorg

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gdm3/+bug/1716857/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1716857] Re: nvidia-drm.modeset=1, gdm3 and optimus laptop results in no external monitors detected by Xorg

2020-05-03 Thread Jean-Pierre van Riel
Hi, thanks to everyone, especially Daniel for unpacking this issue.

I have had a very similar issue, where gnome shell fails to run my
external 4K/UHD display at 60HZ and I see the following failure loop
triggered in  `journalctl -b -p warning _COMM=gnome-shell`:

May 02 20:39:38 JNBA434499PLL gnome-shell[1957]: Failed to blit shared 
framebuffer: EGL failed to allocate resources for the requested operation.
May 02 20:39:38 JNBA434499PLL gnome-shell[1957]: Failed to set CRTC mode 
3840x2160: No such file or directory
May 02 20:39:38 JNBA434499PLL gnome-shell[1957]: Failed to flip: Device or 
resource busy
May 02 20:39:38 JNBA434499PLL gnome-shell[1957]: Failed to set CRTC mode 
3840x2160: No such file or directory
May 02 20:39:38 JNBA434499PLL gnome-shell[1957]: Failed to blit shared 
framebuffer: EGL failed to allocate resources for the requested operation.
May 02 20:39:38 JNBA434499PLL gnome-shell[1957]: Failed to set CRTC mode 
3840x2160: No such file or directory
May 02 20:39:38 JNBA434499PLL gnome-shell[1957]: Failed to blit shared 
framebuffer: EGL failed to allocate resources for the requested operation.
May 02 20:39:38 JNBA434499PLL gnome-shell[1957]: Failed to set CRTC mode 
3840x2160: No such file or directory
...


 While not sure it's exactly the same, it should still inform the
overall discussion about dealing with GDM3 + Mutter + proprietary Nvidia
drivers modeset problems.

To summarise and share my experience of it on a Lenovo P53 and some
quirks/workarounds:

- `sudo ubuntu-drivers autoinstall` got Nvidia 440.59 drivers installed.
- However, Nvidia modeset was not enabled as yet. 

$ sudo cat /sys/module/nvidia_drm/parameters/modeset
N

-

- Using prime-select

- For laptops like mine, seems the external port is connected to the Nvidia GPU.
- Using the proprietary Nvidia drivers seems to then bump into a 


** Attachment added: "gnome-shell_journal_warnings_egl_resource_failed.txt"
   
https://bugs.launchpad.net/ubuntu/+source/gdm3/+bug/1716857/+attachment/5365716/+files/gnome-shell_journal_warnings_egl_resource_failed.txt

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gdm3 in Ubuntu.
https://bugs.launchpad.net/bugs/1716857

Title:
  nvidia-drm.modeset=1, gdm3 and optimus laptop results in no external
  monitors detected by Xorg

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gdm3/+bug/1716857/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1774904] Re: No defualt sound. Test speakers not working.

2019-02-27 Thread Jean-Pierre van Riel
Hi, in my case, I think it was simply a missing package dependency.
Installing the libcanberra-pulse package fixed it for me.

gnome-control should probably add libcanberra-pulse to a proper
dependency rather than just recommends since it's likely common that
people would want to test speakers and the test silently failing (e.g.
control-centre doesn't even warn its missing the libs it needs) makes a
user (me for example) get lost (i.e. inspecting ALSA, etc) when the
silent test failure misleads.

Also noted at the end of: https://bugs.launchpad.net/ubuntu/+source
/gnome-media/+bug/736349

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-control-center in Ubuntu.
https://bugs.launchpad.net/bugs/1774904

Title:
  No defualt sound. Test speakers not working.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-control-center/+bug/1774904/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1732450] Re: Lock screen doesn't respect gnome shell theme choice

2019-02-17 Thread Jean-Pierre van Riel
** Also affects: gnome-session (Ubuntu)
   Importance: Undecided
   Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-session in Ubuntu.
https://bugs.launchpad.net/bugs/1732450

Title:
  Lock screen doesn't respect gnome shell theme choice

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnome-shell/+bug/1732450/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1715722] Re: Allow safe override of GDM3 theme

2019-02-17 Thread Jean-Pierre van Riel
I've noticed in 18.04.2 (upgraded from 16.04 LTS), with gnome-shell
3.28.3-0ubuntu0.18.04.4 and ubuntu-session 3.28.1-0ubuntu3, the *lock*
screen is still pinning to /usr/share/gnome-shell/theme/ubuntu.css.
Note, the login session screen is using the correct theme.

This is related: https://bugs.launchpad.net/ubuntu/+source/gnome-
shell/+bug/1732450.

As per https://bugs.launchpad.net/ubuntu/+source/gnome-
shell/+bug/1732450/comments/5, the nasty I did to work around it shows
the gdm3 / session lock screen theme is still pointed directly to
/usr/share/gnome-shell/theme/ubuntu.css instead of /usr/share/gnome-
shell/theme/gdm3.css.

I also checked the alternative symlinking, and indeed, `pop.css` was
supposed to be used, yet the lock screen used ubuntu.css.

```
$ update-alternatives --display gdm3.css
gdm3.css - auto mode
  link best version is /usr/share/gnome-shell/theme/pop.css
  link currently points to /usr/share/gnome-shell/theme/pop.css
  link gdm3.css is /usr/share/gnome-shell/theme/gdm3.css
/usr/share/gnome-shell/theme/pop.css - priority 20
/usr/share/gnome-shell/theme/ubuntu.css - priority 10
```

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-shell in Ubuntu.
https://bugs.launchpad.net/bugs/1715722

Title:
  Allow safe override of GDM3 theme

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnome-shell/+bug/1715722/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1732450] Re: Lock screen doesn't respect gnome shell theme choice

2019-02-17 Thread Jean-Pierre van Riel
I roughly understand this issue might be something to do with ubuntu-
session package hard configuring the gdm login screen to use ubuntu.css?

Is this not a sub-effect / possible duplicate bug of:
https://bugs.launchpad.net/ubuntu/+source/gnome-shell/+bug/1715722 ?

Also see: https://github.com/pop-os/gtk-theme/issues/123

I did this very dodgy hack:

```
cd /usr/share/gnome-shell/theme
sudo mv ubuntu.css ubuntu.css.bak-dist_1804
sudo ln -s pop.css ubuntu.css
```

Note, I don't symlink `ubuntu.css` to `gdm3.css`, because this might
cause circular referencing if the default theme was selected given this
is how symlinks could stack:

/usr/share/gnome-shell/theme/gdm3.css -> /etc/alternatives/gdm3.css ->
/usr/share/gnome-shell/theme/ubuntu.css


Anyhow, the above is temp work-around, and I know that ubuntu.css will get 
clobbered next time the gnome-shell-common package updates, but so be it.

** Bug watch added: github.com/pop-os/gtk-theme/issues #123
   https://github.com/pop-os/gtk-theme/issues/123

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-shell in Ubuntu.
https://bugs.launchpad.net/bugs/1732450

Title:
  Lock screen doesn't respect gnome shell theme choice

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnome-shell/+bug/1732450/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs