jfchevrette
08-18-2007, 08:32 AM
Suppose I have an application with two servers that are sharing content volume. How do I put my content on this volume if it's read-only on the servers?
Thanks!
PeterNic
08-18-2007, 08:30 PM
Two approaches (plus a bonus one):
1. By accessing the volume through the grid controller
Let's say that app name is 'jfapp', the volume is 'content', your grid is 'jfgrid.com'. Use the following steps:
- make sure the jfapp is stopped
- mount the content volume on the grid controller:
vol mount jfapp:content
- you will see the path on which it was mounted, something like /vol/jfapp/content
- now, from your workstation, you can scp or sftp to the grid:
scp -R /home/jf/files root@jfgrid.com:/vol/jfapp/content
See details in http://doc.3tera.net/AppLogic2/GridAccess.html
This is the simplest way, works best when you already have the desired files (i.e., you are not developing them actively).
2. By modifying the appliance.
- Put the second web server on standby (so it won't start automatically); branch the first web server, so it will become editable; edit the first web server's class to make the content volume read/write and not shared.
- rename the class to, say, WEBRW; move it to the 'user' catalog (so you can use it later again without having to branch/edit)
- log into the web server, write your files
- you can now test with a single web server, adjust the files until everything works fine.
- when done, replace the class of the WEBRW web server with the regular WEB class (shift-drag the WEB appliance from the catalog onto the WEBRW instance on the canvas -- this changes the class of the instance while preserving properties, connections and other settings).
- clear the standby attribute of the second web server
- restart the app
3. And now, for bonus points, a third way
Don't use a R/O content volume and put the content files in a NAS box connected to fs terminal (assuming you have one or don't mind having one). Change the 'content_on_fs' property of the WEB servers to 1 (TRUE). You can look at the LampX4 application template (see docs at http://doc.3tera.net/AppLogic2/RefAppLamp.html) on how this works. You can also move the doc_dir/scripts_dir to a subdirectory, so that the web content will be in a subtree of the NAS volume (rather than in the root).
Regards,
-- Peter
vBulletin® v3.7.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.