Linux server run

Started by Nihongo^, Sep 14, 2016, 08:17 AM

Previous topic - Next topic

Nihongo^

im trying to run server on my Linux vps ( 64 bit )

i have few questions

how can i run server i mean commands  ( when i use this command  -allow-server-runas-root the server start but after close the putty server also off how can i fix it ?

how can i restart or turn off the server  ( when i again try to run server it said port already in use but the server is off )


ysc3839

#1
Use the `screen` command.
First, use `screen -S sessionname` to start a new session. Eg `screen -S vcmp`.
Then, start the server normally.

After started the server. Click Ctrl+A+D to return to main session. Then you can disconnect, the server is still running.

When you want to go back. Use `screen -r sessionname`. Eg `screen -r vcmp`.

You can use `screen -ls` to see all running sessions.

Here is a full tutorial of screen: https://www.linux.com/learn/taking-command-terminal-gnu-screen

Xmair

The 8192 port is used somewhere. Try using 'killall mpsvrrel64'.

Credits to Boystang!

VU Full Member | VCDC 6 Coordinator & Scripter | EG A/D Contributor | Developer of VCCNR | Developer of KTB | Ex-Scripter of EAD

.

#3
@Xmair he tried 'killall' but if you notice he couldn't make the difference between a command and an executable file. So he used './killall'




Quote from: ysc3839 on Sep 14, 2016, 09:43 AMUse the `screen` command.

I'm guessing that the next error will be "-bash: screen: command not found" so be ready to answer that too :D



@OP I don't really get you people. You don't know the very first thing about something and yet you insist on using it.

And if you can't read the message in that image "Port in use?" then how dahell did you even reached this age without getting hit by a car or something.

Yes, I might sound a bit harsh but come on.
.

Nihongo^

#4
Thanks ysc3839 its work but still problem how can i restart or turn it off
+
its still saying port in use after using killall

ysc3839

Quote from: Nihongo^ on Sep 14, 2016, 10:31 AMThanks ysc3839 its work but still problem how can i restart or turn it off
+
its still saying port in use after using killall
Restart the whole server using `reboot`. If it don't works. Try to run as root.

aXXo

Run the command 'ps aux' or 'top'
It will list all the processes running with their PIDs. Check if any VCMP server is running, and 'kill PID' to shut it.

Nihongo^

Quote from: ysc3839 on Sep 14, 2016, 02:47 PM
Quote from: Nihongo^ on Sep 14, 2016, 10:31 AMThanks ysc3839 its work but still problem how can i restart or turn it off
+
its still saying port in use after using killall
Restart the whole server using `reboot`. If it don't works. Try to run as root.

i try this but its stuck when i use that command



Quote from: aXXo on Sep 14, 2016, 04:51 PMRun the command 'ps aux' or 'top'
It will list all the processes running with their PIDs. Check if any VCMP server is running, and 'kill PID' to shut it.
Thanks aXXo its really works for me :D but any other solution to restart the server ? instead of kill them again and again

Nihongo^

@edit that cmd top and ps aux work but now its not showing the server name in list  :/


in list


ysc3839

Quote from: Nihongo^ on Sep 14, 2016, 06:11 PM@edit that cmd top and ps aux work but now its not showing the server name in list  :/


in list

I think it's your OS's issue. It refuses you bind a port.

Shovon^

Use a very different port ex 5194 or some other ports
Iam the best and i only believe in Allah

Conatact me here on IRC:  #shovon^ @LUnet

EK.IceFlake

Why are you trying to run it as root?
useradd vcmp
su vcmp
//screen stuff here
./mpsvrrel64

fix no screen:
[on debian]
apt-get install screen
[assuming you are on root, otherwise prefix it with 'sudo ']



To answer your question, you need to make a script that saves its PID in some file, and restart uses pkill from its PID and start a new one and save the new PID