• Forum
  • Doc
  • Screenshots
  • Download
  • Donate
  • Contributors
  • Contact
  • Follow @phpfreechat
  • DEMO
  • Board index ‹ Version 1.x branch ‹ General Support (v1.x)
  • Change font size
  • FAQ
  • Register
  • Login

File vs MySQL advantages and disadvantages

Moderators: OldWolf, re*s.t.a.r.s.*2

Post a reply
9 posts • Page 1 of 1

Postby martian1949 » Tue Mar 15, 2011 12:47 pm

I would like to know if there is any significant advantage in using MySQL instead of Files.
For the time being I have only a disadvantage. In fact, while it works fine with container_type=file, if I set container_type=mysql I cannot see any users in the chat page, not even myself.
Is it possible that this is due to the fact that I already have a database connection open associated with variable $db?
Thanks in advance.
Bruno
martian1949
New member
 
Posts: 4
Joined: Tue Mar 15, 2011 12:39 pm
Location: Rome, Italy
  • Website
Top

Postby re*s.t.a.r.s.*2 » Tue Mar 15, 2011 2:23 pm

put the code here, between the "code" tags...

so we can see whats up..
Free Singles Chat Rooms No Registration Required
Text and Chat Singles no need to register or app required
Sala De Bate Papo Online Grátis E Sem Cadastro
re*s.t.a.r.s.*2
Support Team
 
Posts: 612
Joined: Wed Sep 24, 2008 4:04 pm
Location: los angeles CA
  • Website
Top

Postby martian1949 » Tue Mar 15, 2011 4:05 pm

Thanks, here is the code:
Code: Select all
$params['firstisadmin'] = true;
$params["isadmin"] = false;
$params["debug"] = false;
$channels=Array("Public Room");
$params["channels"] = $channels;
$params["time_offset"] = 5*60*60;
$params["date_format"] = 'Y-m-d';
$params["display_ping"] = false;
$params["container_type"] = "mysql";
$params["container_cfg_mysql_host"]     = "localhost";        // default value is "localhost"
$params["container_cfg_mysql_port"]     = 3306;               // default value is 3306
$params["container_cfg_mysql_database"] = "udred_tutorsdata";      // default value is "phpfreechat"
$params["container_cfg_mysql_table"]    = "n01_tab_phpfreechat";             // default value is "phpfreechat"
$params["container_cfg_mysql_username"] = "root";      // default value is "root"
$params["container_cfg_mysql_password"] = ""; // default value is ""
$params["serverid"] = md5(CHAT_SERVER_ID); // calculate a unique id for this chat
$chat = new phpFreeChat( $params );
martian1949
New member
 
Posts: 4
Joined: Tue Mar 15, 2011 12:39 pm
Location: Rome, Italy
  • Website
Top

Postby re*s.t.a.r.s.*2 » Tue Mar 15, 2011 8:07 pm

Looks fine to me..

if you use file container without editing anything do you get the chat to work?

do you have any out put in the apache error logs?

does your mysql has the correct permission for that particular user?

try using a different database and or create a new database username and try again...
Free Singles Chat Rooms No Registration Required
Text and Chat Singles no need to register or app required
Sala De Bate Papo Online Grátis E Sem Cadastro
re*s.t.a.r.s.*2
Support Team
 
Posts: 612
Joined: Wed Sep 24, 2008 4:04 pm
Location: los angeles CA
  • Website
Top

Postby kriko » Wed Mar 16, 2011 3:09 pm

I was using mysql and with about 6 users I got constant heavy I/O load from mysqld service.
Seems to me that DB engine in this case is too huge overhead for what pfc needs.
kriko
Member
 
Posts: 30
Joined: Sun May 31, 2009 8:07 pm
Top

Postby martian1949 » Fri Mar 18, 2011 5:15 pm

Dear support team,
before I try to do what you suggested I would like to understand if there is any advantage in using MySQL instead of files. If none, I would not invest time in finding out the reason of the problem I mentioned.
So, could you please tell me when using MySQL would be convenient?
Thanks
Bruno
martian1949
New member
 
Posts: 4
Joined: Tue Mar 15, 2011 12:39 pm
Location: Rome, Italy
  • Website
Top

Postby re*s.t.a.r.s.*2 » Fri Mar 18, 2011 5:45 pm

I am sorry,

The only way to know if there is a performance increase its testing...
I for one have used the mysql container and file container but never had enough users chatting to really test any performance increase...

So you are on your own on this one..

if you get to check performance let us know..
Free Singles Chat Rooms No Registration Required
Text and Chat Singles no need to register or app required
Sala De Bate Papo Online Grátis E Sem Cadastro
re*s.t.a.r.s.*2
Support Team
 
Posts: 612
Joined: Wed Sep 24, 2008 4:04 pm
Location: los angeles CA
  • Website
Top

Postby martian1949 » Fri Mar 18, 2011 5:52 pm

Ok, I will come back to you when I will have a significant chat traffic on my site.
Thanks
Bruno
martian1949
New member
 
Posts: 4
Joined: Tue Mar 15, 2011 12:39 pm
Location: Rome, Italy
  • Website
Top

Postby kriko » Fri Mar 18, 2011 6:04 pm

As I said, with not that many users I got too much I/O activity, which didn't happen with file container.
You might try to setup mysql with raw device if that helps in that case.
Last edited by kriko on Fri Mar 18, 2011 6:05 pm, edited 1 time in total.
kriko
Member
 
Posts: 30
Joined: Sun May 31, 2009 8:07 pm
Top


Post a reply
9 posts • Page 1 of 1

Return to General Support (v1.x)

Who is online

Users browsing this forum: No registered users and 15 guests

  • Board index
  • The team • Delete all board cookies • All times are UTC + 1 hour
Powered by phpBB® Forum Software © phpBB Group
cron
Sign in
Wrong credentials
Sign up I forgot my password
.
jeu-gratuit.net | more partners
Fork me on GitHub