Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to access data partition created with repart? #2350

Closed
danielbisar opened this issue Feb 7, 2024 · 1 comment
Closed

How to access data partition created with repart? #2350

danielbisar opened this issue Feb 7, 2024 · 1 comment

Comments

@danielbisar
Copy link

danielbisar commented Feb 7, 2024

Host: Debian 12
mkosi v0.20.2 (git) + #2347
Target: Ubuntu focal

Lets say i have a mkosi.repart/20-data.conf with the following content:

[Partition]
Type=linux-generic
Format=ext4
SizeMinBytes=1G
SizeMaxBytes=1G

On boot the partition is also shown in the overview before systemd starts.

This is just the start of a more complex setup. So there are a few questions:

  • there is no fstab?

  • context: system booted with "mkosi boot": how do i mount the additional partition (lsblk show loop5 -> loop5p3), if i try mount -o loop loop5p3 /mnt it says permission denied; and I guess i should probably create some systemd mount files?

  • mount does not seem to have it mounted

  • access to internet does not work in mkosi.postinst, event though [Packages] -> WithNetwork=yes is set.

@DaanDeMeyer
Copy link
Contributor

there is no fstab?

I am adding fstab support in systemd/systemd#30636. Until that lands, you have to write /etc/fstab yourself (which is complicated unless you use fixed UUIDS)

context: system booted with "mkosi boot": how do i mount the additional partition (lsblk show loop5 -> loop5p3), if i try mount -o loop loop5p3 /mnt it says permission denied; and I guess i should probably create some systemd mount files?

You cannot mount additional partitions from within a systemd-nspawn containers. These have to be mounted on the host and passed into the container. Maybe systemd-nspawn should look at fstab, but this is something related to systemd, not mkosi, so I'd suggest opening an issue in the systemd repo.

mount does not seem to have it mounted

There's no fstab, and systemd-nspawn doesn't automatically mount generic data partitions

access to internet does not work in mkosi.postinst, event though [Packages] -> WithNetwork=yes is set.

I'll need a lot more information that that to be able to debug this

@systemd systemd locked and limited conversation to collaborators Feb 8, 2024
@DaanDeMeyer DaanDeMeyer converted this issue into discussion #2353 Feb 8, 2024

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Development

No branches or pull requests

2 participants