Problem with opening it
#1

Well everything works fine hosts sayserver started succesfuly but when i open on my own PC it works great using the same files, but when i open in the host it's all different, i'll send you the logs it is not giving any problem, just ain't contiuning to run.

Код:
SA-MP Dedicated Server
----------------------
v0.3z, ©2005-2014 SA-MP Team

[19:36:52] 
[19:36:52] Server Plugins
[19:36:52] --------------
[19:36:52]  Loading plugin: streamer.so
[19:36:52] 

*** Streamer Plugin v2.6.1 by Incognito loaded ***

[19:36:52]   Loaded.
[19:36:52]  Loading plugin: irc.so
[19:36:52] 

*** IRC Plugin v1.4.2 by Incognito loaded ***

[19:36:52]   Loaded.
[19:36:52]  Loading plugin: sscanf.so
[19:36:52] 

[19:36:52]  ===============================

[19:36:52]       sscanf plugin loaded.     

[19:36:52]    © 2009 Alex "******" Cole

[19:36:52]    0.3d-R2 500 Players "dnee"

[19:36:52]  ===============================

[19:36:52]   Loaded.
[19:36:52]  Loaded 3 plugins.

[19:36:52] 
[19:36:52] Filterscripts
[19:36:52] ---------------
[19:36:52]   Loading filterscript 'maps.amx'...
[19:36:52]   Loaded 1 filterscripts.

[19:36:52] Gates loaded successfully.
[19:36:52] ATMs loaded successfully.
[19:36:52] Teleports loaded successfully.
Reply
#2

If it stucks there, it's probably a server crash. You can be sure if you load crashdetect plugin. By compiling with debug info, you can get more information related to server crashes and run time errors such as the line caused it and the last function was called.

By the way, update your plugins. You use old versions for streamer, IRC and sscanf plugins.
Reply
#3

this is what it gives me after doing it, any idea how to fix those?

Код:
[21:13:17] Gates loaded successfully.
[21:13:17] ATMs loaded successfully.
[21:13:17] Teleports loaded successfully.
[21:13:17] [debug] Server crashed while executing EM.amx
[21:13:17] [debug] AMX backtrace:
[21:13:17] [debug] #0 native fclose () [0809a9f0] from samp03svr
[21:13:17] [debug] #1 00005e04 in ?? (0x006b0b70) from EM.amx
[21:13:17] [debug] #2 0009b390 in ?? () from EM.amx
[21:13:17] [debug] #3 000700a4 in public zcmd_OnGameModeInit () from EM.amx
[21:13:17] [debug] #4 native CallLocalFunction () [080dbf60] from samp03svr
[21:13:17] [debug] #5 00008d68 in public Streamer_OnGameModeInit () from EM.amx
[21:13:17] [debug] #6 native CallLocalFunction () [080dbf60] from samp03svr
[21:13:17] [debug] #7 00008654 in public IRC_OnGameModeInit () from EM.amx
[21:13:17] [debug] #8 native CallLocalFunction () [080dbf60] from samp03svr
[21:13:17] [debug] #9 00007e4c in public OnGameModeInit () from EM.amx
[21:13:17] [debug] Native backtrace:
[21:13:17] [debug] #0 00ec309b in _ZN10StackTraceC1EPv () from plugins/crashdetect.so
[21:13:17] [debug] #1 00ebe2d2 in _ZN11CrashDetect20PrintNativeBacktraceERSoPv () from plugins/crashdetect.so
[21:13:17] [debug] #2 00ebeebc in _ZN11CrashDetect20PrintNativeBacktraceEPv () from plugins/crashdetect.so
[21:13:17] [debug] #3 00ebf366 in _ZN11CrashDetect11OnExceptionEPv () from plugins/crashdetect.so
[21:13:17] [debug] #4 00ec2cec in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #5 00498410 in ?? ()
[21:13:17] [debug] #6 00204877 in fclose () from /lib/libc.so.6
[21:13:17] [debug] #7 0809aa04 in ?? () from ./samp03svr
[21:13:17] [debug] #8 08093d84 in ?? () from ./samp03svr
[21:13:17] [debug] #9 00ebbb9c in _ZN11CrashDetect13DoAmxCallbackEiPiS0_ () from plugins/crashdetect.so
[21:13:17] [debug] #10 00ec1d38 in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #11 00ec81f8 in amx_Exec () from plugins/crashdetect.so
[21:13:17] [debug] #12 00ebe218 in _ZN11CrashDetect9DoAmxExecEPii () from plugins/crashdetect.so
[21:13:17] [debug] #13 00ec1aa9 in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #14 080dc202 in ?? () from ./samp03svr
[21:13:17] [debug] #15 08093d84 in ?? () from ./samp03svr
[21:13:17] [debug] #16 00ebbb9c in _ZN11CrashDetect13DoAmxCallbackEiPiS0_ () from plugins/crashdetect.so
[21:13:17] [debug] #17 00ec1d38 in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #18 00ec81f8 in amx_Exec () from plugins/crashdetect.so
[21:13:17] [debug] #19 00ebe218 in _ZN11CrashDetect9DoAmxExecEPii () from plugins/crashdetect.so
[21:13:17] [debug] #20 00ec1aa9 in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #21 080dc202 in ?? () from ./samp03svr
[21:13:17] [debug] #22 08093d84 in ?? () from ./samp03svr
[21:13:17] [debug] #23 00ebbb9c in _ZN11CrashDetect13DoAmxCallbackEiPiS0_ () from plugins/crashdetect.so
[21:13:17] [debug] #24 00ec1d38 in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #25 00ec81f8 in amx_Exec () from plugins/crashdetect.so
[21:13:17] [debug] #26 00ebe218 in _ZN11CrashDetect9DoAmxExecEPii () from plugins/crashdetect.so
[21:13:17] [debug] #27 00ec1aa9 in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #28 080dc202 in ?? () from ./samp03svr
[21:13:17] [debug] #29 08093d84 in ?? () from ./samp03svr
[21:13:17] [debug] #30 00ebbb9c in _ZN11CrashDetect13DoAmxCallbackEiPiS0_ () from plugins/crashdetect.so
[21:13:17] [debug] #31 00ec1d38 in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #32 00ec81f8 in amx_Exec () from plugins/crashdetect.so
[21:13:17] [debug] #33 00ebe218 in _ZN11CrashDetect9DoAmxExecEPii () from plugins/crashdetect.so
[21:13:17] [debug] #34 00ec1aa9 in ?? () from plugins/crashdetect.so
[21:13:17] [debug] #35 080a36bb in ?? () from ./samp03svr
[21:13:17] [debug] #36 080a98bd in ?? () from ./samp03svr
[21:13:17] [debug] #37 080a8162 in ?? () from ./samp03svr
[21:13:17] [debug] #38 001bad26 in __libc_start_main () from /lib/libc.so.6
[21:13:17] [debug] #39 0804b4a1 in ?? () from ./samp03svr
Reply
#4

It's probably the 5th time I've been saying this today (in similar threads): using invalid file handle in file functions will result in server crash.

If you had compiled with -d3, we would have just got the line but now the only clues we have is that fclose crashed the server, the callback OnGameModeInit (which probably calls 2 more function (1 and inside that, 1 more)) and that the problem is after loading the teleports.
Reply
#5

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
It's probably the 5th time I've been saying this today (in similar threads): using invalid file handle in file functions will result in server crash.

If you had compiled with -d3, we would have just got the line but now the only clues we have is that fclose crashed the server, the callback OnGameModeInit (which probably calls 2 more function (1 and inside that, 1 more)) and that the problem is after loading the teleports.
Im the sure the problem is not the script since it works great, i've also seen my plugins versions on my main PC(Where server works great), and host one, and i've noticed that plugins on my main PC(the one where the server works) are even older than the others of the host but the script is not working, i will send you logs of both ones:

The one that works
Код:
A-MP Dedicated Server
----------------------
v0.3z, ©2005-2014 SA-MP Team

[11:18:53] 
[11:18:53] Server Plugins
[11:18:53] --------------
[11:18:53]  Loading plugin: sscanf.dll
[11:18:53] 

[11:18:53]  ===============================

[11:18:53]       sscanf plugin loaded.     

[11:18:53]    © 2009 Alex "******" Cole

[11:18:53]  ===============================

[11:18:53]   Loaded.
[11:18:53]  Loading plugin: streamer.dll
[11:18:53] 

*** Streamer Plugin v2.6 by Incognito loaded ***

[11:18:53]   Loaded.
[11:18:53]  Loading plugin: nativechecker.dll
[11:18:53]   Loaded.
[11:18:53]  Loading plugin: irc.dll
[11:18:53] 

*** IRC Plugin v1.3.5 by Incognito loaded ***


[11:18:53]   Loaded.
[11:18:53]  Loaded 4 plugins.

[11:18:53] 
[11:18:53] Ban list
[11:18:53] --------
[11:18:53]  Loaded: samp.ban
[11:18:53] 
[11:18:53] 
[11:18:53] *** IRC Plugin: Could not resolve server address (No such host is known.)
[11:18:53] Filterscripts
[11:18:53] ---------------
[11:18:53]   Loading filterscript 'xyzteleport.amx'...
[11:18:53]   Loaded 1 filterscripts.

[11:18:53]    Error: Function not registered: 'IRC_GetUserChannelMode'
[11:18:53]    Error: Function not registered: 'IRC_CreateGroup'
[11:18:53]    Error: Function not registered: 'IRC_Quit'
[11:18:53]    Error: Function not registered: 'IRC_DestroyGroup'
[11:18:53]    Error: Function not registered: 'IRC_Connect'
[11:18:53]    Error: Function not registered: 'IRC_JoinChannel'
[11:18:53]    Error: Function not registered: 'IRC_AddToGroup'
[11:18:53]    Error: Function not registered: 'IRC_RemoveFromGroup'
[11:18:53]    Error: Function not registered: 'IRC_GroupSay'
[11:18:53]    Error: Function not registered: 'IRC_GroupNotice'
[11:18:53]    Error: Function not registered: 'IRC_ChangeNick'
[11:18:53] Gates loaded successfully.
[11:18:53] ATMs loaded successfully.
[11:18:54] Teleports loaded successfully.
[11:18:59] Total Cars:958 - Vehicles types: 90
[11:18:59] :: GameMode Started -> 11:18:59 - 29/4/2014 (1398763139) ::
[11:18:59] Debug level: 0
The one that is not working(Host)
Код:
SA-MP Dedicated Server
----------------------
v0.3z, ©2005-2014 SA-MP Team

[21:14:11] 
[21:14:11] Server Plugins
[21:14:11] --------------
[21:14:11]  Loading plugin: streamer.so
[21:14:11] 

*** Streamer Plugin v2.6.1 by Incognito loaded ***

[21:14:11]   Loaded.
[21:14:11]  Loading plugin: irc.so
[21:14:11] 

*** IRC Plugin v1.4.2 by Incognito loaded ***

[21:14:11]   Loaded.
[21:14:11]  Loading plugin: sscanf.so
[21:14:11] 

[21:14:11]  ===============================

[21:14:11]       sscanf plugin loaded.     

[21:14:11]    © 2009 Alex "******" Cole

[21:14:11]    0.3d-R2 500 Players "dnee"

[21:14:11]  ===============================

[21:14:11]   Loaded.
[21:14:11]  Loading plugin: nativechecker.so
[21:14:11]   Loaded.
[21:14:11]  Loading plugin: crashdetect.so
[21:14:11]   CrashDetect v4.13.1 is OK.
[21:14:11]   Loaded.
[21:14:11]  Loaded 5 plugins.

