vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   General Articles (https://vborg.vbsupport.ru/forumdisplay.php?f=189)
-   -   How to setup a CDN for vbulletin (https://vborg.vbsupport.ru/showthread.php?t=257127)

final kaoss 01-13-2011 10:00 PM

How to setup a CDN for vbulletin
 
To edit your vBulletin style to enable CDN, follow these steps:

* Open admincp by visiting http://mywebsite.com/admincp/ > Select Styles & Templates > Replacement Variable Manager:
* Click on [Add New Replacement Variable] link and set it as follows:
o Set Search for Text to href="clientscript
o Set Replace with Text to href="http://cdn.mywebsite.com/clientscript

Code:

You need to repeat this step for images, javascript and other shared media as follows:
Search for Text         Replace with Text
src="customavatars/         src="http://cdn.mywebsite.com/customavatars/
src="customprofilepics/        src="http://cdn.mywebsite.com/customprofilepics/
src="images/         src="http://cdn.mywebsite.com/images/
url("clientscript         url("http://cdn.mywebsite.com/clientscript
src="clientscript/         src="http://cdn.mywebsite.com/clientscript/
href="clientscript/         href="http://cdn.mywebsite.com/clientscript/
url(./images/         url(http://cdn.mywebsite.com/images/
url(images/         url(http://cdn.mywebsite.com/images/
var imgdir_misc = "images/misc";        var IMGDIR_MISC =    "http://cdn.mywebsite.com/images/misc";

Avatars & Pictures - Storage Type

* Visit Avatars > Storage Type and set them as follows to match your above CDN rules by moving all of them to file systems:
o Avatars are currently being served from the filesystem at ./customavatars
o Profile pictures are currently being served from the filesystem at ./customprofilepics
o Signature pictures are currently being served from the filesystem at ./signaturepics

How Do I Test Images And Other Media Files Are Cached Or Not By CDN? Use curl to test HTTP headers (look for Etags, max-age and Expires headers):

Code:

$ curl -I 'http://cdn.mywebsite.com/clientscript/vbulletin_important.css?v=385'
$ curl -I http://cdn.mywebsite.com/customavatars/avatarx_y.gif

Credit for this nice & short tutorial goes to these guys.
http://wiki.netdna.com/Implementation/vBulletin

final kaoss 01-15-2011 04:18 PM

After you finish with this, I suggest you complete the steps in this article if you're looking to max out the speed of your vbulletin.
https://vborg.vbsupport.ru/showthread.php?t=237025

List of Paid CDN's:

Amazon CloudFront $0.150 per GB. A decent offering from Amazon. But supports origin pull ONLY from Amazon S3 which you have to pay extra.

High Winds CDN $0.075 per GB. One of the cheapest you can get. No POP (point of presence) in Asia Pacific, yet. VPS.NET is reselling this. Original price is $0.50

Cachefly $0.39 per GB ($99 plan prorated). Expensive because it is a monthly plan. Said to be of high performance. Decent POP list. 30day trial available. There is a high volume plan and price can go as low as $0.03.

Limelight Networks $0.22 per GB (PAYG). Similar to CloudFront. You need to keep the files with them. They have $0.01 for each request if your file sizes are smaller than 250kb! Rackspace is a reseller.

Internap $0.18 per GB (250GB plan). They have good coverage around the world. SoftLayer is reselling Internap accounts.

Voxel $0.20 per GB. They have good coverage around the world. Also offers pro-apache support through their extension.

MediaTemple This service is $20/Month. This includes 200GB bandwith/month. If you go over that limit, here is the pricing for that [$.15/GB up to 10TB] [$.10/GB over 10TB]. They claim to be "25% faster in delivering content when benchmarked against competitive CDNs".

sross 01-15-2011 07:12 PM

Is there a way to have all attachments stored at a cdn?

final kaoss 01-16-2011 12:02 AM

I'll have to look that up & post back.

Alfa1 01-16-2011 01:34 AM

Have you tried this yourself? The instructions are meant to work for their pull zones.

AFAIK this does not work for css files, avatars, attachments, custom profile pics, signaturepics nor any other user generated files. The issue is that vbulletin has only one location for files and cannot set a different location for writing the files to (your server) and reading the files from (the CDN).

OldSchoolDSL 01-17-2011 03:27 PM

I'll be the noob and ask....

cdn ?

final kaoss 01-17-2011 03:43 PM

Read up here then.
http://www.vbulletin.com/forum/showt...static-content
Or here
http://en.wikipedia.org/wiki/Content_delivery_network

LuisManson 01-19-2011 07:40 PM

i made a thread to do something like this, but i use a plugin to rewrite the URLs on the templates
maybe that can be usefull here too

final kaoss 01-19-2011 10:36 PM

A plugin for this would be helpful for alot of people, is it your own? If not, can you give us a link to it?

LuisManson 01-20-2011 05:10 PM

Quote:

Originally Posted by extreme-gaming (Post 2151721)
A plugin for this would be helpful for alot of people, is it your own? If not, can you give us a link to it?

hi, near middle of the article under "plugin" https://vborg.vbsupport.ru/showthread.php?t=246277

CvP 01-25-2011 03:42 PM

I wonder how a CDN based on geoip will do.
for example, using examplex.com for country x and exampley.com for country y.
ofc examplex and exampley are two different servers hosted on two different countries.
the main problem seems to be the synchronization between files/writing files.

cuocsongso 03-01-2011 12:47 AM

1 Attachment(s)
Quote:

Originally Posted by extreme-gaming (Post 2148977)
To edit your vBulletin style to enable CDN, follow these steps:

* Open admincp by visiting http://mywebsite.com/admincp/ > Select Styles & Templates > Replacement Variable Manager:
* Click on [Add New Replacement Variable] link and set it as follows:
o Set Search for Text to href="clientscript
o Set Replace with Text to href="http://cdn.mywebsite.com/clientscript

Code:

You need to repeat this step for images, javascript and other shared media as follows:
Search for Text         Replace with Text
src="clear.gif"         <src="http://cdn.mywebsite.com/clear.gif"/td>
src="customavatars/         src="http://cdn.mywebsite.com/customavatars/
src="customprofilepics/        src="http://cdn.mywebsite.com/customprofilepics/
src="images/         src="http://cdn.mywebsite.com/images/
url("clientscript         url("http://cdn.mywebsite.com/clientscript
src="clientscript/         src="http://cdn.mywebsite.com/clientscript/
href="clientscript/         href="http://cdn.mywebsite.com/clientscript/
url(./images/         url(http://cdn.mywebsite.com/images/
url(images/         url(http://cdn.mywebsite.com/images/
var imgdir_misc = "images/misc";        var IMGDIR_MISC =    "http://cdn.mywebsite.com/images/misc";

Avatars & Pictures - Storage Type

* Visit Avatars > Storage Type and set them as follows to match your above CDN rules by moving all of them to file systems:
o Avatars are currently being served from the filesystem at ./customavatars
o Profile pictures are currently being served from the filesystem at ./customprofilepics
o Signature pictures are currently being served from the filesystem at ./signaturepics

How Do I Test Images And Other Media Files Are Cached Or Not By CDN? Use curl to test HTTP headers (look for Etags, max-age and Expires headers):

Code:

$ curl -I 'http://cdn.mywebsite.com/clientscript/vbulletin_important.css?v=385'
$ curl -I http://cdn.mywebsite.com/customavatars/avatarx_y.gif

Credit for this nice & short tutorial goes to these guys.
http://wiki.netdna.com/Implementation/vBulletin

I met a problem after when I do it, please view attachment images

How to fix it? Thank you

A.Chakery 04-29-2011 03:39 PM

solved, thanks so much for the tip :)

8thos 07-25-2011 06:39 PM

Today I started using Cloudflare which comes with URLJET. Not sure if it's working yet.

final kaoss 07-28-2011 06:33 PM

Yes as long as you setup cloudflare properly it does fine.

Quote:

16,066 requests saved by CloudFlare
32,112 total requests

But be aware that it is not a recognized CDN according to pagespeed, yslow & gtmetrix.
http://wordpress.org/support/topic/h...wp-super-cache
Quote:

Originally Posted by Frederick Townes
It's important to understand that CloudFlare is *not* a CDN, nor is it their intension to be. Furthermore nothing replaces properly tuning your web site before adding other services as next or final steps.

He is the guy at http://www.w3-edge.com/ aka the company who made the popular w 3 total cache plugin for wordpress.

8thos 07-30-2011 02:24 AM

Google has a CDN now. Should I switch to them? http://googlecode.blogspot.com/2011/...rformance.html

final kaoss 07-30-2011 12:40 PM

As soon as they fix their sign up form, I'll be able to check it out.

Quote:

We're sorry.

You can't access this form because it is in violation of our Terms of service. If you feel this is in error, please contact us.

Find out more at the Google Docs Help Center.
Quote:

At this time, Page Speed Service is offered to a limited set of webmasters. You can request access to the service by filling this web form. (which is broken)

final kaoss 07-31-2011 01:46 PM

Now it's working!

Alfa1 08-01-2011 06:10 AM

Quote:

Originally Posted by Octavius. (Post 2226669)
Google has a CDN now. Should I switch to them? http://googlecode.blogspot.com/2011/...rformance.html

Its sure worth a try.

sivaganeshk 11-27-2011 05:00 PM

http://wiki.netdna.com/Implementation/vBulletin

The CDN plugin mention here is not available :(
any help. I have MaxCDN but don't have vbSEO

A.Chakery 11-27-2011 05:12 PM

Quote:

Originally Posted by sivaganeshk (Post 2272431)
http://wiki.netdna.com/Implementation/vBulletin

The CDN plugin mention here is not available :(
any help. I have MaxCDN but don't have vbSEO

there is no need for vbseo plugin, cause vbseo has released a stand alone plugin for vbulletin.

if you can't find it I can share it with you here .

Its free !!!

sivaganeshk 11-27-2011 05:21 PM

Please share.

--------------- Added [DATE]1322418145[/DATE] at [TIME]1322418145[/TIME] ---------------

https://vborg.vbsupport.ru/external/2011/11/9.jpg
:(

A.Chakery 11-27-2011 05:32 PM

well, so let me ask vbseo team about this issue ?

briansol 11-27-2011 08:24 PM

See: https://www.vbulletin.com/forum/show...MaxCDN-product

A.Chakery 11-28-2011 06:18 AM

Quote:

Originally Posted by briansol (Post 2272506)

Thank you Brian for the fast reply ...

vBSEO really rokcs ...:up:

Jackchan 08-05-2013 05:38 AM

I'm using VB 4.2 and the guide does not cover all expects. After replaced there still have many images and scripts not served from CDN.

Also, replace src="clear.gif" by <src="http://cdn.mywebsite.com/clear.gif"/td> will cause error here https://vborg.vbsupport.ru/showpost....8&postcount=12

A.Chakery 08-05-2013 06:11 AM

Quote:

Originally Posted by Jackchan (Post 2437199)
I'm using VB 4.2 and the guide does not cover all expects. After replaced there still have many images and scripts not served from CDN.

Also, replace src="clear.gif" by <src="http://cdn.mywebsite.com/clear.gif"/td> will cause error here https://vborg.vbsupport.ru/showpost....8&postcount=12

You should try to use Relevant Replacements to serve your static files,

oh and another option is to use the paid version of vboptimize which IMO really worth it.

it also has a Guest cache which decreases the page load time.

Here is the plugin :
http://www.dragonbyte-tech.com/product/1-vb-optimise

Plus it has a great support.

Jackchan 08-05-2013 06:30 AM

Quote:

Originally Posted by A.Chakery (Post 2437204)
You should try to use Relevant Replacements to serve your static files,

oh and another option is to use the paid version of vboptimize which IMO really worth it.

it also has a Guest cache which decreases the page load time.

Here is the plugin :
http://www.dragonbyte-tech.com/product/1-vb-optimise

Plus it has a great support.

I did check out vboptimize but I found no demo/site using this plugin so I don't how great the performance is.

The dragonbyte-tech.com forum itself does not use this plugin I guess as the forum is loading really slow.

Most paid SEO plugin out there are just simple configs which I can do by myself and I afraid this plugin may in the same categories.

A.Chakery 08-05-2013 06:38 AM

I have it on my own forum, but unfortunately I had to disable the Guests full cache since I am using highly customized plugins which should not be cached, on a simple (regular) vbulletin installation you will not have any problems with this feature ...

Here is my forum :

Pet Owners and Veterinarian Cmommunity

Jackchan 08-05-2013 06:45 AM

Quote:

Originally Posted by A.Chakery (Post 2437207)
I have it on my own forum, but unfortunately I had to disable the Guests full cache since I am using highly customized plugins which should not be cached, on a simple (regular) vbulletin installation you will not have any problems with this feature ...

Here is my forum :

Pet Owners and Veterinarian Cmommunity

You have a good forum. :)

I check it out now. Thank you.

A.Chakery 08-05-2013 07:06 AM

You are welcome :)

But please note that I used relevant replacements to serve my static files from CDN ...

Good luck

nikosb 06-19-2014 09:23 AM

Quote:

Originally Posted by cuocsongso (Post 2168058)
I met a problem after when I do it, please view attachment images

How to fix it? Thank you

https://vborg.vbsupport.ru/attachmen...1&d=1298947603

i have the same problem

A.Chakery 06-19-2014 10:28 AM

Would you please provide us with your relevant replacements ?

nikosb 06-19-2014 10:34 AM

Code:

src="clear.gif"        <src="http://cdn.mywebsite.com/clear.gif"/td>
src="customavatars/        src="http://cdn.mywebsite.com/customavatars/
src="customprofilepics/        src="http://cdn.mywebsite.com/customprofilepics/
src="images/        src="http://cdn.mywebsite.com/images/
url("clientscript        url("http://cdn.mywebsite.com/clientscript
src="clientscript/        src="http://cdn.mywebsite.com/clientscript/
href="clientscript/        href="http://cdn.mywebsite.com/clientscript/
url(./images/        url(http://cdn.mywebsite.com/images/
url(images/        url(http://cdn.mywebsite.com/images/
var imgdir_misc = "images/misc";        var IMGDIR_MISC =    "http://cdn.mywebsite.com/images/misc";

The problem was the
Code:

src="clear.gif"        <src="http://cdn.mywebsite.com/clear.gif"/td>
and remove this.


All times are GMT. The time now is 01:39 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03321 seconds
  • Memory Usage 1,830KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (6)bbcode_code_printable
  • (13)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (34)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete