Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
https://developer.valvesoftware.com/wiki/Source_Dedicated_Server
https://developer.valvesoftware.com/wiki/Command_Line_Options#Source_Games
This is not quite updated, but gives a good overview of things to check
https://wiki.alliedmods.net/Srcds_hardening#Crashes
I am sure there are a few guides on steam.
The most basic steps are:
1. Install SteamCMD
2. Use SteamCMD to download the required dedicated server files (SRCDS)
3. Configure the dedicated server
4. Test and run
I find the commands to be confusing as in when and how to use them. For example, should it be in the command line when I start the server, command line when the server is already up or console when in the server as a client.
That being said:
I've written a script to install CS:S. It can be modified to do the same for CS:GO, alas that is probably not that easy. But the comments and commands within should at least give you a rough overview on how to do it, e. g. creating a dedicated user, implement security and so on.
You may find that at https://github.com/M3tal-Warrior/installers/tree/master/cssource
Thanks! What are things I need to watch out for if I'm hosting on internet? What's the safer way to learn how to host using Linux? Thanks
Let's see:
1. Never run anything as root/sudo unless you're dead sure there's no other way.
2. Never run anything as root that is a web service. Exceptions are limited to sshd and VERY few other things you'll never get your hands on within the next 10 years or so.
3. Services are only run by system users. No exceptions.
4. System users must not be able to write to any file on the disk, except cache/temp directory (/tmp/servicename), their own data/home directory (/var/lib/servicename) and logs (/var/log/servicename/*). Especially the binaries are to be owned by root exclusively!
5. Never install other repositories than the one of your OS, unless there's no other way (read: there almost always is)
6. Always prefer the provided packages of your OS to anything you'll find on the internet, even if the latter promises newer versions. Stick to your OS toolkit, that one gets security updates.
7. You want to install unattended-upgrades. That one keeps your system up to date.
8. Rule of thumb for privileges of services in general: The fewer the better. As many as exactly necessary, as few as possible.
9. You want to read the FHS 3.0. You'll understand a lot about your system if you've read that.
10. Wikis to trust: Ubuntuusers Wiki, Debian Wiki, Arch Wiki. The latter has the deepest dive into the weeds, the middle one is the mother of Ubuntu. For servers you'll probably want to switch to Debian, it has less ♥♥♥♥ flying around and safer default options for services.
11. The 'man' command is your friend.
12. 99% of developers don't know ♥♥♥♥ about running services. Don't use their howtos.
That probably is a good list to start with.
I'm afraid running a steam server is not easy to do properly (I've done that a lot with my apprentices for training purposes), as it's not prepackaged by the OS maintainers and needs a lot of manual work to be secure. Most howtos tell you 'run steamcmd as root and afterwards start the binary as root, easy', which is just plain wrong (see #1 and #2). If you take a look at my installer, it tries to avoid that as far as possible and changes the owner of almost everything to root. It basically is the result of the better part of a work week of a very eager apprentice, and we've had a deep dive into kernel calls and such.
If you really want to learn Linux without being a security risk for yourself and others, try a webserver/nextcloud with letsencrypt. It's fairly easy and you'll learn a lot. And don't get discouraged. If you succeed and have fun with it, you're able to get into one of the best paying professions around - even without attending university. But beware: It's a profession that never sleeps, so learning until you die will be like 50% of your time (but you will get paid for that).
This is more of a hobby for me. Already have a career in Finance but have somewhat of a technical background. Linux has always been something I wanted to learn. I just had 1gbit symmetrical service installed and want to host games from home lol.
I'm going to restart with a fresh copy of everything and go through your list once I get my hands on an Optiplex with better hardware.
Also I'd strongly advise against hosting stuff at home, at least for a newbie. If your home server gets pwned, you can't trust anything in your network any longer. I'd advise for buying a vserver somewhere for a couple of bucks and host the games there - if it gets pwned, you've lost a game server, no big deal. Also regarding hardware lifetime it's a better investment to put your money into hosting, as a datacenter has better infrastructure (cooling, UPS, redundancy, security monitoring) than you're able to provide to a home server.
I looked into a VPS and will probably try that out when I get comfortable with what I'm doing. Could I separate the home server from my other devices? Vlan?
Yes, VLANs is an option alas most routers can't do them and if you're not familiar with networking you'll probably end up with less security than just leaving it be.
Don't overdo it. Small steps, learn the OS basics so you're able to blindly find your stuff on the console, and then go to network and firewalling. There's a lot of things to know not to mess up.
Like I said - leave gameservers outside and your private stuff inside is the way better option for a beginner, as most home routers offer more security than you're able to set up yourself for quite some time.