[21:14:11] 
[21:14:11] Filterscripts
[21:14:11] ---------------
[21:14:11]   Loading filterscript 'maps.amx'...
[21:14:11]   Loaded 1 filterscripts.

[21:14:11] Gates loaded successfully.
[21:14:11] ATMs loaded successfully.
[21:14:11] Teleports loaded successfully.
[21:14:11] [debug] Server crashed while executing EM.amx
[21:14:11] [debug] AMX backtrace:
[21:14:11] [debug] #0 native fclose () [0809a9f0] from samp03svr
[21:14:11] [debug] #1 00005e04 in ?? (0x006b0b70) from EM.amx
[21:14:11] [debug] #2 0009b390 in ?? () from EM.amx
[21:14:11] [debug] #3 000700a4 in public zcmd_OnGameModeInit () from EM.amx
[21:14:11] [debug] #4 native CallLocalFunction () [080dbf60] from samp03svr
[21:14:11] [debug] #5 00008d68 in public Streamer_OnGameModeInit () from EM.amx
[21:14:11] [debug] #6 native CallLocalFunction () [080dbf60] from samp03svr
[21:14:11] [debug] #7 00008654 in public IRC_OnGameModeInit () from EM.amx
[21:14:11] [debug] #8 native CallLocalFunction () [080dbf60] from samp03svr
[21:14:11] [debug] #9 00007e4c in public OnGameModeInit () from EM.amx
[21:14:11] [debug] Native backtrace:
[21:14:11] [debug] #0 004a409b in _ZN10StackTraceC1EPv () from plugins/crashdetect.so
[21:14:11] [debug] #1 0049f2d2 in _ZN11CrashDetect20PrintNativeBacktraceERSoPv () from plugins/crashdetect.so
[21:14:11] [debug] #2 0049febc in _ZN11CrashDetect20PrintNativeBacktraceEPv () from plugins/crashdetect.so
[21:14:11] [debug] #3 004a0366 in _ZN11CrashDetect11OnExceptionEPv () from plugins/crashdetect.so
[21:14:11] [debug] #4 004a3cec in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #5 005cd410 in ?? ()
[21:14:11] [debug] #6 002d4877 in fclose () from /lib/libc.so.6
[21:14:11] [debug] #7 0809aa04 in ?? () from ./samp03svr
[21:14:11] [debug] #8 08093d84 in ?? () from ./samp03svr
[21:14:11] [debug] #9 0049cb9c in _ZN11CrashDetect13DoAmxCallbackEiPiS0_ () from plugins/crashdetect.so
[21:14:11] [debug] #10 004a2d38 in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #11 004a91f8 in amx_Exec () from plugins/crashdetect.so
[21:14:11] [debug] #12 0049f218 in _ZN11CrashDetect9DoAmxExecEPii () from plugins/crashdetect.so
[21:14:11] [debug] #13 004a2aa9 in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #14 080dc202 in ?? () from ./samp03svr
[21:14:11] [debug] #15 08093d84 in ?? () from ./samp03svr
[21:14:11] [debug] #16 0049cb9c in _ZN11CrashDetect13DoAmxCallbackEiPiS0_ () from plugins/crashdetect.so
[21:14:11] [debug] #17 004a2d38 in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #18 004a91f8 in amx_Exec () from plugins/crashdetect.so
[21:14:11] [debug] #19 0049f218 in _ZN11CrashDetect9DoAmxExecEPii () from plugins/crashdetect.so
[21:14:11] [debug] #20 004a2aa9 in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #21 080dc202 in ?? () from ./samp03svr
[21:14:11] [debug] #22 08093d84 in ?? () from ./samp03svr
[21:14:11] [debug] #23 0049cb9c in _ZN11CrashDetect13DoAmxCallbackEiPiS0_ () from plugins/crashdetect.so
[21:14:11] [debug] #24 004a2d38 in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #25 004a91f8 in amx_Exec () from plugins/crashdetect.so
[21:14:11] [debug] #26 0049f218 in _ZN11CrashDetect9DoAmxExecEPii () from plugins/crashdetect.so
[21:14:11] [debug] #27 004a2aa9 in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #28 080dc202 in ?? () from ./samp03svr
[21:14:11] [debug] #29 08093d84 in ?? () from ./samp03svr
[21:14:11] [debug] #30 0049cb9c in _ZN11CrashDetect13DoAmxCallbackEiPiS0_ () from plugins/crashdetect.so
[21:14:11] [debug] #31 004a2d38 in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #32 004a91f8 in amx_Exec () from plugins/crashdetect.so
[21:14:11] [debug] #33 0049f218 in _ZN11CrashDetect9DoAmxExecEPii () from plugins/crashdetect.so
[21:14:11] [debug] #34 004a2aa9 in ?? () from plugins/crashdetect.so
[21:14:11] [debug] #35 080a36bb in ?? () from ./samp03svr
[21:14:11] [debug] #36 080a98bd in ?? () from ./samp03svr
[21:14:11] [debug] #37 080a8162 in ?? () from ./samp03svr
[21:14:11] [debug] #38 0028ad26 in __libc_start_main () from /lib/libc.so.6
[21:14:11] [debug] #39 0804b4a1 in ?? () from ./samp03svr
Reply
#6

Unfortunately the problem is the script. I'll give a simple example to explain it. This is wrong because it doesn't check the file handle:
pawn Код:
new File: fhandle = fopen("somefile.txt", io_append);
fwrite(fhandle, "I wrote here\n");
fclose(fhandle);
and this is correct because it does:
pawn Код:
new File: fhandle = fopen("somefile.txt", io_append);
if (fhandle) // if file handle is not 0, thus it is valid.. write to the file and close it. It won't crash the server if it's invalid
{
    fwrite(fhandle, "I wrote here\n");
    fclose(fhandle);
}
If you could compile with -d3 and test the script after using -d3 would be much easier (and faster) for me to help you fix it.

---

Now about 'Error: Function not registered', it's because you loaded nativechecker before IRC. nativechecker should be last.


And like I told you you need to update your plugins. Their versions are too old.
Reply
#7

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
Unfortunately the problem is the script. I'll give a simple example to explain it. This is wrong because it doesn't check the file handle:
pawn Код:
new File: fhandle = fopen("somefile.txt", io_append);
fwrite(fhandle, "I wrote here\n");
fclose(fhandle);
and this is correct because it does:
pawn Код:
new File: fhandle = fopen("somefile.txt", io_append);
if (fhandle) // if file handle is not 0, thus it is valid.. write to the file and close it. It won't crash the server if it's invalid
{
    fwrite(fhandle, "I wrote here\n");
    fclose(fhandle);
}
If you could compile with -d3 and test the script after using -d3 would be much easier (and faster) for me to help you fix it.

---

Now about 'Error: Function not registered', it's because you loaded nativechecker before IRC. nativechecker should be last.


And like I told you you need to update your plugins. Their versions are too old.
Well im done compiling it with -d3 here are the codes:

Код:
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase

Header size:          20716 bytes
Code size:          1421152 bytes
Data size:          7015280 bytes
Stack/heap size:      16384 bytes; estimated max. usage: unknown, due to recursion
Total requirements: 8473532 bytes
Now i uploaded the script at the FTP, and when i run i get no logs or shit, any idea what to do?
Reply
#8

Be sure that you have entered the log file name correctly also try restart server and go look at ftp logs again.
Reply me back
Reply
#9

Quote:
Originally Posted by 1FreeHost
Посмотреть сообщение
Be sure that you have entered the log file name correctly also try restart server and go look at ftp logs again.
Reply me back
ain't working
Reply
#10

Quote:
Originally Posted by AlbanianBadBoy
Посмотреть сообщение
and when i run i get no logs or shit, any idea what to do?
Sometimes it cannot open a file (thus invalid handle) and sometimes it can. Wait until it prints information with [debug] prefix and post your server log then.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)