Skip Navigation

Search

Setting up a bridged network for HomeAssistant in KVM Fedora

I have tried to follow several tutorial to setup using either ip or nmtui:

  • https://linuxconfig.org/how-to-use-bridged-networking-with-libvirt-and-kvm
  • https://www.redhat.com/sysadmin/setup-network-bridge-VM

However, the bridge inherits the MAC address of host after enslaving the host hardware enp1s0.... This causes my router to give both the host and the bridge the same ip address, making the ha instance inaccessible.

The red hat tutorial clearly show that the bridge and the host have different IP, so I was wondering if I am doing something wrong.

---

alternatively, I can set the home assistant vm to run in NAT and port forward from host, but I have several devices that communicate over different ports. So it would be annoying to forward all these ports. Not to mention, many appliances don't have documentation about the ports they use.

I can also potentially use virtualbox, but it is not well supported on silverblue, especially with secureboot enabled.

1

Manjaro, out of curiosity question, does the image on boot has any security implication regarding logoFAIL?

Hi everyone :).

Just getting started with Manjaro as daily drive to get some easier arched based distro. Except for the LVM bug with calamares everything is pretty smooth :).

But at first boot, I saw they have added their personal Manjaro logo on boot and I directly though of the bug exploit logoFAIL I heard a few month ago and It made me curious if this is something that could be exploitable by Manjaro.

Probably not, this would harm their image and hard worked system, but I'm still curious... If someone smarter/more knowledgeable than me could chime in and give some valuable information on this topic regarding Manjaro, I would really appreciate it !

Thank you !

30

Using DD to make a backup of an OS drive?

Would this work or would I have problems:

Using dd command to backup an entire SSD containing dual boot Windows/Ubuntu partitions into an .iso file, with the intent to then dd that iso back onto the same size SSD in the case of a drive failure?

28

Flatpak or AUR?

I've been using arch for a while now and I always used Flatpaks for proprietary software that might do some creepy shit because Flatpaks are supposed to be sandboxed (e.g. Steam). And Flatpaks always worked flawlessly OOTB for me. AUR for things I trust. I've read on the internet how people prefer AUR over Flatpaks. Why? And how do y'all cope with waiting for all the AUR installed packages to rebuild after every update? Alacritty takes ages to build for me. Which is why I only update the AUR installed and built applications every 2 weeks.

42

How to correctly cleanup unknown filedescriptors received over unix socket

The context I came upon this question is dbus filedescriptor passing but the question is valid more broadly. Assume you are implementing some service that is supposed to receive some kind of filedescriptor for client processes. You get a message that is in some kind or another malformed but you have already received the filedescriptor.

What do you do with that fd? Is close()ing it guaranteed to be enough?

The question was sparked by a safety comment on rusts abstraction of a OwnedFd, which will run close() in its destructor and binds you by contract to only create it from a filedescriptor if close is all that is needed for cleanup.

This of course made me worry about the possibility of malicious clients sending special filedescriptors that accumulate some kind of ressource on the server process causing some kind of DOS.

I guess a secondary question is: Do you know any example where calling close() is not enough?

3

I installed Apache OpenOffice

I downloaded Java, Removed LibreOffice, and installed OpenOffice. I see all the icons, and everything, but when I click on it to open it, NOTHING happens. I just, wont open, I uninstalled, and reinstalled it. and I dont know what to do. Can anyone please help me?

22

Unable to access someof my LAN servers from WAN

Hi there,

I am pretty new to Linux, so apologies for any stupidly obvious answers I might miss; I have a Raspberry Pi with some self hosted stuff to use in my LAN - however I have recently decided to host a Gogs (git) server on there also (as well as a Wordpress server).

Heres the issue - my Plex server is accessible from WAN, the Wordpress server is half working and the Gogs server is only accessible from LAN.

Basically if I connect to the server with LAN IP it works, if I use WAN IP it doesnt (The server at IP is taking too long to respond). One weird thing I noticed is that the Wordpress server - if I try to go to that via WAN IP it doesn’t work, but if I go via the DNS it works fine.

The Gogs server is using Docker, Wordpress just uses nginx. I have a static IP and have forwarded the correct ports on my router, I also have a new modem for fibre that I have not used before - not sure if that matters.

