set max logins
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

set max logins

Started by plop, 27 February, 2005, 22:15:39

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

plop

script 2 change the maximum concurrent logins from ptokax.
iMaxLogins = frmHub:GetMaxLogins()
iLevelHubOwner = 0

function ChatArrival(user, data)
   if user.iProfile == iLevelHubOwner then
	local s,e,sCom, iVal = string.find(data, "%b<>%s+(%S+)%s*(%S*).*|")
	if sCom then
	   if sCom == "!setmaxlogin" then
		if iVal == "" then
		   iVal = iMaxLogins
		else
		   iVal = tonumber(iVal)
		end
		frmHub:SetMaxLogins(iVal)
		user:SendData(frmHub:GetHubBot(), "Max Logins changed to: "..iVal)
		return 1
	   elseif sCom == "!getmaxlogin" then
		user:SendData(frmHub:GetHubBot(), "Max Logins is set to: "..frmHub:GetMaxLogins())
		return 1
	   end
	end
   end
end

plop
http://www.plop.nl lua scripts/howto\'s.
http://www.thegoldenangel.net
http://www.vikingshub.com
http://www.lua.org

>>----> he who fights hatred with hatred, drives the spreading of hatred <----<<

-SkA-

I have a big hub and when I make a reset, users have problems rejoining hub due to max logins set to 500.

Is it possible to increase this max value?
???:::??x??em?-N????:::??? ?wN??

BrianzaLand Blog" style="border:0

plop

Quote from: -SkA- on 25 March, 2006, 16:02:00
I have a big hub and when I make a reset, users have problems rejoining hub due to max logins set to 500.

Is it possible to increase this max value?

thats what the above script is made for.
it doesn't limit the maximum users in the hub, it limits the maximum amount of user able 2 login at the same moment.

plop
http://www.plop.nl lua scripts/howto\'s.
http://www.thegoldenangel.net
http://www.vikingshub.com
http://www.lua.org

>>----> he who fights hatred with hatred, drives the spreading of hatred <----<<

-SkA-

Probably you don't understand what I said:

The problem is not max users, but max login. With the script above, I can set a maximum logins of 500 user at the same moment that is a too low value. Imagine 6000 users rejoining the hub at same moment and limit is set @ 500...
???:::??x??em?-N????:::??? ?wN??

BrianzaLand Blog" style="border:0

-SkA-

The problem is that when there is hub restart, users stay in queue for about 50 minutes.

???:::??x??em?-N????:::??? ?wN??

BrianzaLand Blog" style="border:0

PPK

Max logins is outdated thing originaly created by ptaczek. In 0.3.3.0 b15.25 it limit connections accepted by server thread waiting for processing by main thread... but this is exploitable and create "hub is unable to process your login..." thing and not fix main problem with taking max upload badwith by more users loading userlist (and causing with this dropping other users with "connection reset"). I use this value to create lower value for limiting users to send userlist, but i always don't know what value is best  ::)
"Most of you are familiar with the virtues of a programmer. There are three, of course: laziness, impatience, and hubris." - Larry Wall

plop

Quote from: -SkA- on 26 March, 2006, 18:31:00
Probably you don't understand what I said:

The problem is not max users, but max login. With the script above, I can set a maximum logins of 500 user at the same moment that is a too low value. Imagine 6000 users rejoining the hub at same moment and limit is set @ 500...

i ment the same as you think/wanted, just i now see that this has a max of 500.

plop
http://www.plop.nl lua scripts/howto\'s.
http://www.thegoldenangel.net
http://www.vikingshub.com
http://www.lua.org

>>----> he who fights hatred with hatred, drives the spreading of hatred <----<<

SMF spam blocked by CleanTalk