You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: MUSESDevGuide.tex
+66-3Lines changed: 66 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -141,8 +141,8 @@ \subsection{Preparing the database}
141
141
The script for creating the MUSES server database is located at \texttt{MusesServer\\/db/startup\_db.sql}, and it should be loaded in the MySQL server at our machine. First, make sure you have MySQL server installed. If not, open a terminal and type \texttt{sudo apt-get install mysql-server-5.6}. During the installation, you will be asked to set a password for the root user. Few basic steps \cite{mysqlguide:site} should be followed to load the MUSES database:
142
142
143
143
\begin{description}
144
-
\item[\texttt{root \#/etc/init.d/mysql start}]
145
-
\item[\texttt{user \$mysql -u root -h localhost -p}] and then enter the chosen password.
144
+
\item[\texttt{\$ sudo /etc/init.d/mysql start}]
145
+
\item[\texttt{\$mysql -u root -h localhost -p}] and then enter the chosen password.
146
146
\item[\texttt{SOURCE /home/yourusername/foldertoMusesServer/db/startup\_db.sql;}] which loads the database structure from the script.
147
147
\item[\texttt{SOURCE /home/yourusername/foldertoMusesServer/db/startup\_db.sql;}] which populates the loaded database.
148
148
\item[\texttt{SHOW DATABASES;}] should list the databases, and also MUSES database.
@@ -151,7 +151,15 @@ \subsection{Preparing the database}
151
151
\item[\texttt{GRANT ALL ON muses.* TO 'muses'@'localhost';}] which gives permission to the MusesServer project to access the content in the MUSES database.
152
152
\end{description}
153
153
154
-
Finally, go to Eclipse again, right-click on the MusesServer project, and then go to \textit{Run As > Maven clean}, as it was shown in Figure \ref{fig:RunAs}. In the console, you will see a ``BUILD SUCESS'', and then, repeat going to \textit{Run As > Maven install}. Check that there were no errors, specially this type of error: \texttt{\textit{Error calling Driver\#connect}}, which means that the code cannot connect to the database. Now, you can implement functionalities and test them by doing \textit{Run As > Maven install} or \textit{Run As > Maven test}.
154
+
Finally, go to Eclipse again, right-click on the MusesServer project, and then go to \textit{Run As > Maven clean}, as it was shown in Figure \ref{fig:RunAs}. In the console, you will see a ``BUILD SUCESS'', and then, repeat going to \textit{Run As > Maven install}. Check that there were no errors, specially this type of error: \texttt{\textit{Error calling Driver\#connect}}, which means that the code cannot connect to the database. Now, you can implement functionalities and test them locally by doing \textit{Run As > Maven install} or \textit{Run As > Maven test}.
155
+
156
+
\section{Integrating Tomcat server}
157
+
\label{sec:eclipsetomcat}
158
+
159
+
Now that we can have a running client, by following the described steps on Section \ref{sec:buildclient}, and that we just builded the server part (see previous section), it is time for integrating Tomcat on Eclipse. After that, we will be able to test our development in a client-server mode, and locally. And this is an important point, because this step is for development purposes only. To install Apache Tomcat in a system, in order to work as a MUSES server, please refer to Section \ref{sec:tomcat}.
160
+
161
+
%Tutorial at \cite{eclipsetomcat:site}
162
+
155
163
156
164
\chapter{Creating and integrating new sensors}
157
165
\label{ch:sensors}
@@ -160,6 +168,61 @@ \chapter{Creating and integrating new sensors}
160
168
\chapter{Installing MUSES}
161
169
\label{ch:installmuses}
162
170
171
+
Table \ref{tab:server_infrastructure} shows the hardware requirements to run MUSES server applications, the following sections will explain how to install and configure these requirements.
Apache Tomcat powers numerous large-scale, mission-critical web applications across a diverse range of industries and organizations. But first of all, minimum Java Runtime Environment (JRE) 6 is required for Tomcat 7. For being able to install the last available version of JRE on the machine, open a terminal and follow this command:
199
+
200
+
\begin{verbatim}
201
+
$ sudo apt-get install openjdk-7-jre
202
+
\end{verbatim}
203
+
204
+
If you find problems with the dependencies, the command \texttt{\$ sudo apt-get -f install} fixes the possibly broken dependencies and finishes the installation. Also, you may need to update your system package list, for what you have to do the following:
205
+
206
+
\begin{description}
207
+
\item[\$ sudo apt-get update] to update the lists.
208
+
\item[\$ sudo apt-get upgrade] to install the new version of the packages, found by \textit{updating} the lists.
209
+
\end{description}
210
+
211
+
Find a correct Tomcat package to install by typing \texttt{\$ apt-cache search tomcat} and looking at the highlighted parts on Figure \ref{fig:tomcatpackages}. In this case, the needed version is version 7.
\caption{What your terminal should show after introducing the \texttt{\$ apt-cache search tomcat} command. The highlighted packages are the ones we have to focus in.}
218
+
\end{center}
219
+
\end{figure}
220
+
221
+
Then, to install all Tomcat packages, the following command are needed:
0 commit comments