I'm mostly focused on getting the Gogs server accessible from WAN, I'm not too fussed about Wordpress right now since that works via DNS anyway.

Really appreciate any possible solutions you guys might know

7

Some questions about BSPWM tiling manager

  1. I have a rule for vscode: bspc rule -a Code follow=on desktop='^4'. If I manually move one vscode instance to another workspace, work in that and than drag'n'drop smth (or any other action initiating popup menu), dialog will appear on 4th workspace rather than on current one. How to fix that?
  2. How to transfer workspaces(applications on them) correctly in the easiest way when switching to external monitor and returning?
3

Are OS X like keybindings possible?

I have been using Linux on and off from the first shipped CDs from Ubuntu. Nowadays I mainly use OS X, because my employer provides us with MacBooks I can use in private and I like the UNIX base and I do not have to tinker to get things to work.

I just set up an old Thinkpad for my kids to start their digital journey with Linux Mint and am considering switching my private stuff to a separate computer.

What I really love about OS X is the consistent usage of alt and the command keys. It basically follows the concept: „you want to do something, press Command + …“ and „you want an alternative character? Press alt + …“.

My experience is that Linux key usage was inspired by Windows at first and Windows did not have a Command key.

Would it be hard to get the same behavior as on OS X with a Linux system?

11

Which shell prompt do you use and why?

Hi. I've been using powerlevel10k for a long time, but a few days ago, I decided I wanted to customize it a bit. I opened the .p10k.zsh file, and I was shocked. It's really massive, with TONS of options. I've been digging through for a few hours already, and it's absolutely amazing how much you can customize it without actually programming anything. I was wondering what other people are using. So my questions are:

  • Do you customize your shell prompt?
  • If yes, do you use some framework or pre-made theme, or do you just configure it the vanilla way in your bashrc/zshrc/...
  • How is your experiences with it so far?
  • Share screenshot of your prompts, please (Sadly, my prompt is currently half done, so I can't really share it)
68

Display Management on tiling wm

BSPWM, laptop has 1920x1080 resolution, external screen has 1680x1050. xrandr --output DP-1 1680x1050 cuts image, if I change resolution to 1920x1080, I get "full" image, but quality is just bad. I have another machine with XFCE, it's display utility does the trick and I wonder can I achieve smth similar on BSPWM with some simple console command?

13

Switching rgb range at monitor plugin

I have a projector that needs limited rgb range, but for some reason (maybe a faulty hdmi-vga dongle) the intel driver selects full range. I want to force the limited rgb range when I plug the projector, but I need it set to auto normally, because my usual monitor needs full range.

I read this guide that explains how to use proptest to switch mode when in wayland. The problem is that running the command when the gnome session is open doesn't work and returns an error 243 (I can't find it in errno.h, but google says its EACCESS). The guide deals with this by launching the command with systemd before gdm starts, but as I said, I only want to force the limited range when using the projector.

I noticed that I can switch to a tty, set the range, and switch back to gnome while everything is still running and it works, which is my current "workaround", and I'd like to automate it. So I thought that there's a moment when gnome "takes control" of a screen where this can be set. I tried to use a udev rule to switch as soon as a monitor is plugged, but it exits with 243 as usual. I suspect gdm has a way to automate such things that might possibly work, but I can't find it, I only read about some xorg scripts.

Also, there's this issue that's being worked on. One of the commenters uses an udev rule as a work arount but it doesn't work for me.

0

Splitting headphones and internal speakers on a thinkpad with fedora

When the jack is inserted the internal speakers stop making sound and the only analog out is the jack, as it's common on laptops. But I want to address the two analog output individually so that I can:

  • Still select the speakers when headphones are plugged
  • Have different sounds come from headphones and speaker
  • Mix them with carla or other audio software

My alsa/pipewire settings are all default, I'm on a thinkpad t480s with fedora 38. My sound card is an intel hd audio card, with a realtek ALC257 analog chip.

I tried disabling auto_mute and rising the volume from alsamixer but nothing happens. Then I switching pipewire to "pro audio" but it doesn't separate the analog outputs. I also tried setting the indep_hp hint from hdarackretask but it doesn't change anything.

The hint enables a new "independent hp" option in alsamixer, but it can only be enabled by the cli and it doesn't work either.

