zkfan / tungsten-replicator

Automatically exported from code.google.com/p/tungsten-replicator
0 stars 0 forks source link

Tungsten-installer :: Ruby issues :: NilClass (NoMethodError) #142

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

launch the tungsten-installer:
./tools/tungsten-installer \
  -- verbose \
     --master-slave \
     --master-host=sqltest1 \
     --datasource-user=tungsten \
     --datasource-password=tungstenpwd \
     --service-name=dragon \
     --home-directory=/home/tungsten/planet \
     --cluster-hosts=sqltest1,sqltest2,sqltest3 \
     --start-and-report

What is the expected output?

Creation of the tungstens folder in the /home/tungsten/planet directory

What do you see instead?

./ruby/lib/ifconfig/linux/interface_types.rb:64:in `add_network': undefined 
method `[]' for nil:NilClass (NoMethodError)
    from ./ruby/lib/ifconfig/linux/interface_types.rb:39:in `parse_ifconfig'
    from ./ruby/lib/ifconfig/linux/interface_types.rb:36:in `each'
    from ./ruby/lib/ifconfig/linux/interface_types.rb:36:in `parse_ifconfig'
    from ./ruby/lib/ifconfig/common/interface_types.rb:18:in `initialize'
    from ./ruby/lib/ifconfig/common/interface_types.rb:118:in `initialize'
    from ./ruby/lib/ifconfig/linux/ifconfig.rb:32:in `new'
    from ./ruby/lib/ifconfig/linux/ifconfig.rb:32:in `initialize'
    from ./ruby/lib/ifconfig/linux/ifconfig.rb:28:in `each'
    from ./ruby/lib/ifconfig/linux/ifconfig.rb:28:in `initialize'
    from ./ruby/lib/ifconfig.rb:49:in `new'
    from ./ruby/lib/ifconfig.rb:49:in `initialize'
    from ./ruby/configurator.rb:644:in `new'
    from ./ruby/configurator.rb:644:in `is_localhost?'
    from ./ruby/configure/deployments/regular_configure_deployment.rb:28:in `get_deployment_configurations'
    from ./ruby/configure/deployments/regular_configure_deployment.rb:17:in `each'
    from ./ruby/configure/deployments/regular_configure_deployment.rb:17:in `get_deployment_configurations'
    from ./ruby/configure/configure_deployment.rb:94:in `prevalidate'
    from ./ruby/configurator.rb:213:in `run'
    from ruby/configure.rb:51

Which version :

- Ubuntu version: 10.04 LTS
- java version: 1.6.0_26
- Mysql version: 5.5.12-rel20.3-118 from Percona
- Ruby version: 1.8
- Tungsten version: 2.0.4-145

Original issue reported on code.google.com by tuto...@gmail.com on 30 Jun 2011 at 4:43

GoogleCodeExporter commented 9 years ago

Original comment by g.maxia on 30 Jun 2011 at 5:13

GoogleCodeExporter commented 9 years ago
Could you post the ifconfig output for this server?  It appears that there is 
an unexpected format being returned.

Original comment by jeffm...@gmail.com on 3 Jul 2011 at 9:08

GoogleCodeExporter commented 9 years ago
ifconfig -a
eth0      Link encap:Ethernet  HWaddr 14:fe:b5:c8:65:6c  
          inet adr:10.0.2.19  Bcast:10.0.255.255  Masque:255.255.0.0
          adr inet6: fe80::16fe:b5ff:fec8:656c/64 Scope:Lien
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          Packets reçus:53850688 erreurs:0 :0 overruns:0 frame:0
          TX packets:54265001 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 lg file transmission:1000 
          Octets reçus:44564704138 (44.5 GB) Octets transmis:62127435594 (62.1 GB)
          Interruption:36 Mémoire:f2000000-f2012800 

eth1      Link encap:Ethernet  HWaddr 14:fe:b5:c8:65:6e  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          Packets reçus:0 erreurs:0 :0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 lg file transmission:1000 
          Octets reçus:0 (0.0 B) Octets transmis:0 (0.0 B)
          Interruption:48 Mémoire:f4000000-f4012800 

