Virtual resources in Puppet might seem complicated and confusing but, in fact, they're very simple. They're exactly like regular resources, but they don't actually take effect until they're realized (in the sense of "made real"); a regular resource, on the other hand, can only be declared once per node (so two classes can't declare the same resource, for example). A virtual resource can be realized as many times as you like.
This comes in handy when you need to move applications and services between machines. If two applications that use the same resource end up sharing a machine, they will cause a conflict unless you make the resource virtual.
To clarify this, let's look at a typical situation where virtual resources might come in handy.
You are responsible for two popular web applications: WordPress and Drupal....