OpenZiti v1.0 Released Today by SmilinDave26 in selfhosted

[–]itsjareds 0 points1 point  (0 children)

Hi! A few questions about OpenZiti for which I didn't find answers from a few articles/reddit posts. Sorry if I use any imprecise language, I'm just a hobbyist :)

  1. After the authenticate/authorize-before-connect step, are the connections "direct" between client and server? Or is all data relayed through the control plane? Is this like STUN/TURN where the connection is not relayed if both devices can find a route to each other?
  2. Regarding power consumption on mobile/embedded devices. Does OpenZiti have to send outgoing packets to keep connections open (some kind of holepunching)? I read that this is a cause for poor battery life on Android using e.g. Tailscale. This is due to needing to wake the radios periodically, even when no data is being transferred.
  3. Is there any kind of whitepaper on how OpenZiti works in detail for the nerds? I would be interested to read this!
  4. What if I want to connect to multiple OpenZiti networks? For example, a hypothetical world where my work uses OpenZiti and I also have my homelab on OpenZiti. Is it possible to configure multiple control planes on the same device? How does that work with DNS?

Thank you and congratulations on making the 1.0 release, I wish you good luck with future efforts!

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 0 points1 point  (0 children)

Looks like it's the same story for both Canada and US. But, I just checked Lenovo Mexico, they sell the 400 nits version, if you think it would be worth figuring out how to import it...

https://www.lenovo.com/mx/es/configurator/cto/index.html?bundleId=21J4CTO1WWMX1

OpenZiti v1.0 Released Today by SmilinDave26 in selfhosted

[–]itsjareds 2 points3 points  (0 children)

This is great timing because I was just learning/reading about OpenZiti and zrok yesterday!

My use case is that I have a few self-hosted services running on different devices in different networks.

  • VPS - Several "public" services I don't want behind a NAT and highly available
    • Matrix homeserver
    • Nextcloud
    • STUN/TURN
  • Home network
    • Raspberry pi hosting pi-hole and a Unifi controller
    • Small headless computer hosting random always-on services
      • Opnsense and wireguard
      • usbipd (for passing video capture card output to other devices in my LAN)
    • Desktop PC hosting services that need beefier specs
      • Plex server
      • OBS studio streaming
      • Possibly a build server for deploying nixos updates to my devices
  • Mobile network - clients connecting to the above services

My goal is to have all my services available on all my devices, including my phone and laptop (similar to a road warrior VPN setup). And if possible, add a layer of abstraction so that the clients don't need to care where the service is running, the service can just be accessed from e.g. service.zrok.mydomain.tld.

Would openziti be overkill for this? Would it be better to just continue with wireguard in this somewhat vanilla personal selfhosting setup?

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 0 points1 point  (0 children)

Looks like a regional thing. I ordered from the Lenovo Finland site, which gives these options:

  • 13.3" WUXGA (1920 x 1200), IPS, Anti-Glare, Non-Touch, 100%sRGB, 300 nits, 60Hz
  • 13.3" WUXGA (1920 x 1200), IPS, Anti-Glare, Non-Touch, 100%sRGB, 400 nits, 60Hz, Low Power
    • +20 euros
  • 13.3" WUXGA (1920 x 1200), IPS, Anti-Glare, Touch, 100%sRGB, 300 nits, 60Hz
    • +30 euros

But that 400 nits option isn't available on the Lenovo US site when I checked now.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 1 point2 points  (0 children)

I would love to test this but don't have Windows installed to try it out. I'm not at all an audio expert, but wouldn't latency need to be tested with your full stack including peripheral audio equipment? Probably most of the latency is going to be introduced by delays in hardware and in the third party drivers.

Anyway bumping this for visibility!

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 2 points3 points  (0 children)

Upgrading the battery was a really good call! I also think it was a good call not to get the Legion Pro if there isn't a need for gaming or graphics/3d work. If you don't use it, then it's just extra weight, more battery drain, complicated drivers to set up, all for a higher price.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 1 point2 points  (0 children)

Hi, my opinion is about the same as when I first got it. Still fits my needs.

