Jump to content

CnCNet Forums

Search In
  • More options...
Find results that contain...
Find results in...
Sign in to follow this  
mohsen9010

CnCNet server systemd (Auto Start Service)

Recommended Posts

This is a solution to become a CnCNet host server in linux servers that have systemd for service control (Debian, Ubuntu,...):

Do it as a root or add 'sudo' before every command:
 

apt-get install libmono-system-core4.0-cil mono-runtime

useradd -m cncnet

wget -O /home/cncnet/cncnet-server.exe http://downloads.cncnet.org/cncnet-server.exe

chown cncnet:cncnet /home/cncnet/cncnet-server.exe

wget -O /etc/systemd/system/cncnet.service https://files.catbox.moe/z7y3nd.service

# Change 'my new name server' to your own server name

sed -i 's/My cool server/my new name server/g' /etc/systemd/system/cncnet.service

systemctl daemon-reload

systemctl enable cncnet.service

systemctl start cncnet.service

Make a service is better than crontab for auto start solution!

This topic is related to https://forums.cncnet.org/topic/6325-how-to-host-a-cncnet-server/

cncnet.txt

Edited by mohsen9010
  • Like 1

Share this post


Link to post
Share on other sites

Nice solution!How does the CnCnet servers work in general?  I only play RA1.  https://cncnet.org/status 

