this post was submitted on 16 Jun 2024
58 points (100.0% liked)

Selfhosted

38773 readers
746 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

I don't have spare peripherals like a monitor and a keyboard. How do you suggest I do a bare-metal install of Debian on a computer (meant to be a server)?

you are viewing a single comment's thread
view the rest of the comments
[–] notabot@lemm.ee 22 points 2 months ago (2 children)

While I agree with most people here that finding a keyboard and screen would be the easiest option, you do have a couple of other options:

  • Use a preseed file A preseed lets the installer run completely automatically, without user intervention. Get it to install a basic system with SSH and take it from there. You'll want to test the install in a VM, where you can see what's going on before letting it run on the real server. More information here: https://wiki.debian.org/DebianInstaller/Preseed

  • Boot from a live image with SSH Take a look at https://wiki.debian.org/LiveCD in particular 'Debian Live'. It looks like ssh is included, but you'd want to check the service comes up on boot. You can then SSH to the machine and install to the harddrive that way. Again, test on a VM until you know you have the image working, and know how to run the install, then write it to a USB key and boot the tsrget server from that.

This all assumes the target server has USB or CD at the top of its boot order. If it doesn't you'll have to change that first, either with a keyboard and screen, or via a remote management interface sych as IPMI.

[–] lemmyvore@feddit.nl 2 points 2 months ago (2 children)

Once upon a time you could use a thing called debootstrap to install Debian on the hard disk in a chroot on another machine, then switch the hdd to the target machine. Not sure if that thing is still around.

[–] possiblylinux127@lemmy.zip 1 points 2 months ago

You could just use the installer

[–] notabot@lemm.ee 1 points 2 months ago

Yes, that'll work too, it does involve adding the disk to your machine temporarily though, so just be carefully which disk you format to do it. Please don't ask why I say that, it brings back painful memories...

[–] MigratingtoLemmy@lemmy.world 1 points 2 months ago (1 children)

I did look at Preseed and it's probably a good idea if I'm doing many installs at once. I will still look at it but I'll likely have to purchase a monitor anyway. It is unfortunate because I don't have any thrift stores nearby

[–] notabot@lemm.ee 1 points 2 months ago (1 children)

It's going to be a balance between your time getting an automated approach to work and the cost/effort of getting a monitor. Getting preseed working can be a bit fiddly, but it does mean you've learnt a new skill, getting a monitor sounds like it'll be a pain, and you might only need it once.

[–] MigratingtoLemmy@lemmy.world 1 points 2 months ago (1 children)

Exactly. It's junk after that

[–] notabot@lemm.ee 1 points 2 months ago (1 children)

Putting a simple preseed file on a debian install image is probably going to be your best bet. Assuming you can run a VM on your current machine it shouldn't be too difficult to test it until you're happy with it.

[–] MigratingtoLemmy@lemmy.world 1 points 2 months ago (1 children)

I'll have to try that. Thanks!

[–] vegetaaaaaaa@lemmy.world 2 points 2 months ago (1 children)

example preseed file which I use to provision new servers (VMs)