Issue with Linux (Debian) server
#5

Quote:
Originally Posted by PawnHunter
Посмотреть сообщение
Show us the Log function, something is wrong with fwrite.
PHP код:
Log(typestring[], group = -1)
{
    new 
File:logfilelogstring[300];
    
format(logstringsizeof(logstring), "[%s] %s\r\n"GetDateFormat(gettime(), 2), string);
    switch(
type)
    {
        case 
0// Server
        
{
            
logfile fopen("Logs/Server.log"io_append);
            
fwrite(logfilelogstring);
            
fclose(logfile);
        }
         }

Like I said, this works on windows.

-------------------------

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
Quote:
Originally Posted by BornHuman
Посмотреть сообщение
Yes I have chmodded my entire SA:MP directory to 777, that is not the issue.
-------------------------

Quote:
Originally Posted by Vince
Посмотреть сообщение
But it is a terribly bad idea. Besides, if the file exists in the folder but the server does not have permission to write in it then it can still be the issue. Execute these commands in the main server directory:

Код:
whoami
Код:
ls -la
Код:
ls -la scriptfiles
Post results.
PHP код:
root@---:~/SAMP# whoami
root
root
@---:~/SAMP# ls -la
total 4376
drwxrwxrwx 6 root root    4096 Jun 29 14
:47 .
drwxrwxrwx 6 root root    4096 Jun 27 01:26 ..
-
rwxrwxrwx 1 root root   10936 Jan 24  2015 announce
drwxrwxrwx 2 root root    4096 Jun 24 02
:55 filterscripts
drwxrwxrwx 2 root root    4096 Jun 24 03
:12 gamemodes
-rwxrwxrwx 1 root root 2387912 Jun 19  2010 libmysqlclient.so.15
-rwxrwxrwx 1 root root    3777 Aug  9  2010 LICENSE
drwxrwxrwx 2 root root    4096 Jun 29 14
:40 plugins
-rwxrwxrwx 1 root root 1416792 Jul 14  2015 samp03svr
-rwxrwxrwx 1 root root  591652 Jul 11  2015 samp-npc
drwxrwxrwx 3 root root    4096 Jun 29 14
:20 scriptfiles
-rwxrwxrwx 1 root root     393 Jun 29 14:42 server.cfg
-rwxrwxrwx 1 root root     309 Jun 24 03:42 server.cfg.save
-rwxrwxrwx 1 root root   18987 Jun 29 14:59 server_log.txt
root
@---:~/SAMP# ls -la scriptfiles
total 12
drwxrwxrwx 3 root root 4096 Jun 29 14
:20 .
drwxrwxrwx 6 root root 4096 Jun 29 14:47 ..
drwxrwxrwx 2 root root 4096 Jun 29 14:20 Logs 
Reply


Messages In This Thread
Issue with Linux (Debian) server - by BornHuman - 29.06.2016, 18:58
Re: Issue with Linux (Debian) server - by iKarim - 29.06.2016, 19:09
Re: Issue with Linux (Debian) server - by Konstantinos - 29.06.2016, 19:17
Re: Issue with Linux (Debian) server - by Vince - 29.06.2016, 19:19
Re: Issue with Linux (Debian) server - by BornHuman - 29.06.2016, 19:21
Re: Issue with Linux (Debian) server - by Vince - 29.06.2016, 19:38
Re: Issue with Linux (Debian) server - by BornHuman - 29.06.2016, 19:41

Forum Jump:


Users browsing this thread: 1 Guest(s)