Update README.md

This commit is contained in:
ChocoTaco 2023-10-08 16:24:14 -04:00
parent b1d6e3971b
commit cdf1a8f56f

View file

@ -18,7 +18,7 @@ Discord: [Tribes 2 Discord](https://discord.gg/Y4muNvF)
- GCE (Google Compute Engine) being probably the more difficult option - https://cloud.google.com/compute/ - GCE (Google Compute Engine) being probably the more difficult option - https://cloud.google.com/compute/
- I'm sure there's others - I'm sure there's others
### Connecting... ### Connecting to your vps
- SSH as root into your vps (Your ssh password can usually be found on your host vps website) - SSH as root into your vps (Your ssh password can usually be found on your host vps website)
- In windows use puTTy (ssh tunneling for vnc: https://helpdeskgeek.com/how-to/tunnel-vnc-over-ssh/) - In windows use puTTy (ssh tunneling for vnc: https://helpdeskgeek.com/how-to/tunnel-vnc-over-ssh/)
- In Linux use ssh root@ip.address -L 5901:localhost:5901 - In Linux use ssh root@ip.address -L 5901:localhost:5901
@ -75,7 +75,7 @@ Discord: [Tribes 2 Discord](https://discord.gg/Y4muNvF)
sudo wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key sudo wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/debian/dists/bookworm/winehq-bookworm.sources sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/debian/dists/bookworm/winehq-bookworm.sources
- This install wine-development, typically theres no issues. If you have issues install "winehq-stable". - This will install wine-development, typically theres no issues. If you have issues install "winehq-stable".
sudo apt install --install-recommends winehq-devel sudo apt install --install-recommends winehq-devel
@ -140,36 +140,47 @@ Discord: [Tribes 2 Discord](https://discord.gg/Y4muNvF)
- Also make sure ports are open within the host service youre using with their firewall. Make sure to open port 22 for your ssh port as well. - Also make sure ports are open within the host service youre using with their firewall. Make sure to open port 22 for your ssh port as well.
//Start t2 server (without loops fix) ### Starting the Server
taskset -c 0 wineconsole Tribes2.exe -dedicated -mod Classic - Start t2 server (without loops fix)
//Start t2 server (with loops fix)
taskset -c 0 wine wine_injector.exe Server.dll Tribes2.exe 28000 -dedicated -mod Classic
//"taskset -c 0" is locking the server process to one thread
//Ideally you can start your server with a bash script ie: sh startserver.sh taskset -c 0 wineconsole Tribes2.exe -dedicated -mod Classic
//Update the start command with whatever you choose to use with or without loops fix
#!/bin/sh
BASEDIR=/home/t2server/.wine/drive_c/Dynamix/Tribes2/GameData/
cd ${BASEDIR}
while true; do - Start t2 server (with loops fix)
echo "Waiting 30 seconds for all wine processes to close..."
sleep 30
wineserver -k9 && killall wine && kill $(lsof -t -i:28000) && kill $(lsof -t -i:80) && killall winedevice.exe
echo "Removing dsos..."
find ${BASEDIR} -name \*.dso -execdir /bin/rm {} \;
echo "Starting Tribes2 server..."
WINEDEBUG=-all,-fixme taskset -c 0 wineconsole Tribes2.exe -dedicated -mod Classic
done
//For security you can use an ssh key to login, lockdown ssh thru firewall, lock ssh to your home ip, and move ssh ports around taskset -c 0 wine wine_injector.exe Server.dll Tribes2.exe 28000 -dedicated -mod Classic
//Adding an ftp server can also help with file management, granted you locked down the ports
//If everything is setup correctly, your server should show up on the main server within a few minutes
//Other things that can be done... - "taskset -c 0" is locking the server process to one thread
//Higher Priorty: To allow your user to set a higher priority use...
sudo nano /etc/security/limits.conf - Ideally you can start your server with a bash script ie: sh startserver.sh
//At the end add - Update the start command with whatever you choose to use with or without loops fix
@t2server - nice -20
//New startup would be something with "nice -n -5" added... #!/bin/sh
//nice -n -5 taskset -c 0 wineconsole Tribes2.exe -dedicated -mod Classic BASEDIR=/home/t2server/.wine/drive_c/Dynamix/Tribes2/GameData/
cd ${BASEDIR}
while true; do
echo "Waiting 30 seconds for all wine processes to close..."
sleep 30
wineserver -k9 && killall wine && kill $(lsof -t -i:28000) && kill $(lsof -t -i:80) && killall winedevice.exe
echo "Removing dsos..."
find ${BASEDIR} -name \*.dso -execdir /bin/rm {} \;
echo "Starting Tribes2 server..."
WINEDEBUG=-all,-fixme taskset -c 0 wineconsole Tribes2.exe -dedicated -mod Classic
done
### Other Things
- For security you can use an ssh key to login, lockdown ssh thru firewall, lock ssh to your home ip, and move ssh ports around
- Adding an ftp server can also help with file management, granted you locked down the ports
- If everything is setup correctly, your server should show up on the main server within a few minutes
- Higher Priorty: To allow your user to set a higher priority use...
sudo nano /etc/security/limits.conf
- At the end add
@t2server - nice -20
- New startup would be something with "nice -n -5" added...
nice -n -5 taskset -c 0 wineconsole Tribes2.exe -dedicated -mod Classic