Alfresco Virtualization Server Not Responding – Unable to Preview Site
By Adrian Sutton
If you’ve tried to set up Alfresco 3.2 and use the WCM component, you’ve probably run into one or more1{#footlink1:1260264856408.footnote} of these problems:
-
When you click “Preview Website” you get an unable to connect message.
- You need to start the virtualization server that provides the previews or configure it’s IP correctly.
-
When you click “Preview Website” you get a blank page and the browser is “connecting” forever.
- You did the right thing and entered a root password other than ‘admin’ in the installer and now you’re being punished for it. Go and update the virtualization server configuration and give it the admin password you entered.
-
When you click “Preview Website” you get a response immediately that just reports “Virtual website not found”.
- You started the virtualization server too soon after starting Alfresco. Restart it.
-
When you try to deploy the server it fails to connect.
- You need to download and install the deployment server.
-
You’re trying to follow the getting started example, but when you get to creating content from the Press Release Form, it just gives you an error: Cannot resolve the name ‘pr:company_footer_choices’.
- You need to get the virtualization server working. Also make sure you have done the bulk import step and can preview the site.
Starting the Virtualization Server
There should be a ‘virtual_alf.sh’2{#footlink2:1260265148233.footnote} script in the Alfresco install directory. Run ‘./virtual_alf.sh start’ There’s also a virtual_start.sh but you’ll probably need to edit it to replace the @@ALF_DIRECTORY@@ placeholder that the installer didn’t replace.
Setting the Admin Password
At the end of the file ‘virtual-tomcat/conf/alfresco-virtserver.properties’ within your Alfresco install directory, there’s a property ‘alfresco.server.password’ this needs to be set to the admin password for your Alfresco instance. Keep this in sync anytime you change the admin password or your site previews will stop working.
Also note that the user/password you add here will be used for all previews so it bypasses any security you might have. Don’t deploy this on a publicly available site unless you have nothing to hide.
Installing the Deployment Server
No, it doesn’t seem to come with Alfresco by default – the documentation suggests there’s a way to enable it but I haven’t found it. Much easier to just download the component separately (from the main download page, go to “Custom Installs”, look under the WCM section and pick the obviously named package that works best for your platform. Install it by unzip/untarring in a directory and run it with the deploy_start.sh script.
There is configuration in the ‘deployment.properties’ file which most importantly controls where it deploys to. You probably want to deploy to a Tomcat server’s webapps directory or similar. The default config will however work for testing and put the deployed content into the ‘target’ directory.
Why Isn’t This in the Install Guide?
I have no idea. It would seem like something you would want to know about while installing.
1 – probably all of them actually↩