This discussion is archived
14 Replies Latest reply: Jun 17, 2012 8:37 AM by 62600 RSS

Cannot configure the store under OpenSUSE 12.1

62600 Newbie
Currently Being Moderated
Hi. I cannot get past configuring the store under OpenSUSE 12.1; the same error appears with java 1.6.0_24 or java 1.7.0_5, adminboot_0.log or snaboot_0.log do not show any error messages, Oracle NoSQL is listening on ports 5000 and 5001, port 1099 does not appear under netstat, /etc/hosts contains 127.0.0.1 localhost, the firewall is on or off, it is a pristine OpenSUSE installation under VirtualBox, logged in as root in the shell, or logged in as root on the desktop. The same Oracle NoSQL Installation scripts work under CentOS, Solaris, Debian, Fedora. The address below (80.156.86.78) is a default address the Deutsche Telekom redirects routers for unknown IP addresses. Any ideas where I should look? Maybe is some program installed by default in OpenSUSE interfering with Oracle NoSQL? Thanks, Jesus.

java -jar ${KVHOME}/lib/kvstore-${VERSION}.jar runadmin -port 5000 -host localhost

Exception in thread "main" java.rmi.ConnectException: Connection refused to host: 80.156.86.78; nested exception is:
java.net.ConnectException: Connection timed out
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:619)
at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:216)
at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:202)
at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:128)
at java.rmi.server.RemoteObjectInvocationHandler.invokeRemoteMethod(RemoteObjectInvocationHandler.java:194)
at java.rmi.server.RemoteObjectInvocationHandler.invoke(RemoteObjectInvocationHandler.java:148)
at $Proxy0.getSerialVersion(Unknown Source)
at oracle.kv.impl.util.registry.RemoteAPI.<init>(RemoteAPI.java:32)
at oracle.kv.impl.admin.CommandServiceAPI.<init>(CommandServiceAPI.java:48)
at oracle.kv.impl.admin.CommandServiceAPI.wrap(CommandServiceAPI.java:55)
at oracle.kv.impl.util.registry.RegistryUtils.getAdmin(RegistryUtils.java:197)
at oracle.kv.impl.admin.client.KVAdmin.connect(KVAdmin.java:883)
at oracle.kv.impl.admin.client.KVAdmin.main(KVAdmin.java:2131)
at oracle.kv.impl.util.KVStoreMain$6.run(KVStoreMain.java:188)
at oracle.kv.impl.util.KVStoreMain.main(KVStoreMain.java:319)
Caused by: java.net.ConnectException: Connection timed out
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:391)
at java.net.Socket.connect(Socket.java:579)
at java.net.Socket.connect(Socket.java:528)
at java.net.Socket.<init>(Socket.java:425)
at java.net.Socket.<init>(Socket.java:208)
at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:40)
at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:146)
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:613)
... 14 more
  • 1. Re: Cannot configure the store under OpenSUSE 12.1
    guy.k.hillyer Newbie
    Currently Being Moderated
    What does ping localhost say?
  • 2. Re: Cannot configure the store under OpenSUSE 12.1
    62600 Newbie
    Currently Being Moderated
    Hi. Thanks for answering.
    PING localhost (127.0.0.1) 56(84) bytes of data.
    64 bytes from localhost (127.0.0.1): icmp_seq=1 ttl=64 time=0.053 ms
    ...
    So OK from that side. Internet connection works also.
  • 3. Re: Cannot configure the store under OpenSUSE 12.1
    guy.k.hillyer Newbie
    Currently Being Moderated
    I will download opensuse and try it out. Meanwhile, can you supply the commands you used to configure and start the store? Thanks.
  • 4. Re: Cannot configure the store under OpenSUSE 12.1
    62600 Newbie
    Currently Being Moderated
    Hi. Thanks. The commands are here:
    http://www.geilthings.com/wiki/Oracle_NoSQL#Installation_Oracle_NoSQL

    In short form, including checks (ps aux etc):

    VERSION=1.2.123
    KVROOT=/var/kvroot
    KVHOME=/opt/kv-${VERSION}
    if [ ! -d "${KVROOT}" ]
    then
    mkdir -p ${KVROOT}
    fi
    cd /opt
    # Download / Transfer the compressed file to /opt.
    tar -zxvf kv-ce-1.2.123.gz
    cd /opt/kv-${VERSION}
    java -jar ${KVHOME}/lib/kvstore-${VERSION}.jar makebootconfig -root ${KVROOT} -port 5000 -admin 5001 -host localhost -harange 5010,5020
    nohup java -jar ${KVHOME}/lib/kvstore-${VERSION}.jar start -root ${KVROOT}&
    ps aux | grep kv
    jps -m
    java -jar ${KVHOME}/lib/kvstore-${VERSION}.jar ping -port 5000 -host localhost
    java -jar ${KVHOME}/lib/kvstore-${VERSION}.jar runadmin -port 5000 -host localhost
    # kv->configure mystore
    # kv->set policy "cacheSize=16777216"
    # kv->plan -execute -name "Deploy YeysusOraNoSqlDC" deploy-datacenter "YeysusOraNoSqlDC"
    # kv->plan -execute -name "Deploy node localhost" deploy-sn 1 localhost 5000 "LocalhostStorageNode"
    # kv->plan -execute -name "Deploy admin" deploy-admin 1 5001
    # kv->addpool mySNPool
    # kv->joinpool mySNPool 1
    # kv->plan -execute -name "Deploy the store" deploy-store mySNPool 1 1
    # kv->show plans
    # kv->show topology
    # kv->quit
    java -jar ${KVHOME}/lib/kvstore-${VERSION}.jar ping -port 5000 -host localhost

    Just in case:
    # My /etc/resolv.conf:
    search Speedport_W_700V site
    nameserver 192.168.0.1
  • 5. Re: Cannot configure the store under OpenSUSE 12.1
    62600 Newbie
    Currently Being Moderated
    Just in case: My hostname is not in /etc/hosts; I don't even know where I can set it in OpenSUSE. However using the hostname instead of localhost to configure the store does not help either.
  • 6. Re: Cannot configure the store under OpenSUSE 12.1
    Charles Lamb Pro
    Currently Being Moderated
    Check your iptables/ipchains rules. Don't use localhost.

    Charles Lamb
  • 7. Re: Cannot configure the store under OpenSUSE 12.1
    guy.k.hillyer Newbie
    Currently Being Moderated
    I tried opensuse under virtualbox. I am not seeing the same problem you described.

    May I suggest you make an entry in /etc/hosts that matches the output of the hostname command, and use that name instead of "localhost" for configuring KVStore?
  • 8. Re: Cannot configure the store under OpenSUSE 12.1
    62600 Newbie
    Currently Being Moderated
    Hi. Thanks for your help. Now it is WORKING. Adding hostname to /etc/hosts and reboot was the point. The line looks like "127.0.0.1 localhost linux-urbi.site". I had added it already and had failed but I had not rebooted, only a new terminal session started. Well, it is like Windows: Every boot makes something good.
    I still use "localhost" in the initialization script.
    Best Regards,
    Jesus
  • 9. Re: Cannot configure the store under OpenSUSE 12.1
    62600 Newbie
    Currently Being Moderated
    Solution: Add hostname to /etc/hosts and reboot.
  • 10. Re: Cannot configure the store under OpenSUSE 12.1
    62600 Newbie
    Currently Being Moderated
    Just in case you are interested, I added this below to my script to check for a compliant /etc/hosts file before installation.

    MYHOSTNAME=$(hostname)
    if grep "127.0.0.1" /etc/hosts | grep $MYHOSTNAME | grep -q "localhost"
    then
    echo "Hostname and localhost point to 127.0.0.1 in /etc/hosts. OK."
    else
    echo "Either the Hostname $MYHOSTNAME or localhost do not point to 127.0.0.1 in /etc/hosts."
    echo "You need a line like 127.0.0.1 localhost $MYHOSTNAME in /etc/hosts for this script to work."
    fi
  • 11. Re: Cannot configure the store under OpenSUSE 12.1
    Charles Lamb Pro
    Currently Being Moderated
    Jesus,

    I am pretty sure you want the hostname to point to the non-loopback ipaddr. i.e. do not use a hostname referring to 127.0.0.1.

    Charles Lamb
  • 12. Re: Cannot configure the store under OpenSUSE 12.1
    62600 Newbie
    Currently Being Moderated
    Hi Charles. I know; but this is just a VirtualBox machine for testing purposes, no http server for example. It does not has a fixed IP address. How could I associate the hostname with itself in this case? Maybe using an internal IP address, which is also not fixed btw? Thanks, Jesus
  • 13. Re: Cannot configure the store under OpenSUSE 12.1
    Charles Lamb Pro
    Currently Being Moderated
    Hi Jesus,

    I'm not sure what having an http server has to do with anything. In any case, using the loopback address is going to cause you trouble. It sounds like you are getting a DHCP non-routable ipaddr. If you want to continue to use an existing NoSQL Database installation and the ipaddrs are changing, that will cause trouble. So I suggest that each time you bring up your Virtual Machine, you put an entry for the hostname in /etc/hosts with the non-routable DHCP address. Then use the name of the host in any NoSQL Database configuration. Obviously you would never deploy a real system with DHCP hosts.

    Charles Lamb
  • 14. Re: Cannot configure the store under OpenSUSE 12.1
    62600 Newbie
    Currently Being Moderated
    Hi Charles,
    OK I will create such a script and add it to init. However, I still wonder why Oracle NoSQL (or java rmi classes, I don't know which program actually does the call) translates the host name I give in the command "java -jar ${KVHOME}/lib/kvstore-${VERSION}.jar runadmin -port 5000 -host localhost" (localhost) to the real hostname and then it cannot translate the real host name back to localhost, without using /etc/hosts. The Back-translation gets lost in the process.
    Regards,
    Jesus

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points