3 - Configure jbilling: edit the file
conf/jbilling.properties
More...
4 - Startup Tomcat by executing: startup.sh from the 'bin' directory
(use startup.bat for windows)
5 - You can now login to the example company 'Trend'. Point your browser to http://localhost:8080/billing and login with the user 'admin', password '123qwe', company id 1.
6 - Create the first company: Point your browser to http://localhost:8080/billing/signupEntity.do?action=setup
To shutdown: Do not do CTRL-C or turn off your computer. Run 'bin/shutdown.sh' (use shutdown.bat in Windows).
7 - Follow the Getting Started guide to get your billing system fully configured and operational
Additional information:
1 - Install Java
You do not need NetBeans, J2EE or the JDK, just the JRE. From jbilling 1.0.7 you need Java 1.6. If you can not use Java 1.6, download jbilling 1.0.6.
3 - Locate Your Java Folder
Next, on most computers you will need to add a Java environment variable
that points to the folder where Java is installed on your computer. To do
this, we will need to locate this folder!
Navigate to the folder containing your program files (\program files on a
Windows computer). There should be a Java subfolder. Inside the Java folder,
there will be several more subfolders as well, including jre6. Thus, a
typical Windows installation will have Java located in c:\program
files\java\jre6.
If your computer already had Java installed and you have just installed a
new version, it is possible that two versions are now registered. This can
cause problems when you attempt to run jBilling. To resolve this, you can
use the Java Control Panel utility. It is called javacpl.exe and is located
in java\jre6\bin. Run this program. Click on the "Java" tab, then select the
"View" button to show all versions of Java installed on your computer. It
should show Java platform 1.6 installed, with the checkbox selected to show
it is enabled. If other earlier versions of Java are shown and you are
having difficulties running jBilling, try de-selecting the checkbox to
disable the older Java version(s).
4 - Configuring Java
jBilling requires that an environment variable called JRE_HOME is setup on
your computer. This tells jBilling the location of your Java install.
Check whether the JRE_HOME variable is configured on your computer. The
tutorial video shows you how to do this, as well as how to create the new
variable on a Windows computer. Note that the steps to setup an environment
variable will vary depending on the version of the Operating System you are
using. Note that on most systems, you will need administrator security
rights to make this change.
Use the following to configure the environment variable on different
operating systems: Windows XP , Unix
and others ,
Mac
When you are complete, you should have the JRE_HOME system variable defined
with the path to the jre6 directory on your computer.
Note: JAVA_HOME should NOT be defined on your computer. If it is, jBilling
may fail to run. You may need to remove this environment variable in order
for jBilling to run successfully.
Running jBillingTo start jBilling, navigate to the jbilling\bin folder and
locate the file called startup.bat or startup.sh If your computer is running
a version of Microsoft Windows, double-click onstartup.bat. If you are
running a version of Unix (Linux or an Apple computer) run startup.sh.
You will see a scrolling list as services start and the application
initializes. It might take a little while to start, depending upon the speed
of your computer. In a couple of minutes, the scrolling list will pause for
a short time and you will see the message "INFO: Server startup in ##### ms"
(note that the # signs will actually be the number of milliseconds that the
program took to start on your computer). It is useful to note how long the
application took to start on your computer. If, in the future, it takes
significantly less time to start, it may be a sign that one or more services
did not initialize properly. It is a good idea to check the error logs if
this is the case. This will only happen if you made an error while changing
some configuration settings in jBilling.
Once you see the message noted above, you are ready to launch your web
browser and log in to jBilling. However, do not close the scrolling Tomcat
window! If you do so, you will incorrectly shut down the jBilling services.
You will not be able to log in, and you may even have problems when you next
try to start them. Simply minimize the Tomcat window until you are ready to
shut down jBilling. It will continue to scroll messages as you use the
application, and as scheduled events happen.
Troubleshooting ProblemsIt is not possible to provide a solution to every
problem you may encounter when trying to run jBilling for the first time.
However, in the vast majority of cases, jBilling is not running because one
of the steps listed in the checkbox (provided above) is not complete.
If you do not see the server startup message described above, there is
likely a problem. You can try to launch your web browser and log in anyway
-- perhaps you simply didn't notice the startup message but everything is
fine! But if you cannot view the login screen, there is likely a problem.
But don't worry, because jBilling provides you with lots of information on
any problems it encounters.
First, check the jBilling logs. They are located in jbilling\logs and can be
opened with any text editor.
Exit jBillingWhen you are finished using jBilling, you can log out and close
your web browser. However, the Tomcat window should still be open.
To stop the jBilling services, navigate to the jbilling\bin folder and run
one of the following:
shutdown.bat - use this if you are running a version of Microsoft Windows
shutdown.sh - use this if you are running a version of Unix (such as Linux
or a Mac)
A scrolling list of services that are being closed or shut down will appear
on your screen. When complete, all Tomcat windows will be automatically
closed for you. Remember to always use this method to shut down jBilling
when you are finished using it!! Of course, in a production environment,
these jBilling services will only be stopped in this way if you need to do
system maintenance.
5 - Configure JBilling
The file jbilling.properties
has many properties that will affect how the system runs. Most
default values will be acceptable for the average user. Make sure to
change internal_key to
some long random string, base_dir
to reflect the directory where you unzipped JBilling and the email
server properties so JBilling can send emails.
You can change these properties at any time in the future. You
will need to restart JBilling for the changes to take place. All the
properties are described in this
document
JBilling can generate your
invoices in PDF format. The default design includes a logo on the
top-left corner of the invoice. If you want your logo to be
displayed, copy a JPG version of it to the directory resources/logos.
jBilling Installation FAQ
(Contributed by cocoy)
Here you can find answer to some of the most frequently ask questions about installing and running jbilling. If you have a question not answered by this page, you can use the jBilling Forums.
Contents
Installing jBilling
1.0 Something is not working ... what should I do?
Start by taking a loog to the server logs. These are in the file jbilling\server\default\log\server.log. Another important log file is the jbilling log file: jbilling\server\default\log\jbilling.log. If after reading these you still don't know what to do, copy the last part of these files and post a question in the forums.
1.1 Which version of Java to use?
JRE 1.4.1 and above.
1.2. Do I really need a JDK(Java Developers Kit)?
No. You can just use JRE to run jBilling. Unless you want to build from source.
1.3. Where to extract jBilling?
On windows, avoid problems with spaces in your path. Try making the installation in c:\jbilling
Running and Stopping jBilling
2.1 How to start jBilling in Windows?
Change directory to your jbilling and execute bin/run.bat
2.2 How to start jBilling in Unix/Linux?
Change directory to your jbilling and exectue bin/run.sh
Make sure your file bin/run.sh has execute permission. By default it is not executable, so run 'chmod +x run.sh' from the bin directory.
2.3 I have jBilling running, now what's next?
Point your browser to http://localhost/billing/signupEntity.do?action=setup
Follow the Getting Started guide: Getting Started
2.4. How to stop jBilling in Linux/Unix?
From another terminal, cd to your jbilling directory and execute bin/shutdown.sh -S.
Note that '-S' has an upper case 'S'. Make sure file /bin/shutdown.sh has execute permission. By default it is not executable, so run 'chmod +x shutdown.sh' from the bin directory.
Common problems in Running jBilling
3.1 I have an Error initializing endpoint error, what does it mean?
jbilling are using several tcp ports during startup. If any of these
ports were used by another program, this error is displayed.
Use netstat command to check port status on your machines. On windows, use 'netstat -a -v -b'. You have to find out what is the application that you are running that is using a TCP port number that jbilling needs and shutdown that application.
3.2 I got an error Port already in use?
One of jbilling tcp ports is already used by another program.
You can use netstat command to check port status on your machines (see previous question).
Common problems in running jBilling on Linux/Unix
4.1 Why do I get permission denied or either command not found when
running bin/run.sh ?
Your bin/run.sh is not an executable file. Change the permission
of your bin/run.sh to executable using chmod command.
4.2 I have run.sh: Missing file: /lib/tools.jar?
You can ignore this warning if you only have JRE installed. If you have JDK installed,
set JAVA_HOME to point to your jdk installation directory using 'export' command.