Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Why Linux startup behaves different with overlay rootfs ?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Off the Wall
View previous topic :: View next topic  
Author Message
ranran
n00b
n00b


Joined: 11 Jul 2018
Posts: 69

PostPosted: Wed Oct 10, 2018 7:08 pm    Post subject: Why Linux startup behaves different with overlay rootfs ? Reply with quote

Hello,

I have an issue related to overlay filesystem, and I don't understand how to overcome it. :cry:
I hope someone can help...

I have vncserver (tigervnc), and in startup I see that vncserver service has started for all users (root+user) have vncserver (tigervnc).

Recently we added overlayfs using init script as done here: https://blockdev.io/read-only-rpi/

As you can see in above link, the overlay is above rootfs (rootfs is readonly).

At first, it seemed to me that all works the same (as without overlay).

But today I noticed a strange thing: With overlay rootfs, only the the user's vncserver has not started, and there is no log. I have no idea why.

I actually assume that EVERYTHING should be the same whether I use overlay or not, including all the started services.

What can be the reason for this change in behavior of started services with overlay ?

Thanks for any idea,
ranran
Back to top
View user's profile Send private message
erm67
Apprentice
Apprentice


Joined: 01 Nov 2005
Posts: 239
Location: Where the black men cannot enter

PostPosted: Thu Oct 11, 2018 1:27 pm    Post subject: Reply with quote

There is a comment section in the page where you got all those scripts, ask the author for assistance .....
_________________
True ignorance is not the absence of knowledge, but the refusal to acquire it.
A posse ad esse non valet consequentia
Πάντα ῥεῖ
Back to top
View user's profile Send private message
ranran
n00b
n00b


Joined: 11 Jul 2018
Posts: 69

PostPosted: Sat Oct 13, 2018 8:24 am    Post subject: Reply with quote

I fixed the issue, at first I had the overlay of the user partition in startup script (/init/local.d),
the result is that tigervnc is probably started before that start script is being called.
fix:
move the mount to fstab
That also did not work becuase it mount the partition as root (in terms of priviledge)
fix:
added in localmount chown to the partition, just after the call to fstab.

by the way, is doing it in localmount is the best place ?


Thank you,
ranran
Back to top
View user's profile Send private message
pjp
Administrator
Administrator


Joined: 16 Apr 2002
Posts: 17460

PostPosted: Sat Oct 13, 2018 10:22 pm    Post subject: Reply with quote

Does chown need to be run each time the mount occurs?

At least on some filesystems, ownership is preserved.

That is, after you've mounted the filesystem, changing the ownership should survive unmounting without having to continue running chown.
_________________
Slowly I turned. Step by step.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Off the Wall All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum