Author Topic: Regged user lost after reboot  (Read 1799 times)

0 Members and 1 Guest are viewing this topic.

Offline Ravage

  • Junior Member
  • **
  • Posts: 15
  • Karma: +1/-0
  • Forever Metal
Regged user lost after reboot
« on: 13 May, 2012, 19:25:58 »
Ptokax 0.4.2.0 [build 390] LUA 5.2.0 on Winserver 2008 R2 Data Center or Windows 7 HP 64 bit

Hi,

one of my hubs is on a virtual server, the server is rented.
Anyone who has had experience with virtual servers rented, knows
that it may come to accidental shutdowns and reboots sometime.
Well sometimes it makes sense, because updates must be installed etc, but
this is not the main problem.

The problem I have is, if the server restarts are executed, then I discover
always that recently registered users, no longer can be found in the registry list.
Well, I thought no problem, the user must be just registered again.

A few days later, the same phenomenon, which previously registered user
were again not shown in the user registry list, afer the server restarted even
though they were in the registry list before in the GUI.
Of course, people get angry when they lose their account permanently ...

I then have set up on a test basis another new hub on my home server to find the cause.

Test:
I have registered a user, he apeared in the Reg List in the GUI and closed the hubsoft and
restarted my machine, and reboot I noticed that he is not listed in the reg list anymore.
Well, here I am then stumbled on something...
Once I've registered a user, then they appear in the GUI in the Registered user list
but not in the RegisteredUsers.xml file. I noticed, those ppl that are in the XML file
are save from getting lost :p sounds stupid I know.


I asked myself how can I get the previous registered user in the RegisteredUsers.xml file?
Well, the solution was simply to click on "Save Settings",
and voila, there they are.

Question:
Am I doing something wrong? No?
Can we get the "auto save all settings every [XX] Minutes" Option ?

Regards,
Ravage
Classic Rock to Modern Metal
metal-unity.no-ip.org:980
Join Us!

PtokaX forum

Regged user lost after reboot
« on: 13 May, 2012, 19:25:58 »

Offline PPK

  • Administrator
  • Emperor
  • *****
  • Posts: 1 475
  • Karma: +209/-22
  • PtokaX developer
Re: Regged user lost after reboot
« Reply #1 on: 13 May, 2012, 20:17:33 »
Code: [Select]
nSaveInterval = 60 -- save interval in minutes

function OnStartup()
   TmrMan.AddTimer(nSaveInterval * (60 * 1000), "SaveRegs")
end

function SaveRegs(uTimerId)
   RegMan.Save()
end
"Most of you are familiar with the virtues of a programmer. There are three, of course: laziness, impatience, and hubris." - Larry Wall

Offline Ravage

  • Junior Member
  • **
  • Posts: 15
  • Karma: +1/-0
  • Forever Metal
Re: Regged user lost after reboot
« Reply #2 on: 13 May, 2012, 20:39:14 »
Thanks much,
Appreciate.


Regards,
Ravage
Classic Rock to Modern Metal
metal-unity.no-ip.org:980
Join Us!

Offline Black-Dragon

  • Member
  • ***
  • Posts: 47
  • Karma: +0/-7
Re: Regged user lost after reboot
« Reply #3 on: 20 May, 2012, 13:04:09 »
Hi, I wanted to know and do possibbile so that when you save the settings in the main feed I send a chat in the op?

Offline the-master

  • Triple Ace
  • **
  • Posts: 217
  • Karma: +10/-15
Re: Regged user lost after reboot
« Reply #4 on: 20 May, 2012, 13:12:58 »
Code: [Select]
nSaveInterval = 60 -- save interval in minutes

function OnStartup()
   TmrMan.AddTimer(nSaveInterval * (60 * 1000), "SaveRegs")
end

function SaveRegs(uTimerId)
   RegMan.Save()
   Core.SendToOpChat("<"..SetMan.GetString(21).."> Registered Userlist Updated")
end
keep on sharing :)
dchub://kickincountryhub.no-ip.org

PtokaX forum

Re: Regged user lost after reboot
« Reply #4 on: 20 May, 2012, 13:12:58 »