1. Beatrix Willius
  2. Valentina Server
  3. Суббота, Май 11 2019, 11:57 AM
  4.  Подписаться через email
I'm finalising my Valentina installer. When I drop a random file into the licenses folder and restart the server with the preferences pane I get an error message "there is no license on the server".

When the server is started successfully then I get a log file with the information. But I can't always be sure that the log output is to a file and not to the console.

How do I get the information about the license for my installer? Do I simply restart the server after installing the license and if the server doesn't start I don't have a license?

Mit freundlichen Grüßen/Regards

Beatrix Willius

http://www.mothsoftware.com
Mail Archiver X: The email archiving solution for professionals
Комментарий
There are no comments made yet.
Beatrix Willius Ответ принят
Can you give me a hint what I need to check? This is the final piece I need for my Valentina Server installer.

Mit freundlichen Grüßen/Regards

Beatrix Willius

http://www.mothsoftware.com
Mail Archiver X: The email archiving solution for professionals
Комментарий
There are no comments made yet.
Ivan Smahin Ответ принят
vServer will start even without any license:

WARNING: Not found any valid license.
vServer is still working though (single connection allowed).

No matter what the files in the licenses folder - if there is no valid license, vServer starts with a single available connection.
Комментарий
There are no comments made yet.
Ivan Smahin Ответ принят
"get property CONNECTIONSMAX of server"

if you get '1', then you have no or invalid license(s).
Комментарий
There are no comments made yet.
Beatrix Willius Ответ принят
@Ivan Smahin: thanks, that is clever.
Комментарий
There are no comments made yet.
Beatrix Willius Ответ принят
Had some other bugs to kill. Checking CONNECTIONSMAX works fine. It's, however, kind of too late when I check the property.

I first make a connection and then make the server with the connection:

dim ConnectionThread as new getConnectionThread(Host, Login, ServerPassword, Port, conserv, MaxUsers)
ConnectionThread.Run
'some code
'if the connection is over the maxconnections there is already an error here

theDatabaseConnection = ConnectionThread.getConnection
theServer = new VServer(theDatabaseConnection)

dim temp as String = theServer.GetVariable("CONNECTIONSMAX";)

The PrefPane is very simple and does the checking without having a connection. Is this possible or is this secret?

Mit freundlichen Grüßen/Regards

Beatrix Willius

http://www.mothsoftware.com
Mail Archiver X: The email archiving solution for professionals
Комментарий
There are no comments made yet.
Beatrix Willius Ответ принят
Or does the Prefs Pane only check if there is a file in the licences folder?

The error handling of the Prefs Pane sucks, by the way. There is no error handling at all.
Комментарий
There are no comments made yet.
Beatrix Willius Ответ принят
When I do the vServer example:


connection = New VConnection( host, "sa", "sa", 15432, 30, "Fxxx" )
connection.Open()
srv = new VServer( connection )

dim MaxConnections as Integer = val(srv.GetVariable("CONNECTIONSMAX"))


I get a value of 5 for MaxConnections without any license. Bug or feature?
Вложения
Комментарий
There are no comments made yet.
Ivan Smahin Ответ принят
Or does the Prefs Pane only check if there is a file in the licences folder?


Actually, yes - it is very naive checks.
Комментарий
There are no comments made yet.
Ivan Smahin Ответ принят
Had some other bugs to kill. Checking CONNECTIONSMAX works fine. It's, however, kind of too late when I check the property.


You may do it via REST interface, though, it is still require connection. Ok, one more way is SNMP protocol. Currently, CONNECTIONSMAX is not supported there, but we can implement it.
Комментарий
There are no comments made yet.
Ivan Smahin Ответ принят
When I do the vServer example:


connection = New VConnection( host, "sa", "sa", 15432, 30, "Fxxx" )
connection.Open()
srv = new VServer( connection )

dim MaxConnections as Integer = val(srv.GetVariable("CONNECTIONSMAX"))


I get a value of 5 for MaxConnections without any license. Bug or feature?


I guess licences were removed without restarting vServer, so it would not affect CONNECTIONSMAX.
Комментарий
There are no comments made yet.
Beatrix Willius Ответ принят
Thanks, Ivan, the check in the PrefPane makes sense. Simple is good.

Oh, dang, yes, I did the testing for the connectionsmax during the time when I couldn't restart my computer. After restarting and without license I get the correct value of 1.

I'm not a security person. Shouldn't you use the usual security dialog in the PrefPane to get the password? When executing the shell scripts directly the sudo "stays" in the shell.
Комментарий
There are no comments made yet.
  • Страница :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.

Categories

Announcements & News
  1. 0 subcategories
Valentina Studio
  1. 2 subcategories
Valentina Server
  1. 4 subcategories
Valentina Database ADK
  1. 0 subcategories
Valentina Reports ADK
  1. 0 subcategories
Other Discussions
  1. 2 subcategories
BETA Testing
  1. 0 subcategories
Education & Research
  1. 0 subcategories