Entity and session beans are not run from the command line, rather they
are run inside of an EJB container. I suggest that you take a look at
http://www.jboss.org/ for a good, free, open source EJB server. You can
package your entity and session beans in a JAR, create the deployment
descriptor (which defines security and transaction parameters) and drop
your JAR into a running JBoss's deploy directory and you are off and
running.