I have spun up a VPS and got it going (Sadspider's server) 

However how do I connect to it or is it just used by default?

 

Edited by sadspider
update

Share this post


Link to post
Share on other sites
11 hours ago, sadspider said:

Nice solution!How does the CnCnet servers work in general?  I only play RA1.  https://cncnet.org/status 

I have spun up a VPS and got it going (Sadspider's server) 

However how do I connect to it or is it just used by default?

 

I'm not sure about RA1 game, but already for Tiberian Sun was a way to choose a tunnel server. But for now this is only automatically choose.

In this topic FunkyFr3sh say:

Quote

Note: Servers are chosen automatically by CnCNet and are only used in case 2 players fail to establish a Peer-To-Peer connection.

I think it could be better to people can choose a tunnel server.

Edited by mohsen9010
  • Like 1

Share this post


Link to post
Share on other sites
14 hours ago, mohsen9010 said:

I'm not sure about RA1 game, but already for Tiberian Sun was a way to choose a tunnel server. But for now this is only automatically choose.

In this topic FunkyFr3sh say:

I think it could be better to people can choose a tunnel server.

Totally.  A tunnel server would be far superior than p2p.  There are so many games where all it takes is a bad conn between 2 players to lag everybody out.

Also being able to select a server would increase incentives for more people to host them.  I know they have official servers with high capacity already but why not utilise them fully?

Share this post


Link to post
Share on other sites

years ago it used to be like this, everyone could choose a server when they hosted a game but that didn't work out too well.

Imagine someone from Germany hosted a game (he would choose a server in Germany obviously), now 2 players from Australia join his game. What happens now is that Australia1 has to send the data to the German server, then the German server needs to send the data back to Australia2 and you end up with a round trip time of 800ms, it's going to be unplayable... The games can't handle more than 400ms latency.

Back then I tried to solve the problem by adding country flags to the game rooms to ensure players know that the server is too far away from them, I also tried to show warning messages to ensure they know that the game won't be playable like this, but everyone ignored it. The only way to make such a setup working is to hide games hosted on servers with too big distance, but that's a terrible solution (we can't really separate our small community like this..).

 

As a comparison, with our current setup there is no problem at all with 1 player from Germany and 2 players from Australia. The round trip time will be 400ms only since that's the time from Germany to Australia while the 2 players from Australia will connect directly to each other with just 50ms latency rather than 800ms as explained in the example above.

 

Share this post


Link to post
Share on other sites
23 hours ago, FunkyFr3sh said:

years ago it used to be like this, everyone could choose a server when they hosted a game but that didn't work out too well.

Imagine someone from Germany hosted a game (he would choose a server in Germany obviously), now 2 players from Australia join his game. What happens now is that Australia1 has to send the data to the German server, then the German server needs to send the data back to Australia2 and you end up with a round trip time of 800ms, it's going to be unplayable... The games can't handle more than 400ms latency.

Back then I tried to solve the problem by adding country flags to the game rooms to ensure players know that the server is too far away from them, I also tried to show warning messages to ensure they know that the game won't be playable like this, but everyone ignored it. The only way to make such a setup working is to hide games hosted on servers with too big distance, but that's a terrible solution (we can't really separate our small community like this..).

 

As a comparison, with our current setup there is no problem at all with 1 player from Germany and 2 players from Australia. The round trip time will be 400ms only since that's the time from Germany to Australia while the 2 players from Australia will connect directly to each other with just 50ms latency rather than 800ms as explained in the example above.

 

Thanks.

 

I guess servers would only make sense for a higher player count to justify having regions, i.e EU, NA, ASIA etc.   My reasoning was that if they connected to a server then it didn't matter so much if you had 8 players from say... UK, Germany, Australia, North America etc.  As they will connect to one central server.  But I suppose with p2p they will connect to one host anyways.  It's just that it's a shame when you have a few players with good internet and it just takes 2 other people, like UK and Russia to have a bad connection that will lag everybody.

It is amazing the work you have done to revive this game.  I used to play on xwis all the time back in the day and the CnCnet client is something really amazing.  

Where do you see the future of CnCnet?  Also what is the best way to help contribute the project and community?

Share this post


Link to post
Share on other sites
On 5/18/2019 at 7:53 PM, FunkyFr3sh said:

years ago it used to be like this, everyone could choose a server when they hosted a game but that didn't work out too well.

Imagine someone from Germany hosted a game (he would choose a server in Germany obviously), now 2 players from Australia join his game. What happens now is that Australia1 has to send the data to the German server, then the German server needs to send the data back to Australia2 and you end up with a round trip time of 800ms, it's going to be unplayable... The games can't handle more than 400ms latency.

Back then I tried to solve the problem by adding country flags to the game rooms to ensure players know that the server is too far away from them, I also tried to show warning messages to ensure they know that the game won't be playable like this, but everyone ignored it. The only way to make such a setup working is to hide games hosted on servers with too big distance, but that's a terrible solution (we can't really separate our small community like this..). 

  

As a comparison, with our current setup there is no problem at all with 1 player from Germany and 2 players from Australia. The round trip time will be 400ms only since that's the time from Germany to Australia while the 2 players from Australia will connect directly to each other with just 50ms latency rather than 800ms as explained in the example above. 

  

Be better to show ping instead of country flags of tunnel servers. (like Valve servers)

I think instead of main tunneling, We should have combination of p2p and main tunneling.

What is that?

That mean just one player that have bad connections can choose a tunnel server to connect other people p2p (but by the tunnel server).

Every client can choose a tunnel server to be main host or connect to other games.

It's like a VPN for a client... .And every client can choose a p2p tunnel server or direct connection.

We tested this way already and it's a good idea for bad connection people.

Edited by peylight

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Similar Content

    • By sadspider
      Any decent guides on modding RA1?  Also i'm after a decent Map Maker.  I used to use final alert back in the day and you could generate a map from a .bmp image.  Are there any map editors for RA1 that do the same?  I have seen the sticky thread on links but the Red alert 1 link is dead.
      Thanks in advance.
    • By dougwg
      Checking for updates screen appears and does nothing.
      Then I get a dialog box that says:
      "Update failed... Please check your connection, Anti-Virus and Firewall settings!
      The operation has timed out"
      I have turned off the virus and firewall and the same thing happens.
      Funkyfresh helped me a few weeks ago with the last update.
      If memory serves, he gave me a direct link but I can't remember exactly.
      I have already tried http://downloads.cncnet.org/updates/cncnet5/CnCNet5Version.txt and http://downloads.cncnet.org/updates/cncnet5/ and https://downloads.cncnet.org/updates/cncnet5/ with no love (403 Forbidden).
      Also while joining a game with a map that I don't have, it fails to download the new map so I can't play on any new maps either.

      Please help.
    • By Yah-Nosh
      Hi everyone!
      As I'm sure you all know, TS had a rough release, with lots of features either not fully polished, or cut from the game entirely. This includes features that WW clearly was not happy with, since they greatly altered them in RA2 (Jumpjet Troopers vs Rocketeers, just to name one example).
      I recently introduced a friend to these older C&C games, and while he likes TS, we both could not look past a lot of shortcomings. Thus, I wanted to know if there exists a mod that tries to fix/restore the content of the game to improve gameplay, i.e a sort of "quality of life" mod.
      I know there's plenty of total conversion mods and "remasters", but I'm looking for something that sticks as close as possible to the original, and merely improves on the less impressive features. TS Retro is a good example, introducing some neat features and fixes, but I'd prefer a mod that doesn't add new content (beyond stuff that was meant to be in TS in the first place)
      Below I listed a few of the bigger issues we had (we gathered them based on the GDI campaign, didn't get to the Nod campaign yet, so it's not fully comprehensive):
      Orca Fighter (serious AI issues, and you need dozens of them to kill something reliably, I can assume the Nod Harpy has similar problems) Jumpjet Troopers (they take forever to get in position and shoot at anything, require constant micro to stop them from landing and getting killed) Air units in general being horrible at revealing terrain and having awkward mobility Anti-armor weapons dealing pathetically low damage to infantry, and non-AP weapons doing almost nothing to armor Flames and railguns getting caught on slopes Unit voices (not enough variety, the TS Retro mod had an amusing solution for this) Firestorm walls do not work This is all that came to mind off the top of my head. Any suggestions?
    • By Techstorm
      I was playing Tiberian Sun, (as it is my favorite game in the Tiberium series.) and I noticed some problems, mainly this one. I was playing TS's First Decade release patched with TSpatch and running it using the automatic/GDI renderer. On my first attempt to play the GDI campaign, the game took longer than expected to load, but the first mission worked fine, but afterward the score screen had some graphical ghosting issues, but it didn't mess up anything, I moved on to the second mission and everything went fine in till the end, when "mission accomplished" was supposed to appear, the screen went white, the CGI cutscene plays, then the game automatically closes. I made one more attempt and the same happened minus the glitchy score screen. IDK what's happening, can somebody please fix this or tell me how I can?
      Please respond soon.
      Thank you.
    • By EatMyCar
      Hi!
      OSX Mojave user here.
      I tried installing the SP campaign, etc for Tiberian Sun today and I got this strange popup:
      "Linux/Mac: Please make sure either Wine+winetricks dotnet 2.0 or Crossover is installed to be able to play online".
      I tapped OK since I'm not going online, then it gives me the list of things I want to install. I select all, and it won't install them. It gets to 99% and says it can't install them, so I uncheck everything and just select Single Player missions. it works! Weird. Map editor installed fine too on a second go-around as well as desktop shortcuts. It seems to not want to install music or movies... grr.
      So it goes back to the main menu and I pick Single Player, and I just get the Tiberian Sun main menu in an all-black screen (I can hear the ambient music, the buttons when I roll my mouse over them, but it's just all black). What's the deal here? 
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...