Hey ppl, it is time for one of my super helpful mini tutorials 🙂
Its been a while since last post. I had lot of work and things on my mind. Today I decided to write mini tutorial about installing axis2, as I setup it again on my virtual machine.
Before we start, I’d like to tell you why I’m installing everythin again! 😦 It is because my old virtual machine was broken few days ago.
I had WinXP on it, and I was doing some IDEF0 and DFD diagrams. I needed ERWIN for some ER diagrams and I tried to install it. It started and took some time, and then VBox started going crazy! It shutdown WinXP virtual machine and threw me an error about it. If I just had a clue not to edit Virtual Box.xml file, I’d be very happy man right now. Anyway, I had removed some lines, or something like that and all my virtual machines and their snapshots were inaccessible. I have lost few hours trying to make it work again, but with no success. So, I’m giving you advice, FIRST READ THEN EDIT CONFIG FILES 🙂
Ok, now we will start with installing axis2.
First, you have to install java6, tomcat6 packages with next command:
sudo apt-get install sun-java6-jdk tomcat6-admin tomcat6-docs tomcat6-examples
Now, you can try accessing localhost:8080/ in your browser. If you try to get on admin pages, to deploy some servlet, you’ll get prompt for username and password. Because tomcat6 default install hasn’t those parameters in config file, you’ll have to edit /var/lib/tomcat6/conf/tomcat-users.xml. In it you’ll have to add next lines:
<user username=”admin” password=”password” roles=”admin,manager”/>
between tomcat-users tags. Change “password” with your own.
After this, you’ll have to restart tomcat6 with:
sudo /etc/init.d/tomcat6 restart
Then, you have to access manage-webapp link on localhost:8080/ and enter your username and password from tomcat-users.xml file.
Inside, you can do lot of things, but we will do war deploy :D. Since we are installing axis2, you must download WAR archive from this link: http://ws.apache.org/axis2/download/1_5_1/download.cgi
Then you choose path to axis2.war file, and deploy it. To access it, visit localhost:8080/axis2/. I’m pretty sure you’ll get error. It took me som time to figure out what is blocking it. The problem is in tomcat6 script in /etc/init.d directory. You have to switch tomcat security flag from yes to no. Then restart tomcat6, and you’ll have axis2 working.
That is all. Feel free to comment and ask, and I’ll feel equally free to answer them 🙂 BYE!