Jump to content

Protecting the Root Filesystem on Ubuntu with Overlayroot


Tsung-Li Wang

Recommended Posts

Hi All,

I'm using Ubuntu 16.04 as my OS system and i.MX6DL SabreSD as my cpu.

I build my linux kernel with Yocto Project.

 

Now I'm trying to protect the root filesystem with Overlayroot.

 

I installed the overlayroot by using apt-get as below.

 

sudo apt-get install overlayroot

According some research, its lead me to modify "/etc/overlayroot.conf"  to enable overlayroot.

So here I tried to add the line at the bottom.

overlayroot="tmpfs:swap=1,recurse=0"

Then I reboot the system.

After that I tried to check if there was any overlayroot mounted with command `mount` when get into system.

But there was nothing happened, root filesystem still mounted as RW.

 

Did I miss any steps?

 

Or is overlayroot have any relation with linux kernel driver?

Link to comment
Share on other sites

1 hour ago, Tsung-Li Wang said:

Or is overlayroot have any relation with linux kernel driver?


Yes, check logs for: [failure]: missing kernel module overlayfs

Link to comment
Share on other sites

37 minutes ago, Igor said:


Yes, check logs for: [failure]: missing kernel module overlayfs

Thanks for reply.

 

I had check logs by running below command.

dmesg | grep -rIn "overlayfs" *

But can not find any failure that relate to overlayfs.

 

I doubt that it did not even execute overlayroot.conf.

 

Any Advice?

 

Thanks in Advanced!

Link to comment
Share on other sites

1 hour ago, Tsung-Li Wang said:

 

Any Advice?


overlayroot is very picky and I could not make it work under Debian ... so it only works on Ubuntu. Xenial is tested, while I dont't recall testing it on Bionic. It's not just kernel but probably some libraries. I am not familiar with Yocto, so can't help you to fix it there but if you need this functionality and don't want to spent a lot of time fixing this, switch to Armbian Xenial version. It works there out of the box. Well, you will need to construct/copy a kernel/u-boot for your board ... so it's not very simple to decide the best route.

Link to comment
Share on other sites

On 6/8/2018 at 3:03 PM, Igor said:


overlayroot is very picky and I could not make it work under Debian ... so it only works on Ubuntu. Xenial is tested, while I dont't recall testing it on Bionic. It's not just kernel but probably some libraries. I am not familiar with Yocto, so can't help you to fix it there but if you need this functionality and don't want to spent a lot of time fixing this, switch to Armbian Xenial version. It works there out of the box. Well, you will need to construct/copy a kernel/u-boot for your board ... so it's not very simple to decide the best route.

I can not switch to Armvian Xenial version cause customer need Ubuntu and kernel build from Yocto.

What I know now is that there is some kernel driver configuration that I have to open.

After that it is all about Ubuntu 16.04 LTS.

 

And When I test overlayroot on my Ubuntu 16.04 which installed on Oracle VM VirtualBox, It success.

So I do the exactly same way on my armbased board but things not going quite well.

 

I think I have to do more research on this.

 

Any way thanks for your help.

Link to comment
Share on other sites

On 6/8/2018 at 3:03 PM, Igor said:


overlayroot is very picky and I could not make it work under Debian ... so it only works on Ubuntu. Xenial is tested, while I dont't recall testing it on Bionic. It's not just kernel but probably some libraries. I am not familiar with Yocto, so can't help you to fix it there but if you need this functionality and don't want to spent a lot of time fixing this, switch to Armbian Xenial version. It works there out of the box. Well, you will need to construct/copy a kernel/u-boot for your board ... so it's not very simple to decide the best route.

For a  quick ask, do you know which kernel driver configuration I have to open?

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines