Stefan1200's Forum

English => General Discussions => Topic started by: fonzy on December 07, 2011, 04:36:50 PM

Title: installation JTS3ServerMod
Post by: fonzy on December 07, 2011, 04:36:50 PM
Hello guys, sorry my English but I am an Italian boy.
I have a server on a vps linux centos5 TS3. I would like to install the JTS3ServerMod on my server.
I installed the package java-1.6.0-openjdk (yum install java-1.6.0-openjdk) on the VPS.
Should I install the java package jre-7u1-linux oracle-x64.rpm (http://www.oracle.com/technetwork/java/javase/downloads/jre-7u1-download-513652.html)?

After installing the package java-1.6.0-openjdk, I launched the command java-version but I got this error:

Code: [Select]
[root@clienti ~]# java -version
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.

I do not understand something wrong, why this mistake? What should I do?

Thanks for your help.

PS.my VPS have 5gb Hard disk and 200mb RAM
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 07, 2011, 05:17:30 PM
200 mb ram is not much and might be to less to start the java virtual machine. If you already get problems with java -version, I don't think that you get the bot running. But you can try the command for vservers from the bot readme file.
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 07, 2011, 06:22:25 PM
But you can try the command for vservers from the bot readme file.

what would that command?

How much ram do you think should have my VPS?

Thanks
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 07, 2011, 06:53:44 PM
what would that command?

Try this:
java -mx30M -version
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 07, 2011, 07:19:32 PM
nothing, always the same error  :'(

Code: [Select]
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.

What can I do?

How much ram do you think should have my VPS?

thanks
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 07, 2011, 08:17:10 PM
How much ram do you think should have my VPS?

I don't know the exact number, but 200 MB is not much. I know that a VPS with 1 GB is able to run the bot (including TS3 server and some more stuff).
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 07, 2011, 08:31:04 PM
then you tell me that the problem is definitely the fault of the little ram? It is not a problem of linux, centos, vps, java or something else?

However, just to run the bot in java-1.6.0-openjdk stall or should I install the java package jre-7u1-linux oracle-x64.rpm (http://www.oracle.com/technetwork/java/javase/downloads/jre-7u1-download-513652.html)?

thanks
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 08, 2011, 05:50:51 AM
then you tell me that the problem is definitely the fault of the little ram? It is not a problem of linux, centos, vps, java or something else?

However, just to run the bot in java-1.6.0-openjdk stall or should I install the java package jre-7u1-linux oracle-x64.rpm (http://www.oracle.com/technetwork/java/javase/downloads/jre-7u1-download-513652.html)?

Neve tested the bot with Java 7, but it should work. On my server the bot runs with java-1.6.0-openjdk. The error message is quite exact, too less memory. But you can try this:
java -mx20M -version
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 08, 2011, 06:11:40 PM
I confirm, I did some tests and we wilt at least 400mb to run Java on VPS ... the cost is too high for me!
since your server works via telnet, I wanted to ask what is the command to run queries to send a private message to all users connected to a particular group?
maybe I can make a small script that does just that since I'd used the bot for this reason.
thanks for your help.
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 11, 2011, 07:21:57 AM
To get a client list with server group information:
clientlist -groups

To send a message to a specified client:
sendtextmessage targetmode=3 target=CLIENT_ID msg=MESSAGE
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 11, 2011, 12:43:58 PM
thanks for the information.
because if I send the query message is sent from the sender's private "serveradmin from IP"?
You can not set a different sender name?

hi
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 11, 2011, 03:48:21 PM
You can not set a different sender name?

After you established the connection to the server query interface:
clientupdate client_nickname=NICKNAME
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 11, 2011, 04:02:26 PM
THANK YOU! :-)

I have read many times the guide but I had not noticed that feature.

Sorry if you fill it with questions, but you're the only one I know who knows very well the teamspeak query.

How do I know which channel is a user? I checked all the queries and there is none that give me this information. could you tell me how?

thanks Stefan
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 11, 2011, 04:09:31 PM
How do I know which channel is a user? I checked all the queries and there is none that give me this information. could you tell me how?

If I remember right, it is the cid variable at the client list.
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 13, 2011, 07:30:27 PM
without your help I would not have succeeded. thanks
  ;)
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 21, 2011, 07:22:55 PM
hello stefan
I noticed that your model can read the messages that are sent to the server as! botinfo. I wanted to ask you how you doing? There is a file that is saved of all conversations?

Also how do you know that a user has logged into the server to send a welcome message?

thanks
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 21, 2011, 07:27:56 PM
I don't understand this question. Who is reading what? What do you mean with model? The bot don't save any conversations. The only stuff the bot is holding in memory are client information like last online time, unique id, nickname and client database id. And of course the permission and server group list for some features. But no chat data will be saved by the bot.

Only the usage of bot commands, like !botinfo, are written to the bot logfile.

Edit: After reading your edit I understand what you mean. You can register some events, like people joining/leaving the server and chat messages to receive them. But I don't know how to handle that with PHP, because you need a permanent telnet connection to the TS3 server.
Title: Re: installation JTS3ServerMod
Post by: fonzy on December 21, 2011, 09:01:34 PM
I meant: how do you retrieve the! botinfo I write in chat?

both Java and PHP work with telnet. If java retrieves commands that i write in chat, can also do php.
Title: Re: installation JTS3ServerMod
Post by: Stefan1200 on December 21, 2011, 09:15:06 PM
I meant: how do you retrieve the! botinfo I write in chat?

Check the command servernotifyregister