Koozali.org: home of the SME Server

Counter Strike Source dedicated server is only LAN

Offline Wepa

  • 4
  • +0/-0
Counter Strike Source dedicated server is only LAN
« on: June 27, 2008, 09:17:25 PM »
Hi!

I have followed this guide without any problems.
My Counter Strike Source server works fine, but only LAN. I can only connect to the local ip 192.168.0.130:27015
Neither me or my friends can connect to my public ip.

The server is connected by wire to my D-Link DIR-655 router, and therefore the server is configured to "Server only".
The servers internet connection WORKS, because my friends can download stuff from the server and view it's website. I have also updated it through the server-manager.

I have forwarded every port which is needed for running a public CS:S server, but nothing works.
I have also tried to DMZ the server.
Furthermore my ISP is NOT blocking any ports.
My server.cfg is also in order and I have typed sv_lan 0

I have search for many many hours in this forum + Google, but i didn't find any solutions.

What is wrong?

I am really hoping to get some usefull answers! :-)

Offline Jáder

  • *
  • 1,099
  • +0/-0
    • LinuxFacil
Re: Counter Strike Source dedicated server is only LAN
« Reply #1 on: June 27, 2008, 10:29:47 PM »
You need to open TCP Port on SME server.
This is done by:
Code: [Select]
config set CounterStrike service access public status enabled TCPPort 27015
signal-event remoteaccess-update

You should search for "Open port" on SME forums.

In this page ( http://wiki.contribs.org/Firewall ) under DB Settings you´ll find more info about this.

Good luck.

Jáder
...

Offline Wepa

  • 4
  • +0/-0
Re: Counter Strike Source dedicated server is only LAN
« Reply #2 on: June 28, 2008, 08:25:55 PM »
Many many thanks for your help!

But i still has a problem. I don't know the service name for the server.

I think the service name is srcds_i686, but i don't know how to find it?
I have tried this, but i was not working and i have also tried with srcds as service name. (maybe there is an easier way to open port range's, but I don't care! :-P)

Code: [Select]
config set srcds_i686 service access public status enabled UDPPort 1200
config set srcds_i686 service access public status enabled TCPPort 1200
config set srcds_i686 service access public status enabled UDPPort 5273
config set srcds_i686 service access public status enabled TCPPort 5273
config set srcds_i686 service access public status enabled UDPPort 6003
config set srcds_i686 service access public status enabled TCPPort 6003
config set srcds_i686 service access public status enabled UDPPort 7002
config set srcds_i686 service access public status enabled TCPPort 7002
config set srcds_i686 service access public status enabled UDPPort 27005
config set srcds_i686 service access public status enabled TCPPort 27005
config set srcds_i686 service access public status enabled UDPPort 27006
config set srcds_i686 service access public status enabled TCPPort 27006
config set srcds_i686 service access public status enabled UDPPort 27007
config set srcds_i686 service access public status enabled TCPPort 27007
config set srcds_i686 service access public status enabled UDPPort 27008
config set srcds_i686 service access public status enabled TCPPort 27008
config set srcds_i686 service access public status enabled UDPPort 27009
config set srcds_i686 service access public status enabled TCPPort 27009
config set srcds_i686 service access public status enabled UDPPort 27010
config set srcds_i686 service access public status enabled TCPPort 27010
config set srcds_i686 service access public status enabled UDPPort 27011
config set srcds_i686 service access public status enabled TCPPort 27011
config set srcds_i686 service access public status enabled UDPPort 27012
config set srcds_i686 service access public status enabled TCPPort 27012
config set srcds_i686 service access public status enabled UDPPort 27013
config set srcds_i686 service access public status enabled TCPPort 27013
config set srcds_i686 service access public status enabled UDPPort 27014
config set srcds_i686 service access public status enabled TCPPort 27014
config set srcds_i686 service access public status enabled UDPPort 27015
config set srcds_i686 service access public status enabled TCPPort 27015
config set srcds_i686 service access public status enabled UDPPort 27016
config set srcds_i686 service access public status enabled TCPPort 27016
signal-event remoteaccess-update

Offline aa-ee

  • 1
  • +0/-0
Re: Counter Strike Source dedicated server is only LAN
« Reply #3 on: June 29, 2008, 11:56:43 AM »
Did you also port forward on your Router ?

Offline Wepa

  • 4
  • +0/-0
Re: Counter Strike Source dedicated server is only LAN
« Reply #4 on: June 29, 2008, 12:49:21 PM »
Did you also port forward on your Router ?
Yes.. All the ports above are forwarded to the server.

How to find the service name?

Offline Jáder

  • *
  • 1,099
  • +0/-0
    • LinuxFacil
Re: Counter Strike Source dedicated server is only LAN
« Reply #5 on: June 30, 2008, 12:50:56 AM »
you do have to KNOW the service name... you name it! at least AFAIK!

I not sure about issue all those commands or issue one/several with a port range. Something like:
Code: [Select]
config set CounterStrike_SRV service access public status enabled TCPPort 27010-27050
Do you realy need all those ports open ?

to be sure your server is accepting connections in a port do:
Code: [Select]
netstat -an|grep <PORT>Should show something like:
Code: [Select]
[root@coelho ~]# netstat -an|grep 10050
tcp        0      0 0.0.0.0:10050               0.0.0.0:*                   LISTEN     
This way you'll know your server is waiting for connections on <PORT>
Later search on iptables rules for that port:

Code: [Select]
iptables -L |grep <PORT or service name>
Should show something like:
Code: [Select]
[root@coelho ~]# iptables -L|grep 10050
ACCEPT     tcp  --  anywhere             xxxxxxxxxxxxxx tcp dpt:10050
That would show you if iptables (linux firewall) is correctly configurated to allow connections for outside.

As last step search in logs for connection errors.

Jáder
...

Offline william_syd

  • *****
  • 1,608
  • +0/-0
  • Nothing to see here.
    • http://www.magicwilly.info
Re: Counter Strike Source dedicated server is only LAN
« Reply #6 on: June 30, 2008, 05:37:41 AM »
Use TCPPorts for a range of ports.

Refer this NFR bug.

http://bugs.contribs.org/show_bug.cgi?id=56#c12

Also what do you get from

config show | grep =service

Post the result in a code block.

Edit:

Reading your first post again it looks like you used a generic how-to. Even the one on contribs

http://wiki.contribs.org/Half-Life_Dedicated_Server

is a little generic.

If you are in server-gateway mode use server-manager to forward the required ports to localhost or 127.0.0.1

For server-only mode you will have todo what Jader advised.

config set CounterStrike service \
access public \
status enabled \
TCPPorts 1200,5273,6003,7002,27005:27016 \
UDPPorts 1200,5273,6003,7002,27005:27016

signal-event remoteaccess-update









« Last Edit: June 30, 2008, 06:17:02 AM by william_syd »
Regards,
William

IF I give advise.. It's only if it was me....

Offline Wepa

  • 4
  • +0/-0
Re: Counter Strike Source dedicated server is only LAN
« Reply #7 on: June 30, 2008, 06:01:23 PM »
MANY THANKS FOR YOUR HELP!! :D

The server works perfect now.
If you are curious william, the server writes this when i type "config show | grep =service"...
Code: [Select]
   CounterStrike=service
   CounterStrike_SRV=service
DynDNS=service
acpid=service
apmd=service
atalk=service
backup=service
bootstrap-console=service
clamav=service
clamd=service
cpuspeed=service
crond=service
   cstrike=service
ctrlaltdel=service
dhcpd=service
dnscache=service
dnscache.forwarder=service
fetchmail=service
freshclam=service
ftp=service
haldaemon=service
horde=service
httpd-admin=service
httpd-e-smith=service
imap=service
imaps=service
imp=service
ippp=service
irqbalance=service
isdn=service
klogd=service
ldap=service
local=service
lpd=service
masq=service
messagebus=service
microcode_ctl=service
modPerl=service
modSSL=service
mysql.init=service
mysqld=service
network=service
nmbd=service
ntpd=service
nut=service
oidentd=service
pam_abl=service
pam_tally=service
php=service
pop3=service
pop3s=service
pppoe=service
pptpd=service
qmail=service
qpsmtpd=service
radiusd=service
raidmonitor=service
serial-console=service
smartd=service
smb=service
smbd=service
smolt=service
smtp-auth-proxy=service
smtpd=service
spamassassin=service
spamd=service
sqpsmtpd=service
squid=service
   srcds=service
   srcds_i686=service
   srcds_run=service
sshd=service
ssmtpd=service
statusreport=service
syslog=service
testing=service
tinydns=service
wan=service
yum=service

I do not know the issue why it wasn't working before but williams command solved the problem:
Code: [Select]
config set CounterStrike service \
access public \
status enabled \
TCPPorts 1200,5273,6003,7002,27005:27016 \
UDPPorts 1200,5273,6003,7002,27005:27016

signal-event remoteaccess-update
Yes.. The server is in server-only mode.

Thank you very much, both of you guys! :D
« Last Edit: June 30, 2008, 06:03:16 PM by Wepa »

Offline Jáder

  • *
  • 1,099
  • +0/-0
    • LinuxFacil
Re: Counter Strike Source dedicated server is only LAN
« Reply #8 on: June 30, 2008, 07:40:44 PM »
you´re welcome.
You could write an wiki page to document your configuration (an HowTo about CounterStrike server).

That would be a perfect retribution for our help.

See you

Bye.

Jáder
...

Offline andrewk04

  • 2
  • +0/-0
Re: Counter Strike Source dedicated server is only LAN
« Reply #9 on: September 24, 2011, 12:52:04 AM »
I do not know the issue why it wasn't working before but williams command solved the problem:
Code: [Select]
config set CounterStrike service \
access public \
status enabled \
TCPPorts 1200,5273,6003,7002,27005:27016 \
UDPPorts 1200,5273,6003,7002,27005:27016

signal-event remoteaccess-update
Yes.. The server is in server-only mode.

Thank you very much, both of you guys! :D
[/quote]

Where do you type this code into? I have the exact problem as the initial post... I can access the console for the server after it's running. Is this done in the command line, if so, how?

Offline cactus

  • *
  • 4,880
  • +3/-0
    • http://www.snetram.nl
Re: Counter Strike Source dedicated server is only LAN
« Reply #10 on: September 24, 2011, 01:19:59 AM »
Where do you type this code into? I have the exact problem as the initial post... I can access the console for the server after it's running. Is this done in the command line, if so, how?
On the command line after you have logged in as root instead of admin, both accounts should have the same password, unless you changed the root account specifically.
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Offline andrewk04

  • 2
  • +0/-0
Re: Counter Strike Source dedicated server is only LAN
« Reply #11 on: September 24, 2011, 03:33:17 AM »
Aren't these terminal (unix) command line codes though? I'm in Windows XP...

Offline cactus

  • *
  • 4,880
  • +3/-0
    • http://www.snetram.nl
Re: Counter Strike Source dedicated server is only LAN
« Reply #12 on: September 24, 2011, 09:41:37 AM »
Aren't these terminal (unix) command line codes though? I'm in Windows XP...
They won't work there. They only work on your server, use putty or access the local terminal directly.
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)