I use Debian as my daily driver, but I’m still a newbie. I would like to selfhost a few apps, initially on a VPS, but I will probably move to a local PC once I diagnose what is broken with my old computer.

The guides at https://selfhosting.sh/ always recommend Ubuntu Server LTS for newbies, but Ubuntu seems to have bad PR and I already run Debian on my home PC. On one hand, I am a newbie and I guess Ubuntu might be easier to set up and maintain. Though, I don’t HOW exactly? On the other hand, if I have Debian on my home PC and on my server, they are the same system, so I’d be learning the same system at two places and with two usage scenarios. But it might be easier to make mistakes on Debian…?

What is your opinion/recommendation?

  • hexagonwin@lemmy.today
    link
    fedilink
    English
    arrow-up
    7
    ·
    1 day ago

    ubuntu just feels like debian with unwanted mods on top. if some specific proprietary sw you need only support ubuntu officially then ubuntu’s the better choice, but if not i see no reason to use it tbh

  • GreenKnight23@lemmy.world
    link
    fedilink
    English
    arrow-up
    6
    arrow-down
    2
    ·
    1 day ago

    Debian.

    waiting for the rug pull from Ubuntu once their corporate overlords decide to pull an IBM.

    • ilinamorato@lemmy.world
      link
      fedilink
      English
      arrow-up
      2
      ·
      1 day ago

      Honestly if they haven’t done it in the past 22 years, I’m not sure it’s ever coming. Not saying they’re a “good” corporation, just that it seems like they’ve been playing it fairly clean for a while.

      Besides, Ubuntu is FOSS. If Canonical does do a rug pull, there’ll be a fork available for people to migrate from in approximately 10.3 milliseconds.

      Not saying I like Ubuntu—I’m not a huge fan, honestly—just that this probably isn’t as much of a risk factor as it seems on the face of things.

  • ArborNodeA
    link
    fedilink
    English
    arrow-up
    2
    ·
    1 day ago

    Are you strictly self hosting with this device? If so there are whole operating systems that make this easy. TrueNAS Scale for example.

    I would suggest broadening your search. Debian vs Ubuntu is not much of a difference in my opinion. Videos and just trying some can help you decide.

  • kinther@lemmy.world
    link
    fedilink
    English
    arrow-up
    2
    ·
    1 day ago

    Both are viable. Ubuntu is based on Debian. It may come with some additional bloat. Really it comes down to what you feel comfortable with. Neither will be a bad choice.

  • lemmyvore@feddit.nl
    link
    fedilink
    English
    arrow-up
    8
    ·
    2 days ago

    If you already know Debian that’s a big point in its favor. Nothing beats a distro you’re familiar with. (And I’d make the same argument if you were used to Ubuntu.)

    I’ve used both Debian and Ubuntu Server on my home servers and I ended up returning to Debian.

    • Debian embodies and follows the most essential Linux values. It’s open, it’s run by an open organization, it avoids proprietary stuff.
    • Debian is long-lived. It’s been around for 30 years, it’s mature, self-sustaining, community-run project, and it will be around 30 years from now. Whereas I wouldn’t bet on Canonical being around in 30 years.
    • The upgrade path for Debian is better than for Ubuntu Server LTS.(1) You can upgrade it in-place between major versions a lot more reliably and painlessly than Ubuntu.
    • Debian is dedicated to being stable. (Please run stable, btw.)
    • Debian is a lot more resource-friendly than Ubuntu Server.

    I’ve ended up concluding that Ubuntu Server is Debian, just with more quirks. It offers nothing essential that you can’t do on Debian, and it will just complicate your life when the LTS support period eventually runs out (and even during LTS, when you have to jump through hoops like Ubuntu One to keep updates coming.)

    (1) You can fuck up both Ubuntu and Debian’s upgrades by adding a lot of 3rd-party repos because apt doesn’t safeguard against external repos interfering with the core repos’ dependency graph.

    So the trick is to keep the OS minimal, install only Docker from its repo and install anything else in Docker containers. That way you benefit the most from Debian being stable and very little from Ubuntu Server.

    If you also need to run system containers and virtual machines you can add Incus later to the mix alongside Docker and still keep your host OS lean and simple.

    You can also consider completely migrating to Proxmox later, which is also Debian under the hood but it’s a more turnkey solution. I wouldn’t recommend jumping straight into Proxmox unless you’re fairly sure that you’d need to run VMs. (If you’re unsure stick to plain Debian for now.)

    • steel_for_humans@piefed.socialOP
      link
      fedilink
      English
      arrow-up
      2
      ·
      2 days ago

      So the trick is to keep the OS minimal, install only Docker from its repo and install anything else in Docker containers.

      Why from Docker’s repo and not from Debian’s? I just did a quick apt search docker and I see docker.io and docker-cli.

      • lemmyvore@feddit.nl
        link
        fedilink
        English
        arrow-up
        3
        arrow-down
        1
        ·
        2 days ago

        Debian’s versions lag badly behind Docker’s. You’d always be missing the latest features. Docker introduces them at a steady pace and it can get annoying to see people talking about a new useful improvement and then months passing before it gets to you.

          • lemmyvore@feddit.nl
            link
            fedilink
            English
            arrow-up
            3
            ·
            2 days ago

            You say that but sometimes they come up with stuff that’s really useful and it can be very annoying to not have it. Like when they integrated compose into the main.

            Also, if you later decide to switch to the official version you’ll have to handle the upgrade carefully or you risk wiping out all your images, containers, networks, volumes etc. Which can be fine if you have backups of all the relevant functional definitions and the volumes and so on, but obviously a huge pain if it catches you unprepared.

            Mind you, this can also happen by tinkering with stuff in /etc/docker/daemon.json, which is how I originally learned to back up my shit.

            • steel_for_humans@piefed.socialOP
              link
              fedilink
              English
              arrow-up
              1
              ·
              2 days ago

              Ok, I will keep that in mind. I’m just wary of what you said earlier:

              You can fuck up both Ubuntu and Debian’s upgrades by adding a lot of 3rd-party repos because apt doesn’t safeguard against external repos interfering with the core repos’ dependency graph.

              You’re not the first person to tell me not to add too many external repositories on Debian for the same reason.

              • lemmyvore@feddit.nl
                link
                fedilink
                English
                arrow-up
                2
                ·
                2 days ago

                In Docker’s case is a non-issue because they were careful to use completely different names for all their packages. It’s only when the external repo uses the same names as the core that the dependency resolver can get confused.

                Rant:

                apt should either completely forbid external repos from using core package names (like Arch does), or look at both the package name and repo URL when deciding if a package is the same, not just package name.

                I’m guessing that letting external repos “hijack” a package name was once upon a time seen as a feature and then they never got around to fixing it.

  • Zwuzelmaus@feddit.org
    link
    fedilink
    English
    arrow-up
    61
    ·
    3 days ago

    I use Debian as my daily driver

    Chances are that you would find Ubuntu not just more complicated, but unneccessary complicated.

    Stay with Debian. It can do everything.

  • TheOubliette@lemmy.ml
    link
    fedilink
    English
    arrow-up
    40
    ·
    3 days ago

    Debian is better as a server host. Ubuntu is not easier for a server for anything except initial installation but you’ve already done that once with Debian so you’ll be fine. Only reason to use Ubuntu is if you want core software updates every 6 months and for this purpose you don’t. And can still have the option for newer software in select cases using containers.

  • danielfm123@lemmy.zip
    link
    fedilink
    English
    arrow-up
    29
    arrow-down
    2
    ·
    3 days ago

    Never Ubuntu, debian for server, fedora for desktop and arch/cachyos for tech fun.

  • pixeldaemon@sh.itjust.works
    link
    fedilink
    English
    arrow-up
    13
    ·
    2 days ago

    You are already familiar with Debian, so it will be easier. Debian is more friendly than you might think. This is enough to choose it.

  • curbstickle_lw@lemmy.worldM
    link
    fedilink
    English
    arrow-up
    18
    ·
    2 days ago

    Choosy self-hosters choose Debian.

    That said, I don’t recommend hosting software at the bare metal level - use VMs or containers. Far easier to manage and isolate.

  • Lka1988@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    13
    arrow-down
    1
    ·
    2 days ago

    Don’t use Ubuntu as a server. Pretty much every server application will run happily on Debian, meanwhile Canonical keeps adding/changing shit that is Ubuntu-specific and has broken otherwise-functioning server installations. I may or may not have personal experience with this.

    Ubuntu used to be the go-to, but Canonical is quickly becoming the poster child for Linux enshittification.

    For servers, use Debian and never think about it again. Except the one or two times a year it should probably be rebooted because of kernel updates.

  • litchralee@sh.itjust.works
    link
    fedilink
    English
    arrow-up
    20
    ·
    3 days ago

    If you’re already using Debian on desktop, then Debian on a VPS makes sense from a maintenance perspective: you only have to track one set of security updates. When there’s suddenly a critical update for some vulnerability, you can update both at once because it’s the same upstream repos. Whereas with Ubuntu on your VPS, you’d have to be mindful to make sure to check back when the same vulnerability is patched there.

    Do not underestimate the effort to upkeeping a server, and do try to unify your procedures so you’re spending less time doing the necessary things, and more time building up your self hosting stack.

  • TeaWithDani@lemmy.world
    link
    fedilink
    English
    arrow-up
    17
    arrow-down
    3
    ·
    edit-2
    3 days ago

    Ubuntu’s “reputation” is nonsense. It’s a great distro for servers. Security updates are really fast and using snaps in a server environment is really great. I recommend running things like Docker or Tailscale off snap. They will revert to a previous image if an update fails. Extra stability for a server as you run automatic updates. If you run everything that is not in the base install off a snap, you have an extra layer of sandboxing against any supply chain attack for dependencies.

    Ubuntu will have more recent packages, that doesnt really matter in a server environment. Debian is otherwise fine, I just dislike it’s installer and prefer Ubuntu’s. I found it easier to sync third party drivers on Ubuntu.

    Ubuntu Pro gets you livepatches for kernal issues, which may be worthwhile. Also done without rebooting.

    Ubuntu also gives you better apparmour default profiles on more things, whereas on debian, its up to you to set them up.

    Debian will be exactly the same, its just more conservative and has less of those extras I mentioned. May be marginally lighter on resources for that. Either are fine.

    • bigredgiraffe@lemmy.world
      link
      fedilink
      English
      arrow-up
      2
      ·
      1 day ago

      Yep this right here, I have used Ubuntu LTS for servers both my own and for work for years now and it works fine. I also don’t think snaps are as big of a deal as people make them out to be, the only snap I am actually forced to use is the mass snap and that is a canonical product so whatever. I even use it on some rpi4/5 even and it works great for use with workloads suited for a pi. Now, 10 years ago this was a different story, but these days Ubuntu LTS is a great OS overall.

      Debian is also great though (and if I was building some sort of appliance OS I would prob start with that since it has the fewest customizations to start with) but after you use any of the deb based distros enough they are all basically start to look the same to operate so pick one you want to learn and use that until you have a reason to change, learn the tools not the distro and you will be fine.

      All of that said though, every distro has idiosyncrasies but the Linux CLI skills you learn are definitely transferable so it’s not as big of a choice as it is made out to be sometimes, especially now that containers and systemd are everywhere. That is …unless you decide to pick Solaris or one of the BSDs but those are a whole other animal 😀

      • TeaWithDani@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        1 day ago

        Yeah an appliance distro would be a different consideration. For me Ubuntu is really flexible and a great docker host. I feel it’s safer to tinker with since you get those extra layers of containment and sandboxing.

        If I was to build an appliance I might also start with Debian, but so far I have used FreeBSD. Works great on my NAS, where I use XigmaNAS. You can transfer a surprisingly lot of skills. Learning what was common to FreeBSD and Linux really helped me with cli.

        I’m curious to try making stuff with Ubuntu Core. I think it has potential, but that’s a future deep dive and project. lol

    • nitrolife@hikki.team
      link
      fedilink
      English
      arrow-up
      1
      ·
      2 days ago

      SNAP also doesn’t work well with old hardware because of compression. It’s ironic to recommend system riddled with incompatible compression to someone who explicitly wrote in a post that they would be using outdated hardware.

      • TeaWithDani@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        1 day ago

        I think that’s more of a Ubuntu Desktop concern. My thinkpad has a 4th gen i5 and launches Firefox maybe half a second slower on a fresh reboot and afterwards its normal.

        Its really not relevant to a server who has all the time in the world to boot and stays up. Once the snap is launched, its launched, works fine afterwards. It’s all cached in the RAM or temp data or whatever afterwards.

        Ideally your server install would be on an SSD and your data on HDDs. Performance will be good with that setup.

        • nitrolife@hikki.team
          link
          fedilink
          English
          arrow-up
          1
          ·
          1 day ago

          Never mind what’s ideal, in reality, one of my servers is running on a Core 2 Duo T7600 and when I installed ubuntu on it, it took 24 minutes to boot due to the unzipping of the base snap image in ubuntu server. Older hardware does not become faster just because os requirements change. And yes, I left ubuntu as soon as snap came out, i think that was 2018.

          UPD: and of course I’m not going to change one of the local servers just because Canonical decided to release another system. Thanks. For 20 years the processor has been routing packets and will do so for another 20 without any problems. Just switched to another OS.

          • TeaWithDani@lemmy.world
            link
            fedilink
            English
            arrow-up
            1
            ·
            1 day ago

            At least it supports 64 bit then. 😅

            Listen, can’t speak for 20 year old cpu, but yeah snaps are more optimized now than in 2018.

    • irmadlad@lemmy.world
      link
      fedilink
      English
      arrow-up
      3
      ·
      2 days ago

      Ubuntu Pro gets you livepatches for kernal issues, which may be worthwhile.

      I use Ubuntu ESM. For their free, personal tier of Ubuntu Pro, you get 5 machines or 50 for active community members.

    • lyralycan@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      1
      ·
      3 days ago

      The only thing I know about apparmour is that it breaks some permissions for a couple of my machines, and I have to disable them in the container config in order for the containers to boot

  • nitrolife@hikki.team
    link
    fedilink
    English
    arrow-up
    3
    ·
    2 days ago

    If you’re planning to use old hardware for hosting, don’t use Ubuntu. SNAP will kill performance.

    So your choice is Debian.

    P.S. VPS is already a Virtual Private Server and you can’t install ProxMox or any virtualization on it. If you want experiments, look into containers.

    • khánh@lemmy.zip
      link
      fedilink
      English
      arrow-up
      3
      ·
      2 days ago

      i don’t recall snap being installed on ubuntu server. but yes, go with debian always.

      • nitrolife@hikki.team
        link
        fedilink
        English
        arrow-up
        1
        ·
        2 days ago

        SNAP in the recommended packages of the ubuntu-server metapackage. Ubuntu installs all recommended packages by default. So SNAP is in the server installation, moreover, it can’t even be simply removed without completely blocking in apt policy.

  • Pika@sh.itjust.works
    link
    fedilink
    English
    arrow-up
    11
    ·
    3 days ago

    As someone who ran Ubuntu server for a few years before moving to Debian. I would recommend Debian over Ubuntu just because I have had to do less maintenance with it. When I was on Ubuntu updating it was a constant concern of “will something change that is bad” for example they pushed the kernel live patch and the Ubuntu subscription banner as an update instead of an upgrade, so I updated as normal, and there it was.

    I dislike OS’s that install new packages as part of their update procedures (an update that installs a new package instead of replacing an existing one should be reserved for upgrades), and Debian has never done that with me, so Debian is where I stay.