I can provide configuration files or other info if needed but since they are all pretty long I didn't include them in the post. Also because I didn't edit them so they are just fedora's default.

Thanks

8

From MacOS to Linux, need advice on best software packages

Hello Everyone,

as you can see on my screenshot, i am using an intel based mac for years now, which i customized to my needs. However i have reached the limits of this machine in terms of customization options and would like to move to linux to test it out as a daily driver. I'm actually quite happy with mac from the pov that everything just works, however there are certain things that annoy me, but apple does not allow me to change them.

As a newbie in terms of desktop linux (i've used ubuntu roughly 12 years ago as a daily driver and am familar with headless linux), i'd like your advice.

Specifically I am looking for:

  • a minimal, fast system
  • keyboard / shortcut based - all interactions can be done from keyboard (within common sense limits)
  • all keys can be custom mapped (i have muscle memory of my custom keys for certain actions, so i'd like to keep them)
  • all can be configured from dotfiles (worse case shell scripts and ansible)
  • very low ressource consumption, snappy system with no delays.

I'd like to try NixOs due to it's unique configuration ability, however on a headless server it was a buggy pain just weeks ago (for example user passwords just vanished/changed without any external influence, not allowing access anymore), so i'm open to alternatives.

What i am looking for in advice is:

  • a minimal, configurable (file based for git) tiling window manager
  • a top status bar like you see in the screenshot that i can freely configure
  • as much terminal emulator based as possible (i honestly mostly only need a browser and the terminal, most other apps have a TUI that i can use with the keyboard, see the above requirement)
  • terminal based package management as easy as brew (maybe Nix?)
  • custom keyboard layout (I am not a native english speaker, so i mapped all non-english characters to my option keys with the english layout as the base)
  • Option to use 2 keyboards at once (come by default when using Karabiner Elements) as i combined 2 small keyboards to one to a fake split keyboard ;)

My current stack on macos is Hammerspoon for heavy customization, Karabiner Elements, yabai, kitty (and alacritty, for ssh, as kitty is bad with ssh in my personal experience), sketchybar. firefox (customized for privacy)

Any good recommendations or dotfiles? Anything i should look out for as a MacOs User?

Thanks in advance!

30

Debian sudoers and user best practice

Hi everyone 🙂

TLDR

How do you work with debian and su permission and what's the best way to do it for better security?

  • Add an user in the sudoers?
  • Give special permissions to a group? User?
  • Always connect to su - (default root)?
  • Add users to groups? --- The story is unrelated to the question, but is a direct cause

This is rookie question even though I use linux (ubuntu and recently debian) regularly and have alot of selfhosted docker containers on an old spare laptop.

While this is probably one of the basics you need to know right away when playing arround with sudo or su I wasn't aware of how you can f#ck everything up with a single command

chmod -R xxx /home/$USER

chown -R ...

Why would you do that? Because I'm stupid and how sometimes no idea what I'm doin? I was actually trying to change some permission to create a samba share (that's another story xD).

Trying to revert everything, alot of my docker containers, certificates and special files were unreadable, unexecutable... That broke my nextcloud instance, synchthing functionalities, linkding http shortcut...

With that big incident, I learned how users, root, sudo/su permission work and recently found out you can add users to groups, like docker so you don't have to 'sudo docker' everytime.

My question

How do you work with debian and su permission and what's the best way to do it for better security?

  • Add an user in the sudoers?
  • Give special permissions to a group? User?
  • Always connect to su - (default root)?
  • Add users to groups?

Because this is in a homelab environment, there is a minimal risk compared to exposed instances, but I'm interested to learn the best practice right away !

Thank you 😊

14

How can I dim screen after 20s inactivity when running on battery? tlp/sway/arch/chromebook

I think this could save me some battery time. I checked tlp but could not find anything related. In Sway config with swayidle maybe? All help appreciated.

5

to Linux from Windows as a daily driver

My plan is to buy an NVMe today, install linux as a dual boot, but use linux as a daily driver, to see if it meets my needs before committing to it.

My main needs are gaming, local AI (stable diffusion and oobabooga), and browser stuff.

I have experience with Mint (recently) and Ubuntu (long ago). Any problems with my plan? Will my OS choice meet my needs?

Thanks!

75