sending msg to a server running in a screen

Discuss anything to do with Nexuiz here.

Moderators: Nexuiz Moderators, Moderators


  • hi,
    is it possible to send messages to a server running in a "screen" ( launched with "screen -dmS nesuizserver ./launchNexuizServer.sh" )

    i tried with -X and -S options of screen but didn't work.

    have you got an idea, or a solution ?


    ParkSTø

    PS :
    it's for atomatic stuff, of course. i think i can't use screen -r
    parksto
    Member
     
    Posts: 25
    Joined: Sun May 07, 2006 1:30 pm

Sat May 13, 2006 11:48 pm

  • Try divVerent's RubyPlaces. It probably can do everthing you need and if not you can write a plugin or use sockets (tcp/udp/unix)...
    User avatar
    KadaverJack
    Site admin and forum addon
     
    Posts: 1102
    Joined: Tue Feb 28, 2006 9:42 pm

Sun May 14, 2006 12:26 pm

  • screen -r nexuizserver1 will bring up the console, but are you trying to avoid that?
    the spice extend life!
    the spice expand conciousness!
    the spice is vital to space travel!
    sooooo.. tell me what you want, waht you really-really want
    I will proceed directly to the intravenous injection of hard drugs, please.
    User avatar
    tChr
    Forum addon
     
    Posts: 1501
    Joined: Tue Feb 28, 2006 9:11 pm
    Location: Trondheim, Norway

Wed May 17, 2006 2:24 pm

  • yes...

    i'm trying to automate actions.
    parksto
    Member
     
    Posts: 25
    Joined: Sun May 07, 2006 1:30 pm

Sat May 20, 2006 10:05 pm

  • in the small window where you see the happenings of the server. Yeah you just type what you want to say and it sends it to the server. or you type Say blah blah and it should work. I did that on mine and it worked.
    User avatar
    Bl@nk
    Member
     
    Posts: 22
    Joined: Wed Mar 01, 2006 1:56 pm

Sat May 20, 2006 11:51 pm

  • What he is trying to do is to send messages automatically to a server running in a screen without really attaching to the screen first. He is working on a system to automate management of game servers iirc, and some games server, most, and expecially nexuiz doesnt like to be running in the BG, hence you use a scren, but making a script that connects to a screen, sned commands and then detaches again is a bit harder.

    I'll let you know if I find out.

    edit "screen" is a *nix console tool for virtual consoles, not the PC screen it self :)
    the spice extend life!
    the spice expand conciousness!
    the spice is vital to space travel!
    sooooo.. tell me what you want, waht you really-really want
    I will proceed directly to the intravenous injection of hard drugs, please.
    User avatar
    tChr
    Forum addon
     
    Posts: 1501
    Joined: Tue Feb 28, 2006 9:11 pm
    Location: Trondheim, Norway

Mon May 22, 2006 7:34 am

  • tChr wrote:What he is trying to do is to send messages automatically to a server running in a screen without really attaching to the screen first. He is working on a system to automate management of game servers iirc, and some games server, most, and expecially nexuiz doesnt like to be running in the BG, hence you use a scren, but making a script that connects to a screen, sned commands and then detaches again is a bit harder.


    And it's doomed to fail. I did that for some time... and it was not reliable at all. Main problems being: latency from "tail -f logfile" to my log reading script was quite long, and sometimes messages got mixed up when sending them to the screen's keyboard input buffer.

    Well, this was then exactly what I wrote RubyPlaces for... even though some of it will get removed once Nexuiz 1.6 comes out (especially the map rotation handling which is finally good enough in 1.6), the other half is still the generic control framework and the IPC sources.

    RubyPlaces: http://www.forums.alientrap.local/viewtopic.php?t=39
    1. Open Notepad
    2. Paste: ÿþMSMSMS
    3. Save
    4. Open the file in Notepad again

    You can vary the number of "MS", so you can clearly see it's MS which is causing it.
    User avatar
    divVerent
    Site admin and keyboard killer
     
    Posts: 3809
    Joined: Thu Mar 02, 2006 4:46 pm
    Location: BRLOGENSHFEGLE



Return to Nexuiz - General Discussion




Information
  • Who is online
  • Users browsing this forum: No registered users and 1 guest