freecwmp
[Top] [All Lists]

openACS on Fedora 13

To: Luka Perkov <freecwmp@lukaperkov.net>
Subject: openACS on Fedora 13
From: w c <griscruf@gmail.com>
Date: Sun, 20 Jan 2013 19:13:04 -0500
Cc: freecwmp@linux-mips.org
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:date:message-id:subject:from:to:cc :content-type; bh=5nCDkqycR+F/0PTAkUEJH4EUUpXPlJOVkQ2iXhj+dzc=; b=I20inI5wgW0s/qj7UVzAcgZCos+2v56LJcNMDX86OJ4QNFh5hl1fcS9Q5aFpf4eEOP zEBf3VlwcSFCBDli4op6aGKMSKnnrFpbK65UrST2vuSo0NblodY1wClSO+QeJptXnDNx 2UGZqX9gSFumEMhXCor3yXBugMNoAUi+6Jr6/A34HKHppTBnetvNB+8i69W2u9bXONTC H0bPPrQYCRsxNF17m9paeLKgHa6pMmxuFtfK68fdNbgEZT1L82FCyDyBz9ROHUTb3oCi nzaBpZh1SS04t37RsiPmQlrVNgpz9cnex3HaJDgPjD92FqoBao+lW59W9UGnRU+X2WO/ nROg==
Original-recipient: rfc822;freecwmp@linux-mips.org
Sender: freecwmp-bounce@linux-mips.org
I am running Fedora 13 (not 18) because of some other dependencies.  I
got most the setup from:

http://sourceforge.net/p/openacs/wiki/Deploying/
http://sourceforge.net/p/openacs/wiki/Running/

So look at those for explaination, but here is what worked for me to
get it going:

-----------------jboss---------------
su
yum install java
java -version [says 1.6.0]

mvn --version [installs, says it fails]
mvn install [also fails, but seems ok]
mvn --version [says 2.0.8]
exit

wget 
http://sourceforge.net/projects/jboss/files/JBoss/JBoss-4.2.2.GA/jboss-4.2.2.GA.zip
unzip jboss-4.2.2.GA.zip
jboss-4.2.2.GA/bin/run.sh -b 0.0.0.0

cat jboss-4.2.2.GA/server/default/log/server.log

browse to http://localhost:8080

------------------------------mysql-----------------
su
yum install mysql mysql-server mysql-connector-java
/etc/init.d/mysqld start

mysql
CREATE DATABASE ACS;
quit

/usr/bin/mysqladmin -u root password 'password123'
/usr/bin/mysqladmin -u root -h localhost.localdomain password 'password123' -p
exit

cp /usr/share/java/mysql-connector-java-5.1.15.jar
jboss-4.2.2.GA/server/default/lib/

------------------------------openacs----------
wget 
http://sourceforge.net/projects/openacs/files/openacs-binary/openacs-bin-0.5.zip
unzip openacs-bin-0.5.zip

vi jboss-4.2.2.GA/server/default/deploy/openacs-ds.xml :
<?xml version="1.0" encoding="UTF-8"?>
<datasources>
<local-tx-datasource>
<jndi-name>ACS</jndi-name>
<connection-url>jdbc:mysql://localhost/ACS</connection-url>
<driver-class>com.mysql.jdbc.Driver</driver-class>
<user-name>root</user-name>
<password>password123</password>
<min-pool-size>5</min-pool-size>
<max-pool-size>20</max-pool-size>
<idle-timeout-minutes>5</idle-timeout-minutes>
</local-tx-datasource>
</datasources>

vi jboss-4.2.2.GA/server/default/deploy/jms/openacs-service.xml :
<?xml version="1.0" encoding="UTF-8"?>
<server>
<mbean code="org.jboss.mq.server.jmx.Queue"
name="jboss.mq.destination:service=Queue,name=acsQueue">
<depends 
optional-attribute-name="DestinationManager">jboss.mq:service=DestinationManager</depends>
</mbean>
</server>

cp openacs/acs.ear jboss-4.2.2.GA/server/default/deploy/openacs.ear

cp jboss-4.2.2.GA/server/default/lib/jboss-jaxrpc.jar
jboss-4.2.2.GA/lib/endorsed/
cp jboss-4.2.2.GA/server/default/lib/jboss-jaxws.jar
jboss-4.2.2.GA/lib/endorsed/
cp jboss-4.2.2.GA/server/default/lib/jboss-saaj.jar jboss-4.2.2.GA/lib/endorsed/

jboss-4.2.2.GA/bin/run.sh -b 0.0.0.0

http://localhost:8080/openacs

vi /etc/config/freecwmp :
config acs
        option scheme http
        option username freecwmp
        option password freecwmp
        option hostname 192.168.2.1
        option port 8080
        option path /openacs/acs

now if you start freecwmpd you should see your model under Hardware
models in openACS.  You can then create a Configuration script and
have it run as part of the Default Device profile.  A basic starting
script is:

var parameters = new Array ();
var j = 0;

parameters[0] = 'InternetGatewayDevice.DeviceInfo.Manufacturer';
j = 1;

try {
  var response = cpe.GetParameterValues(parameters);
  cpe.log('Get Parameter Values');
  for (i = 0; i < j; i++) {
    cpe.log(response[i].name + '=' + response[i].value);
  }
} catch (e) {
  logger("EXCEPTION!!!");
}

<Prev in Thread] Current Thread [Next in Thread>
  • openACS on Fedora 13, w c <=