New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch crash on startup #189

Closed
mihailtudoran opened this Issue Oct 21, 2013 · 3 comments

Comments

Projects
None yet
2 participants
@mihailtudoran

mihailtudoran commented Oct 21, 2013

Using the latest version of LINC, on startup switch crash with the following errors:

Exec: /home/mihait/LINC-Switch/rel/linc/erts-5.9/bin/erlexec -boot /home/mihait/LINC-Switch/rel/linc/releases/1.0/linc -mode embedded -config /home/mihait/LINC-Switch/rel/linc/releases/1.0/sys.config -args_file /home/mihait/LINC-Switch/rel/linc/releases/1.0/vm.args -- console
Root: /home/mihait/LINC-Switch/rel/linc
Erlang R15B (erts-5.9) [source] [smp:4:4] [async-threads:0] [hipe] [kernel-poll:false]

10:30:21.587 [info] Application lager started on node 'linc@mihait-pc'
10:30:21.587 [error] Starting ssh application failed because: {error,{not_started,crypto}}
10:30:21.638 [error] Starting enetconf application failed because: {error,{not_started,crypto}}
10:30:21.690 [info] Application linc started on node 'linc@mihait-pc'
10:30:21.690 [info] Application xmerl started on node 'linc@mihait-pc'
10:30:21.690 [info] Application runtime_tools started on node 'linc@mihait-pc'
10:30:21.690 [info] Application crypto started on node 'linc@mihait-pc'
10:30:21.691 [info] Application public_key started on node 'linc@mihait-pc'
10:30:21.691 [info] Application ssl started on node 'linc@mihait-pc'
10:30:21.692 [info] Application sasl started on node 'linc@mihait-pc'
Eshell V5.9 (abort with ^G)
(linc@mihait-pc)1> 10:30:21.702 [info] Created port: {port,1,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap0"}]}
10:30:21.713 [info] Created port: {port,2,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap1"}]}
10:30:21.723 [info] Created port: {port,3,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap2"}]}
10:30:21.730 [info] Created port: {port,4,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap3"}]}
10:30:21.738 [info] Created port: {port,5,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap4"}]}
10:30:21.749 [info] Created port: {port,6,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap5"}]}
10:30:21.758 [info] Created port: {port,7,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap6"}]}
10:30:21.766 [info] Created port: {port,8,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap7"}]}
10:30:21.766 [error] gen_server <0.100.0> terminated with reason: no function clause matching linc_us4:stop([]) line 103
10:30:21.848 [info] Created port: {port,1,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap0"}]}
10:30:21.852 [error] CRASH REPORT Process <0.100.0> with 0 neighbours exited with reason: no function clause matching linc_us4:stop([]) line 103 in gen_server:terminate/6 line 715
10:30:21.871 [info] Created port: {port,2,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap1"}]}
10:30:21.925 [error] Supervisor linc_sup had child linc_logic started with linc_logic:start_link(0, linc_us4, [], [{switch,0,[{datapath_id,"00:19:E0:79:DB:9C:00:00"},{backend,linc_us4},{controllers,[{"Switch...",...}]},...]}]) at <0.100.0> exit with reason no function clause matching linc_us4:stop([]) line 103 in context child_terminated
10:30:21.933 [info] Created port: {port,3,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap2"}]}
10:30:21.979 [error] gen_server <0.158.0> terminated with reason: bad argument in call to ets:delete(1138993, 7) in linc_us4_port:terminate/2 line 513
10:30:21.988 [info] Created port: {port,4,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap3"}]}
10:30:22.031 [error] CRASH REPORT Process <0.158.0> with 0 neighbours exited with reason: bad argument in call to ets:delete(1138993, 7) in linc_us4_port:terminate/2 line 513 in gen_server:terminate/6 line 715
10:30:22.064 [info] Created port: {port,5,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap4"}]}
10:30:22.088 [error] gen_server <0.161.0> terminated with reason: bad argument in call to ets:delete(1138993, 8) in linc_us4_port:terminate/2 line 513
10:30:22.097 [info] Created port: {port,6,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap5"}]}
10:30:22.137 [error] gen_server <0.143.0> terminated with reason: bad argument in call to ets:delete(1138993, 2) in linc_us4_port:terminate/2 line 513
10:30:22.148 [info] Created port: {port,7,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap6"}]}
10:30:22.188 [error] CRASH REPORT Process <0.161.0> with 0 neighbours exited with reason: bad argument in call to ets:delete(1138993, 8) in linc_us4_port:terminate/2 line 513 in gen_server:terminate/6 line 715
10:30:22.222 [info] Created port: {port,8,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap7"}]}
10:30:22.247 [error] CRASH REPORT Process <0.143.0> with 0 neighbours exited with reason: bad argument in call to ets:delete(1138993, 2) in linc_us4_port:terminate/2 line 513 in gen_server:terminate/6 line 715
10:30:22.307 [info] Created port: {port,1,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap0"}]}
10:30:22.346 [error] gen_server <0.155.0> terminated with reason: bad argument in call to ets:delete(1138993, 6) in linc_us4_port:terminate/2 line 513
10:30:22.359 [info] Created port: {port,2,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap1"}]}
10:30:22.398 [error] CRASH REPORT Process <0.155.0> with 0 neighbours exited with reason: bad argument in call to ets:delete(1138993, 6) in linc_us4_port:terminate/2 line 513 in gen_server:terminate/6 line 715
10:30:22.430 [info] Created port: {port,3,[{queues_status,disabled},{queues,[]},{config,{port_configuration,undefined,up,false,false,false}},{features,{features,undefined,'100Mb-FD',true,copper,unsupported}},{queues,[]},{interface,"tap2"}]}

I am using the following configuration file:

[
{linc,
  [
   {of_config, enabled},
   {capable_switch_ports,
    [
{port, 1, [{interface, "tap0"}]},

{port, 2, [{interface, "tap1"}]},
{port, 3, [{interface, "tap2"}]},
{port, 4, [{interface, "tap3"}]},
{port, 5, [{interface, "tap4"}]},
{port, 6, [{interface, "tap5"}]},
{port, 7, [{interface, "tap6"}]},
{port, 8, [{interface, "tap7"}]}]},

{capable_switch_queues,
[
]},
{logical_switches,
[

 {switch, 0,
  [
   {backend, linc_us4},
   {controllers,
    [
      {"Switch0-DefaultController", "localhost", 6633, tcp}
    ]},

   {queues_status, disabled},

   {ports, [

{port, 1, {queues, []}},
{port, 2, {queues, []}},
{port, 3, {queues, []}},
{port, 4, {queues, []}},
{port, 5, {queues, []}},
{port, 6, {queues, []}},
{port, 7, {queues, []}},
{port, 8, {queues, []}}]}
]}
]}

%% TLS configuration. Put your switch certificate and private RSA key here.
%% Values should be base64 encoded, DER encoded strings.
%% , {certificate, ""},
%% {rsa_private_key, ""}
]},

{enetconf,
[
{capabilities, [{base, {1, 1}},
{startup, {1, 0}},
{'writable-running', {1, 0}}]},
{callback_module, linc_ofconfig},
{sshd_ip, any},
{sshd_port, 1830},
{sshd_user_passwords,
[
{"linc", "linc"}
]}
]},

{lager,
[
{handlers,
[
{lager_console_backend, info},
{lager_file_backend,
[
{"log/error.log", error, 10485760, "$D0", 5},
{"log/console.log", info, 10485760, "$D0", 5}
]}
]}
]},

{sasl,
[
{sasl_error_logger, {file, "log/sasl-error.log"}},
{errlog_type, error},
{error_logger_mf_dir, "log/sasl"}, % Log directory
{error_logger_mf_maxbytes, 10485760}, % 10 MB max file size
{error_logger_mf_maxfiles, 5} % 5 files max
]},

{sync,
%% Sync is a developer utility that reloads changed beam files into the VM
%% without the need to restart it. It is started when the Makefile's dev
%% target is invoked to start the development environment.
[
%% By default only the procket module is excluded from the scan process
%% as it does not support reloading.
{excluded_modules, [procket]}
]}

].

@ghost ghost assigned mentels Oct 21, 2013

@mentels

This comment has been minimized.

Show comment
Hide comment
@mentels

mentels Oct 21, 2013

Contributor

@mihailtudoran should be fixed now.

Contributor

mentels commented Oct 21, 2013

@mihailtudoran should be fixed now.

@mentels

This comment has been minimized.

Show comment
Hide comment
@mentels

mentels Oct 21, 2013

Contributor

@mihailtudoran please also note that sys.config has been updated.

We're upgrading to OFP 1.3.2 and there's new configuration option controllers_listener in the config file.

Contributor

mentels commented Oct 21, 2013

@mihailtudoran please also note that sys.config has been updated.

We're upgrading to OFP 1.3.2 and there's new configuration option controllers_listener in the config file.

@mihailtudoran

This comment has been minimized.

Show comment
Hide comment
@mihailtudoran

mihailtudoran Oct 21, 2013

Works now, thanks!

mihailtudoran commented Oct 21, 2013

Works now, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment