Skip to content

Adding tun module as a vellum package#128

Open
esclee wants to merge 16 commits into
vellum-dev:mainfrom
esclee:main
Open

Adding tun module as a vellum package#128
esclee wants to merge 16 commits into
vellum-dev:mainfrom
esclee:main

Conversation

@esclee
Copy link
Copy Markdown

@esclee esclee commented Mar 30, 2026

Current plan is for me to build tun modules for ferrari and chiappa as rM releases toolchains and kernel for new OS versions and throw the compiled versions onto a github repo.

esclee added 2 commits March 29, 2026 20:35
Updated maintainer and upstream author information, modified package description and URL.
@esclee
Copy link
Copy Markdown
Author

esclee commented Mar 30, 2026

Ideally this could complement #116

Comment thread packages/tun/VELBUILD Outdated
Comment thread packages/tun/VELBUILD Outdated
Comment thread packages/tun/VELBUILD Outdated
Comment thread packages/tun/VELBUILD Outdated
depmod -a
modprobe tun
echo "tun" > /etc/modules-load.d/tun.conf
sleep 1s
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are you waiting 1 second here before doing a mount-restore? It doesn't look like you are doing any async changes to /etc or / that would require waiting? If there is, perhaps a sync is in order instead of sleep?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for some reason /home/root/.vellum/bin/mount-restore was erroring out on me with mount: /: mount point is busy, this seemed to solve it. Open to suggestions!

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Try a sync to make sure all changes have been properly written to disk. It could be that it hasn't finished writing. If it's not that, we should track down what is writing to the root partition that shouldn't be, as you have finished your changes already.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tried sync, worked for install!

Copy link
Copy Markdown
Member

@rmitchellscott rmitchellscott Apr 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 doesn't mount-restore already run a sync?

echo "Remounting / as read-only..."
sync
mount -o remount,ro /

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It worked the three or so times I tried, but might also just be a sometimes works, sometimes doesn't type situation...

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like some kind of orphaned inode issue. This seemed to fix it for me, I ran 50 install / uninstall cycles with no failures:

safe_depmod() {
      kver=$(uname -r)
      tmp=$(mktemp -d /tmp/depmod.XXXXXX)
      depmod -a -o "$tmp"
      for f in "$tmp/lib/modules/$kver"/modules.*; do
          cat "$f" > "/lib/modules/$kver/$(basename "$f")"
      done
      rm -rf "$tmp"
  }

If this is the way we wanna go, should I add to mount-utils?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as long as mine is the only one that messes with kernel modules it seems like we can just bake it into the specific VELBUILD?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It probably makes more sense to put into mount-utils so we don't waste time on this again if we add another kernel module

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, took a stab at this--added depmod-noorphan to mount-utils and velbuild for tun calls this

@rmitchellscott
Copy link
Copy Markdown
Member

@esclee anything else needed for this one?

@esclee
Copy link
Copy Markdown
Author

esclee commented May 27, 2026

should be ready for testing with 3.27!

@Eeems
Copy link
Copy Markdown
Collaborator

Eeems commented May 27, 2026

should be ready for testing with 3.27!

The depends limit this to 3.26 though?

@esclee
Copy link
Copy Markdown
Author

esclee commented May 27, 2026

sigh, I pushed something by mistake and in removing that I made a mistake. Should be good now, sorry

@Eeems
Copy link
Copy Markdown
Collaborator

Eeems commented May 27, 2026

/publish-testing

@github-actions
Copy link
Copy Markdown

Packages published to testing repo:

  • mount-utils
  • tun

Install with:

vellum add mount-utils@testing
vellum add tun@testing

Copy link
Copy Markdown
Collaborator

@Eeems Eeems left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code changes look good to me, I can install, lsmod, uninstall, lsmod with no issues on the rMPPM and rMPP.

@rmitchellscott quick check on the pure as well?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants