728 shaares
49 results
tagged
tutorial
Kernel parameter allowing to pull firmware from separate path. Still has issue with file not being available in initramfs in Bazzite.
To enable virtual displays on amdgpu in Bazzite edit the kernel parameters on unused ports.
To determine unused ports on your gpu use:
for p in /sys/class/drm/*/status; do con=${p%/status}; echo -n "${con#*/card?-}: "; cat $p; done
Then add the parameters:
sudo rpm-ostree kargs --editor
Add the following arguments to the kernel, changing port,resolution and refresh as required:
video=DP-2:1920x1080@60e video=DP-3:2560x1600@60e
In Sunshine you should now see the new displays. You can use "command preparations" to enable/disable displays as required.
Examples:
Only DP-3, other displays disabled (parameters can be derived from "~/.config/monitors.xml where the settings app stores settings)":
gnome-monitor-config set -LpM DP-3 -m '2560x1600@59.987' -s 2
gnome-monitor-config set -LpM DP-1 -m '1920x1080@60.000' -t normal -LM DP-3 -m '2560x1600@59.987' -x 1920 -y 0 -s 2 -t normal
To determine unused ports on your gpu use:
for p in /sys/class/drm/*/status; do con=${p%/status}; echo -n "${con#*/card?-}: "; cat $p; done
Then add the parameters:
sudo rpm-ostree kargs --editor
Add the following arguments to the kernel, changing port,resolution and refresh as required:
video=DP-2:1920x1080@60e video=DP-3:2560x1600@60e
In Sunshine you should now see the new displays. You can use "command preparations" to enable/disable displays as required.
Examples:
Only DP-3, other displays disabled (parameters can be derived from "~/.config/monitors.xml where the settings app stores settings)":
gnome-monitor-config set -LpM DP-3 -m '2560x1600@59.987' -s 2
gnome-monitor-config set -LpM DP-1 -m '1920x1080@60.000' -t normal -LM DP-3 -m '2560x1600@59.987' -x 1920 -y 0 -s 2 -t normal
Build a tailored configuration:
mkdir -p ~/.config/samba
vi .config/samba/samba.json
In this file paste the following structure:
{
"samba-container-config": "v0",
"configs": {
"config1": {
"instance_name": "SAMBA",
"instance_features": [],
"shares": [
"share1",
"share2"
],
"globals": [
"default"
]
}
},
"shares": {
"share1": {
"options": {
"path": "/share1",
"valid users": "username"
}
},
"share2": {
"options": {
"path": "/share2",
"valid users": "username"
},
"permissions": {
"method": "initialize-share-perms",
"status_xattr": "user.share-perms-status",
"mode": "0755"
}
}
},
"globals": {
"default": {
"options": {
"security": "user",
"server min protocol": "SMB2",
"load printers": "no",
"printing": "bsd",
"printcap name": "/dev/null",
"disable spoolss": "yes",
"guest ok": "no"
}
}
},
"users": {
"all_entries": [
{
"name": "username",
"uid": 1000,
"gid": 1000,
"password": "password_cleartext"
}
]
},
"groups": {
"all_entries": [
{
"name": "usergroup",
"gid": 1000
}
]
}
}
Make sure uid and gid match the uid and gid of the file owner on the host. If you have files with deviating ownership you might have change ownership before the service comes up otherwise it might fail.
Now create the corresponding podman quadlet:
mkdir -p ~/.config/containers/systemd/
vi ~/.config/containers/systemd/samba.container
Paste the following content:
[Unit]
Description=Podman samba.service
Wants=network-online.target
After=network-online.target
[Service]
Restart=on-failure
TimeoutStartSec=900
[Container]
Image=quay.io/samba.org/samba-server:latest
AutoUpdate=registry
PublishPort=10445:445
#UserNS=keep-id:uid=1000,gid=1000
Environment=SAMBACC_CONFIG=/etc/samba-container/samba.json
Environment=SAMBA_CONTAINER_ID=config1
Volume=%h/.config/samba:/etc/samba-container:Z
# Folders to share
Volume=%h/path/to/share1:/share1:Z
Volume=%h/path/to/share2:/share2:Z
[Install]
WantedBy=default.target
Now test the quadlet:
systemctl --user daemon-reload
systemctl --user start samba
If the container comes up as expected you need to forward the firewall from the priviledged low port to the unprivileged low port and open the samba port in the firewall:
firewall-cmd --add-service=samba --permanent
firewall-cmd --add-forward-port=port=445:proto=tcp:toport=10445 --permanent
This should be it.
mkdir -p ~/.config/samba
vi .config/samba/samba.json
In this file paste the following structure:
{
"samba-container-config": "v0",
"configs": {
"config1": {
"instance_name": "SAMBA",
"instance_features": [],
"shares": [
"share1",
"share2"
],
"globals": [
"default"
]
}
},
"shares": {
"share1": {
"options": {
"path": "/share1",
"valid users": "username"
}
},
"share2": {
"options": {
"path": "/share2",
"valid users": "username"
},
"permissions": {
"method": "initialize-share-perms",
"status_xattr": "user.share-perms-status",
"mode": "0755"
}
}
},
"globals": {
"default": {
"options": {
"security": "user",
"server min protocol": "SMB2",
"load printers": "no",
"printing": "bsd",
"printcap name": "/dev/null",
"disable spoolss": "yes",
"guest ok": "no"
}
}
},
"users": {
"all_entries": [
{
"name": "username",
"uid": 1000,
"gid": 1000,
"password": "password_cleartext"
}
]
},
"groups": {
"all_entries": [
{
"name": "usergroup",
"gid": 1000
}
]
}
}
Make sure uid and gid match the uid and gid of the file owner on the host. If you have files with deviating ownership you might have change ownership before the service comes up otherwise it might fail.
Now create the corresponding podman quadlet:
mkdir -p ~/.config/containers/systemd/
vi ~/.config/containers/systemd/samba.container
Paste the following content:
[Unit]
Description=Podman samba.service
Wants=network-online.target
After=network-online.target
[Service]
Restart=on-failure
TimeoutStartSec=900
[Container]
Image=quay.io/samba.org/samba-server:latest
AutoUpdate=registry
PublishPort=10445:445
#UserNS=keep-id:uid=1000,gid=1000
Environment=SAMBACC_CONFIG=/etc/samba-container/samba.json
Environment=SAMBA_CONTAINER_ID=config1
Volume=%h/.config/samba:/etc/samba-container:Z
# Folders to share
Volume=%h/path/to/share1:/share1:Z
Volume=%h/path/to/share2:/share2:Z
[Install]
WantedBy=default.target
Now test the quadlet:
systemctl --user daemon-reload
systemctl --user start samba
If the container comes up as expected you need to forward the firewall from the priviledged low port to the unprivileged low port and open the samba port in the firewall:
firewall-cmd --add-service=samba --permanent
firewall-cmd --add-forward-port=port=445:proto=tcp:toport=10445 --permanent
This should be it.