Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Clean up log_url_info table and possible consequences
 
conticreative
Member
 
Total Posts:  38
Joined:  2007-12-13
 

I successfully moved a magento installation from a staging directory to a production directory.

The site works fine but I am still concerned about the content of the log_url_info table, which reflect the old directory path.

What is the best way to handle that data? How i9mportant is it and is it going to affect the way the cart works?
There sure are a lot of records in that table and almost every single one is wrong.

I am puzzled as to what function that table serves and the fact that apparently it gets bigger and bigger. Can someone let me know how to clean it and what its purpose is?

Thank you.

 
Magento Community Magento Community
Magento Community
Magento Community
 
conticreative
Member
 
Total Posts:  38
Joined:  2007-12-13
 

I am glad to see I am not the only one. Is that table just going to get bigger and bigger? What’s up with that?

 
Magento Community Magento Community
Magento Community
Magento Community
 
turbo1
Sr. Member
 
Avatar
Total Posts:  296
Joined:  2008-08-19
Los Angeles, CA
 

Yes, it is going to keep getting bigger and bigger. I first noticed this problem when my log table was over 300MB in size. The setting in magento to auto-clean it has never worked for me.

I regularly do this:

In PHPMyAdmin, “truncate” any tables that start with log_

Of course, back up your database first. But it’s never caused a problem for me. Hope this helps.

 
Magento Community Magento Community
Magento Community
Magento Community
 
conticreative
Member
 
Total Posts:  38
Joined:  2007-12-13
 

Well, thank you very much for the answer. That looks like pretty lousy design to me.

I find Magento to be very schizophrenic. Some features are so advanced (and long awaited) that makes you want to go down on your knees and cream “Alleluia”!
Others are just retarded. This is one of them. I profoundly dislike having to run any queries on a live site no matter how safe.

By the way, do you know what the purpose is for that table?

 
Magento Community Magento Community
Magento Community
Magento Community
 
skippybosco
Enthusiast
 
Avatar
Total Posts:  796
Joined:  2008-10-03
 

the log files are just that, logs of visitor activity on your site.

1) log_url: this is a table that tracks visitor(id)-> site url(id)->date/time
2) log_url_info: this is the table that maintains the unique ids for log_url, specifically it maintains id(autoincrimenting)-> site url(path) -> referrer url(path). You will get a lot of these, one for each unique combination of site and referrer url.
3) log_visitor: this is the table that tracks user specific activity id(autoincrimenting)->sessionid->first visit->last visit->lasturl(id)->store(id)
4) log_visitor_info: this is the table that tracks user specific attributes: id(autoincriment), referrer(url), useragent, charset, language, server ip, client ip

This provides a ton of historical analytic about your site and its visitors. Perhaps you are tracking this elsewhere such as google analytics, if so, I would recommend (instead of manually clearing the tables) just enabling the log cleaning option in administrator

http://mydomain.com/magento/index.php/admin/system_config/edit/section/system/ -> log cleaning

and setting the number of days to something your comfortable with (default is 180 days)

 
Magento Community Magento Community
Magento Community
Magento Community
 
conticreative
Member
 
Total Posts:  38
Joined:  2007-12-13
 

Thank you very much for the valuable information.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top