eth2      Link encap:Ethernet  HWaddr 14:fe:b5:c8:65:70  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          Packets reçus:0 erreurs:0 :0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 lg file transmission:1000 
          Octets reçus:0 (0.0 B) Octets transmis:0 (0.0 B)
          Interruption:37 Mémoire:f6000000-f6012800 

eth3      Link encap:Ethernet  HWaddr 14:fe:b5:c8:65:72  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          Packets reçus:0 erreurs:0 :0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 lg file transmission:1000 
          Octets reçus:0 (0.0 B) Octets transmis:0 (0.0 B)
          Interruption:49 Mémoire:f8000000-f8012800 

lo        Link encap:Boucle locale  
          inet adr:127.0.0.1  Masque:255.0.0.0
          adr inet6: ::1/128 Scope:Hôte
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          Packets reçus:964 erreurs:0 :0 overruns:0 frame:0
          TX packets:964 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 lg file transmission:0 
          Octets reçus:128329 (128.3 KB) Octets transmis:128329 (128.3 KB)

Original comment by tuto...@gmail.com on 5 Jul 2011 at 11:51

GoogleCodeExporter commented 9 years ago
Thank you for posting that.  It appears that your version of ifconfig is 
printing out information in a format other than the one we use for testing.  
Notice the different abbreviations below.  Do you know of anything special with 
your ifconfig utility? Could you post the full version info like I have in this 
message?

eth1      Link encap:Ethernet  HWaddr 08:00:27:27:d1:42  
          inet addr:192.168.198.101  Bcast:192.168.198.255  Mask:255.255.255.0
          inet6 addr: fe80::a00:27ff:fe27:d142/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:82 errors:0 dropped:0 overruns:0 frame:0
          TX packets:49 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:9919 (9.9 KB)  TX bytes:7593 (7.5 KB)

Linux mdb1 2.6.32-21-generic #32-Ubuntu SMP Fri Apr 16 08:10:02 UTC 2010 i686 
GNU/Linux
Ubuntu 10.04.2 LTS

Original comment by jeffm...@gmail.com on 6 Jul 2011 at 12:55

GoogleCodeExporter commented 9 years ago
root@sql19:/data# ifconfig
eth0      Link encap:Ethernet  HWaddr 14:fe:b5:c8:65:6c  
          inet adr:10.0.2.19  Bcast:10.0.255.255  Masque:255.255.0.0
          adr inet6: fe80::16fe:b5ff:fec8:656c/64 Scope:Lien
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          Packets reçus:56260841 erreurs:0 :0 overruns:0 frame:0
          TX packets:58950364 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 lg file transmission:1000 
          Octets reçus:44735283130 (44.7 GB) Octets transmis:69210550113 (69.2 GB)
          Interruption:36 Mémoire:f2000000-f2012800 

lo        Link encap:Boucle locale  
          inet adr:127.0.0.1  Masque:255.0.0.0
          adr inet6: ::1/128 Scope:Hôte
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          Packets reçus:964 erreurs:0 :0 overruns:0 frame:0
          TX packets:964 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 lg file transmission:0 
          Octets reçus:128329 (128.3 KB) Octets transmis:128329 (128.3 KB)

root@sql19:/data# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 10.04.2 LTS
Release:    10.04
Codename:   lucid

root@sql19:/data# uname -a
Linux sql19 2.6.32-21-server #32-Ubuntu SMP Fri Apr 16 09:17:34 UTC 2010 x86_64 
GNU/Linux

It's a french version of ubuntu but it's the only thing "special"

Original comment by tuto...@gmail.com on 6 Jul 2011 at 1:31

GoogleCodeExporter commented 9 years ago
That is the issue.  I was able to reproduce the ifconfig output by installing 
the french language packs and modifying my LANG environment variable.

    7  apt-get install language-support-fr
    8  apt-get install language-pack-fr
    ......
   15  export LANG=fr_FR.UTF-8
   16  ifconfig -a

This will be fixed by modifying the LANG environment variable to en_US when 
running shell commands.

Original comment by jeffm...@gmail.com on 6 Jul 2011 at 2:18

GoogleCodeExporter commented 9 years ago
This has been fixed and will be included in the nightly build.

Original comment by jeffm...@gmail.com on 6 Jul 2011 at 2:49

GoogleCodeExporter commented 9 years ago
Thank you so much !

Original comment by tuto...@gmail.com on 6 Jul 2011 at 4:18