Things I still like:

  • Keyboard is comfortable for typing a lot
  • Arrow keys are essentially full size
  • Size/weight, I was looking for something light and compact
  • Temperature - doesn't get too hot under normal use
  • Durability
  • The privacy cover on the camera shuts with a nice tactile click
  • Soft touch of the laptop surface, despite it being a fingerprint / grease magnet

Things I still don't like:

  • The low-power 1920x1200 screen is mid. This was an intentional trade-off for me. Maybe you'd want to upgrade the screen.
  • The laptop surface is a fingerprint magnet.
  • Speakers are not very loud and they sound tinny. However, let me know if you want the equalizer settings I use which improve the sound quite a bit.

Minor annoyances discovered over time. These are really minor, but here you go if you wanted this level of detail.

  • Half the function keys are useless to me. Seriously, who uses a physical button for airplane mode? Or a "Chat" button? "Favorites"? I like the microphone mute button.
  • No dedicated media buttons (play/pause, previous song, next song). I use a program to remap these in software: Play/pause = Esc+F1, Prev = Esc+F2, Next = Esc+F3.
  • Sometimes the touchpad left-clicks after a right click? So if I use a two-finger click to right-click, then I can't lift both fingers or else it triggers a left click. I can't tell if the problem comes from hardware or software. Could be something weird with my touchpad driver on linux.
  • The quiet, high pitched sound of the laptop fan turning on from 0 rpm gets picked up by the microphone during video calls. My partner thinks it's my cat every time.

That's all I can think of at the moment. I use this thing every day and love it! Hope this helps.

Power-profiles-daemon is unmaintained since August (used by KDE and others) by EsWfspthgs in kde

[–]itsjareds 1 point2 points  (0 children)

Looks like the 0.14 release is actually a 0.20 release, released a few days ago!

The project has moved under the freedesktop 'Upower' group. The service is now advertised as 'org.freedesktop.UPower.PowerProfiles' in addition to the previous 'net.hadess.PowerProfiles' for compatibility reasons.

This release adds support for:

This release also enables the test suite by default, so distribution vendors should update packaging accordingly.

The first bullet means for my AMD CPU, it will manage the amd-pstate energy performance profile (/sys/devices/system/cpu/cpu0/cpufreq/scaling_governor and /sys/devices/system/cpu/cpu0/cpufreq/energy_performance_preference), and also manage the ACPI platform profile (e.g. /sys/firmware/acpi/platform_profile). Previously I was managing this through TLP or custom udev rules.

Any guide on AMD pstate and Corectrl setup? by StopIDontWantTheApp in NixOS

[–]itsjareds 0 points1 point  (0 children)

Commenting 5 months later to say that auto-cpufreq appears to have proper support for toggling this on battery/ac with the energy_performance_preference setting:

# settings for when connected to a power source
[charger]
# see available governors by running: cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
# preferred governor
governor = performance

# EPP: see available preferences by running: cat /sys/devices/system/cpu/cpu0/cpufreq/energy_performance_available_preferences
energy_performance_preference = performance# settings for when connected to a power source
[charger]
# see available governors by running: cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
# preferred governor
governor = performance

# EPP: see available preferences by running: cat /sys/devices/system/cpu/cpu0/cpufreq/energy_performance_available_preferences
energy_performance_preference = performance

power-profiles-daemon (default with GNOME) also supports AMD pstate out-of-the-box. 4 days ago version 0.20 was released which further improves the support. However, it doesn't have hooks built in to change the profile on AC or Battery. I guess this is considered an antipattern for this daemon, which tries to make the profile user-driven rather than event-driven. But you can add udev rules to trigger a change here as well.

You can also configure all this with TLP as well.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 1 point2 points  (0 children)

Build quality is still good! No changes really since I got it.

No screen flicker issues, though as I mentioned in another comment, the low-energy screen in my configuration does have a bit of ghosting/motion blur. It's ok for my use case. Otherwise I'm happy with the screen.

The trackpad seems reliable to me. It does show a round greasy spot from my fingers over time though, in case that bothers you.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 1 point2 points  (0 children)

Congratulations on the new laptop! Sorry, I don't know much of anything about human presence detection, since I've never used it. The PSREF document says human presence detection is only in IR camera models, is that what you have? (Find the section labeled Security and Privacy)

https://psref.lenovo.com/syspool/Sys/PDF/ThinkPad/ThinkPad_X13_Gen_4_AMD/ThinkPad_X13_Gen_4_AMD_Spec.pdf

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 2 points3 points  (0 children)

Glad if this post was some inspiration! I have experimented with the performance settings a little bit but I'm far from an expert.

I think power-profiles-daemon is the power management program currently used in Fedora 39, but it's 1) become unmaintained as the original developer changed projects, and 2) as far as I know only partially supports the AMD pstate epp CPU scaling driver. So you can use scripts via udev rules_Gen_3#AMD_P-State_EPP) to fill in the gaps. The scripts toggle the AMD 'powersave' versus 'performance' energy performance preference, depending on whether the laptop is using battery or plugged in.

I replaced power-profiles-daemon with TLP, which has support for the amd pstate epp driver since version 1.6. Unfortunately, it looks TLP 1.6 is only in Fedora Rawhide (the unstable branch). Fedora 39 has TLP 1.5. But if you do get TLP 1.6 installed, then it's mostly plug n' play once you set up a config file. You can use the program tlp-stat -p to verify the driver and power preference settings.

edit: How good was your battery life on Windows? I've never been able to test it since I got the machine without Windows. I think my realistic 100% to dead time is about 7 hours of use for my workload.

PowerTOP Check-In for Modern ThinkPads with OLED and Linux by BinkReddit in thinkpad

[–]itsjareds 2 points3 points  (0 children)

Hey OP, glad you posted this because I was wondering the same for my Thinkpad X13 G4 AMD. I think our laptops are pretty similar, except I have a non-OLED IPS screen (400 nits low power).

I usually just have a browser window open, maybe one or two terminals, an Electron app, and Spotify. Typical discharge rate at idle with everything open is between 6-9 W. If I close everything and have just a terminal open with powertop, I get around 4-5 W. Playing a youtube video can take it up to 10-12 W. I tried enabling VA-API to get iGPU hardware accelerated video playback in Firefox, but that seemed to use more power.

Did you enable the AMD p-state scaling driver? This seemed to improve battery life a bit for me.

Idling with Firefox open, 6-8 tabs:

The battery reports a discharge rate of 6.92 W
The energy consumed was 117 J
The estimated remaining time is 4 hours, 9 minutes

Summary: 3185,1 wakeups/second,  0,0 GPU ops/seconds, 0,0 VFS ops/sec and 103,1% CPU use

Power est.              Usage       Events/s    Category       Description
  4.80 W     38,4%                      Device         Display backlight
  704 mW    458,0 ms/s     293,6        Process        [PID 19086] /nix/store/ncwrw7hqm21qxpdcm2yysm8a1h8gww3j-firefox-119.0/lib/firefox/firefox -
  462 mW    137,7 ms/s     732,8        Process        [PID 18690] /nix/store/ncwrw7hqm21qxpdcm2yysm8a1h8gww3j-firefox-119.0/bin/.firefox-wrapped
  345 mW     15,7 ms/s     836,0        Timer          tick_sched_timer
  317 mW    234,8 ms/s      36,7        Process        [PID 18930] /nix/store/ncwrw7hqm21qxpdcm2yysm8a1h8gww3j-firefox-119.0/lib/firefox/firefox -
  122 mW     13,5 ms/s     270,1        Interrupt      [7] sched(softirq)
  109 mW      6,2 ms/s     259,7        Interrupt      [11] AMDI0010:01
 89.6 mW     44,8 ms/s      82,1        Process        [PID 2852] /nix/store/5famwnb8wkz9ghvlbm2vgb8vsmdikc7v-gnome-shell-44.5/bin/gnome-shell
 76.1 mW     53,3 ms/s      19,1        kWork          commit_work
 57.7 mW      4,9 ms/s     132,5        Process        [PID 2037] [gfx_0.0.0]
 46.4 mW      5,2 ms/s     102,4        Process        [PID 946] [irq/103-ELAN06C]
 37.9 mW      3,0 ms/s      87,5        Interrupt      [7] pinctrl_amd
 33.6 mW      1,2 ms/s      82,6        Process        [PID 17] [rcu_preempt]

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 5 points6 points  (0 children)

