Incus Containers Step by Step
ฝัง
- เผยแพร่เมื่อ 28 พ.ย. 2024
- Incus is an open source fork of LXD Containers which is supported on linuxcontainers.org. The LXD project will be a Cononical project moving forward. I have a tutorial and a TH-cam video entitled LXD Containers Step by Step which covers much of the same content, except for LXD. This is about Incus.
Show Notes:
discussion.sco...
------------
Come visit us at: www.scottibyte...
Discourse: : discussion.sco...
RocketChat: chat.scottibyt...
still this is the best out there right now for getting started with incus in my view
this and the whole series on incus is very good and I am glad to have found this and the channel
many thanks
Thanks Jon. Be sure to join the chat and say hi. chat.scottibyte.com
Very helpful and detailed! Was able to setup my own Incus instance yesterday, thanks to your videos. I also appreciated your video on Incus vs LXD. Thank you.
Thanks so much. Come by and join the chat at chat.scottibyte.com/
@@scottibyte Quick follow-up question from your video. When I created a new incus instance using the launch keyword, along with --profile default --profile bridgeprofile, I didn't get back any errors, but when I list the instance, it doesn't display an IPV4 address. Any ideas on how I can troubleshoot what's going on, since I never got any errors?
@@MrDevonscott Wait at least two minutes for DHCP to assign an address. If it never gets an address, then the bridge0 device or the bridgeprofile are incorrectly created. Ask questions at chat.scottibyte.com/
2 commands in the 'ip' realm that have helped me a ton are
ip -br -c a this one shows a nice clean layout of interface name and ip addresses
ip -br -4 a this one shows the same as above essentially, but just for the ipv4 addresses.
I got these from my viewers, so figured it might help you too. The '-br' in the arguments is for --brief.
Awesome, Mr. Awesome. Published for others discussion.scottibyte.com/t/awesome-ip-commands-to-know/384
Useful getting started with Incus guide.
Glad it was helpful!
Thanks for these videos! Only thing is I'd love if they had TH-cam "chapters" so that it'd be easier to skip around to specific places
That is a reasonable point. However, I have a couple videos with chapters and my experience with them has been that subscribers come to me with questions because they skip over critical material. I try to keep my "editorial" content to a minimum and just present the material in an easy to follow, abridged fashion. "Incus Containers Step by Step" is one of those videos where not missing anything is critical to success. I will consider chapters in the future where viable. Thanks for the comments!
@@scottibyte that's fair enough :)
@@bwbuhse Be sure to join the chat chat.scottibyte.com/. Lots of folks there and I get a lot of input from other subscribers there to target future content.
I am definitely moving over from LXD to Incus at some point. Finally being able to install this from a real package has been long overdo. Currently running Snap on Debian just to have LXD. Ubuntu Server was great for many years, but Ubuntu Core and Snap has become such an annoyance and way to integrated that I just had to get away. Some of this may be great when dealing with large server setups, but for my tiny home server needs, I don't need all that waste. Looking forward to see how this project will progress without Canonical's control.
I agree on having the native package installer as a good thing. That being said, I have never had an issue with snaps and honestly Ubuntu Server is a very nice lean server with a huge market share. The appeal to running Incus for the foreseeable future will be access to "ALL" of the container images for a wide variety of distros. Down the road, Incus will develop a unique identity over LXD that will be user driven.
@@scottibyte For sure Ubuntu Server is one of the major goto's for a professional setup. But that's the thing, I do not have such a requirement. Just like SELinux would be my very first choice on a professional level, I would never want to have to deal with it on my own little private server where I find AppArmor to be plenty efficient. You may be able to remove most of the Ubuntu Core components, since I believe most have been moved into Snaps anyway. I never tried because Debian 12 came out around the time that I had had enough of the Core components. And it is running like a dream.
Thanks for much for posting these videos on how to use incus. One question I always had, both lxc and incus default to zfs, as well as you also choose in your videos. I would like try zfs as default storage, but have concern about zfs wearing out ssd and nvme storage disks. Is this a concern or how to handle?
When you say "default storage" I am assuming that you mean using zfs as your default for the root file system as opposed to ext-4. Generally if you are using a zfs file system, there is a chron job that sets autotrim to run on a weekly basis. If you are interested in seeing the trim operation status on your default storage pool in incus, use "zpool iostat -r default". Just FYI, the chat is better for these discussions than TH-cam comments.
Thanks, Scott for a very concise step by step container server setup. I acquired a 32G mini pc with a 512 SSD which I intend to use for educating myself on containerization. Do you have some links to some of your videos on practical usage of containers? I need a crash course in the day to day usage of such containers. I am thinking of maybe a nextcloud or opencloud instance, perhaps a pihole instance, etc.
Best Regards to you and your from about 750 miles east of you on the Suwannee River in North Florida.
Glad to hear it helped. I have over 125 videos on the use of Incus/LXD. Come by chat.scottibyte.com/ to discuss. Once you have created a container and then connected to it with "incus shell", it is trivial to add apps like pihole with a simple "curl -sSL install.pi-hole.net | bash". More complicated apps like Nextcloud may entail nesting docker inside of your incus container and I have dozens of videos illustrating how this is done.
Thanks. Very helpful.
Thanks. Be sure to join the chat at chat.scottibyte.com/. I have over 20 Incus videos now.
Very helpful! Works perfectly for me! Very good job!
But I ask me about openvswitch.
I wonder what the purpose of installing OpenVSwitch is.
Because I don't understand where it's being used.
Can its installation be avoided?
Openvswitch is required for bridge0. Netplan wants to see it to create the bridge aka virtual switch. Come by the chat at chat.scottibyte.com/ to say hi.
@@scottibyte It's clear to me now. Thanks for your help.👍
@@danielabbati1893 Come by the chat sometime to say hi chat.scottibyte.com/. I have close to 200 tutorials on Incus/LXD containers.
What if I want one of my containers to have a static ip address on my network? Would the same netplan steps for the incus host do the trick for the container?
With both LXD and Incus, the default network configuration for a container is DHCP. A best practice is to use DHCP Address Reservations on your router to have the same address applied to a LXD or Incus container every time it starts. The reason this works is because containers have an assigned MAC address that doesn't change. You can certainly create a netplan file (not like the one in the video) to set a static address. However, I don't recommend that because that becomes a configuration nightmare. DHCP address reservations managed at the router provides one place to manage all your fixed addresses.
Hi and thanks. What if I want to use a separate disk in the "incus admin init" process - what do I have to use at "Would you like to use an existing empty block device"? I didn´t find help in the documentation. Maybe you or someone else could help. Thanks.
Join the chat at chat.scottibyte.com/. An empty block device refers to an unused disk device like /dev/sdc. Do an lsblk to list your block storage devices.
@@scottibyte I tried exactly this but got an error message. I will try it again, thanks!
@@Glatze603 I have not not seen you on chat.scottibyte.com/ so that I can help you.
@@scottibyte I crashed my hole network by uninstalling "sudo" from my proxmox hosts. The result was, that ceph has been crashed completely and every vm is down now. I naw have to recover all services... Thanks.
Working with sudo as root?
Really hard to tell if that is a question or a comment. To use incus commands, you will need to add your account to incus-admin as indicated in the tutorial.
Damn this looks like the perfect all around software that can meet my needs. Thanks for the video learned a little about Incus. Hopefully in the future i will switch to it from Proxmox.
Good to hear I have over 150 videos on the details of using both LXD and Incus that should help.