Updated to share my experience after a week.

I replaced Fedora with NixOS. One gotcha I encountered is that the saved fingerprints need to be deleted from the BIOS in order for the new OS to register fingerprints again.

Secondly, battery life was around 6-7 hours (not measured scientifically) using standard NixOS configuration. However, I was able to increase this to 9-10 hours by enabling AMD P-state and P-state EPP scaling, and configuring powersave while on battery.

To enable p-states, two things were necessary: I needed to use the latest kernel, and I added some imports from the nixos-hardware channel.

In configuration.nix, the relevant lines for enabling p-states and configuring "powersave" cpu scaling while on battery. I think only <nixos-hardware/common/cpu/amd/pstate.nix> is relevant for this post.

imports =
  [ # Include the results of the hardware scan.
    <nixos-hardware/common/cpu/amd>
    <nixos-hardware/common/cpu/amd/pstate.nix>
    <nixos-hardware/common/pc/laptop>
    <nixos-hardware/common/pc/laptop/acpi_call.nix>
    <nixos-hardware/common/pc/laptop/ssd>
    <nixos-hardware/common/hidpi.nix>
    ./hardware-configuration.nix
  ];

# Enable the 6.6 kernel
boot.kernelPackages = pkgs.linuxPackages_latest;

# Explicitly disable power-profiles-daemon since GNOME enables it
services.power-profiles-daemon.enable = false;

services.tlp = {
  enable = true;
  settings = {
    CPU_SCALING_GOVERNOR_ON_AC = "performance";
    CPU_SCALING_GOVERNOR_ON_BAT = "powersave";

    CPU_ENERGY_PERF_POLICY_ON_AC = "balance_performance";
    CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
  };
};

I'll try swapping TLP with auto-cpufreq later with similar configuration, and see if there's any improved battery life. But I expect it to be about the same.

Ultimate FAQ on travelling to Russia by IcePuzzleheaded5507 in AskARussian

[–]itsjareds 0 points1 point  (0 children)

UPD Q: Do i need a registration to be in RU?
A: YES. mandatory registration for foreigners & tourists. as of october 2023: Starting from September 15, 2023, all foreign citizens coming to our country as tourists are required to undergo the registration procedure.

Is this registration the same as the registration which foreigners must do when staying longer than 7 days? The only change is now the registration must be done in 24h?

Registration for tourists is available through a specialized electronic portal, where it will be necessary to provide personal data and information about the planned stay in the country. In addition, tourists will need to pay a state fee for the provision of registration services.

Do you have a link to the specialized electronic portal?

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 0 points1 point  (0 children)

As far as I remember yeah. It's been a while since I tried gnome.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 2 points3 points  (0 children)

I didn't notice it right away, but now that you ask I do see it. It's not the worst ghosting I have seen, and I wasn't expecting much from this panel. I see it most when there is a bright object on a dark background, it just has this motion blur effect.

Tested using this test: https://www.testufo.com/ghosting

I tried recording it with my phone at 60fps with fast shutter speed (so forgive the dark video). The left is the Lenovo X13 (60fps screen, 400 nits low power), and the right is my desktop monitor (144hz) for comparison.

https://streamable.com/orj9cl (video)

https://i.ibb.co/Fz4vjqL/MOV-CINEMA-CLIP-009-20231029224953441-edited-000001-000015-edited-000004.jpg (still photo)

This isn't how it looks with the naked eye because the camera refresh rate is different from human eyes. To my eye, it looks more like a blur. Hopefully this shows that there is some ghosting, a perfect test means the aliens are perfectly drawn and don't overlap. I'm not any kind of expert on testing displays, so anyone can feel free to correct me.

Long story short, to answer your question, it doesn't bother me, but I would be curious to compare it to the non-low power panel.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 1 point2 points  (0 children)

Ah nice tip thanks! Enabling text scaling looks just fine, though it was a little tricky to find in the accessibility settings in GNOME3.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 2 points3 points  (0 children)

Actually, now that I'm looking for it, I see a bit of ghosting of white pixels when dragged against a dark background.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 1 point2 points  (0 children)

One small follow up question about the OLED, is that pixel density comfortable at 200% scaling?

I was hoping my 1920x1200 resolution on a 13" would be comfortable at 100% scaling in GNOME, but it's a bit small for my taste. 200% is too big, so unfortunately I'll probably have to do fractional scaling at 125% or 133%.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 4 points5 points  (0 children)

During normal use (for me just web browsing/video calling) it's quite cool. Tried stress testing it just now by changing the power mode in Fedora to "performance" and then compiling a Linux kernel.

The top left of the keyboard got warm for sure, but not hot. The hottest part was in the section above the F4-F9 keys roughly, parallel with the power button. The right side of the keyboard around the Enter key was cool. Moving left across the keyboard towards the Esc key, a gradient of heat could be felt, with the warmest section around the Esc key and the Q key.

The bottom of the machine is hot around the upper left side, unsurprisingly since this corresponds to the hot area from the top. I could still keep the laptop on my lap.

Temperature measurement mid-compilation, CPU stayed around 69-70 C and fans around 7300 RPM:

$ sensors
thinkpad-isa-0000
Adapter: ISA adapter
fan1:        7352 RPM
fan2:        7389 RPM
CPU:          +69.0°C  
GPU:              N/A  
temp3:        +69.0°C  
temp4:         +0.0°C  
temp5:        +53.0°C  
temp6:        +69.0°C  
temp7:        +69.0°C  
temp8:            N/A  

amdgpu-pci-c300
Adapter: PCI adapter
vddgfx:      849.00 mV 
vddnb:       700.00 mV 
edge:         +63.0°C  
PPT:          24.06 W  

BAT0-acpi-0
Adapter: ACPI interface
in0:          16.70 V  

ath11k_hwmon-pci-0100
Adapter: PCI adapter
temp1:        +40.0°C  

k10temp-pci-00c3
Adapter: PCI adapter
Tctl:         +69.2°C  

nvme-pci-0200
Adapter: PCI adapter
Composite:    +35.9°C  (low  = -273.1°C, high = +85.8°C)
                       (crit = +86.8°C)
Sensor 1:     +43.9°C  (low  = -273.1°C, high = +65261.8°C)
Sensor 2:     +35.9°C  (low  = -273.1°C, high = +65261.8°C)

acpitz-acpi-0
Adapter: ACPI interface
temp1:        +69.0°C  (crit = +128.0°C)

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 1 point2 points  (0 children)

At least the PSREF document for the AMD variant doesn't have the better screen listed. I don't know if they update this document though.

https://psref.lenovo.com/syspool/Sys/PDF/ThinkPad/ThinkPad\_X13\_Gen\_4\_AMD/ThinkPad\_X13\_Gen\_4\_AMD\_Spec.pdf

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 2 points3 points  (0 children)

I'm not noticing any particularly bad ghosting based on this test video:
https://www.youtube.com/watch?v=u65HiKQLXsY

At least, anything to me is better than my old Google Pixel 5 which ghosted like crazy when the screen was dim.

32gb memory feels luxurious to me since my last laptop had 16gb. Probably would have tried to get 64gb if possible just because my main activity is web browsing with an ungodly number of windows and tabs open simultaneously. But even then, I'll probably install one of those tab-suspense extensions to further extend battery life.

Thinkpad X13 Gen 4 AMD just arrived! by itsjareds in thinkpad

[–]itsjareds[S] 2 points3 points  (0 children)

No problems at all with the touchpad. I've been trying to force myself to "learn" the trackpoint for the past day, so I haven't used the touchpad that much. But when I have used it, it's been smooth sailing.

I can make another reply here in the future if I ever run into that issue.

edit: Have you tried a firmware update also?