Skip to content
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

No available resources in PDP context creation #197

Closed
Twig96 opened this issue Jul 23, 2020 · 0 comments
Closed

No available resources in PDP context creation #197

Twig96 opened this issue Jul 23, 2020 · 0 comments

Comments

@Twig96
Copy link

Twig96 commented Jul 23, 2020

Hi @RoadRunnr , I changed the configuration file (from #196 ) as you suggested so that the ip_pools parameter is now fine but a new error showed up in the response for the 'Create PDP Context request' is code 209 (User Authentication failed) because default values using sgsnemu where {mig, hemmelig}. I changed those to match the one accepted by ergw in {ergw, ergw} and again the same error showed up (199, No resource available).

If it can help this is the output error from the erlang shell:

=ERROR REPORT==== 23-Jul-2020::10:32:50.294199 ===
unable to find context {irx,
{{gtp_port,irx,
<<3,101,112,99>>,
'gtp-c',<0.1123.0>,5,
{172,20,20,1}},
{172,20,20,150},
2123,create_pdp_context_request,
{v1,30721}}}

I attach the modified configuration file:

%--Erlang--

[

%% setup application

{setup,
[{data_dir, "/var/lib/ergw"},
{log_dir, "/var/log/ergw-c-node"}
]},

%%kernel application

{kernel,
[{logger,
[{handler, default, logger_std_h,
#{level => all,
config =>
#{sync_mode_qlen => 10000,
drop_mode_qlen => 10000,
flush_qlen => 10000}
}
}
]}
]},

%% ergw application

{ergw,
[
{'$setup_vars',
[{"ORIGIN", {value, "epc.mnc001.mcc001.3gppnetwork.org"}}
]},

%% GTP sockets

 {sockets,
  [{'cp-socket',
    [{type, 'gtp-u'},
     {vrf, cp},
     {ip, {172,20,21,1}},
     {netdev, "sxb-cp"},
     %{netns, "cp"},
     {reuseaddr, true}
    ]},
   {irx, [{type, 'gtp-c'},
	  {vrf, epc},
	  {ip, {172,20,20,1}},
	  {netdev, "grx-cp"},
	  %{netns, "epc"},
	  {reuseaddr, true}
     ]}
  ]},

%% IP pools

 {ip_pools,
	[{'pool-A', [{ranges, [{{10,80,0,1}, {10,80,255,254}, 32}]},
		{'MS-Primary-DNS-Server', {8,8,8,8}},
		{'MS-Secondary-DNS-Server', {8,8,4,4}},
		{'MS-Primary-NBNS-Server', {127,0,0,1}},
		{'MS-Secondary-NBNS-Server', {127,0,0,1}}
	]},
	{'pool-B', [{ranges, [{{10,81,0,1}, {10,81,255,254}, 32}]},
		{'MS-Primary-DNS-Server', {8,8,8,8}},
		{'MS-Secondary-DNS-Server', {8,8,4,4}},
		{'MS-Primary-NBNS-Server', {127,0,0,1}},
		{'MS-Secondary-NBNS-Server', {127,0,0,1}}
	]},
	{'pool-C', [{ranges, [{{10,82,0,1}, {10,82,255,254}, 32}]},
		{'MS-Primary-DNS-Server', {8,8,8,8}},
		{'MS-Secondary-DNS-Server', {8,8,4,4}},
		{'MS-Primary-NBNS-Server', {127,0,0,1}},
		{'MS-Secondary-NBNS-Server', {127,0,0,1}}
	]}
]},

%% Socket for Sx interface

 {sx_socket,
  [{node, 'ergw'},
   {name, 'ergw'},
   {socket, 'cp-socket'},
   {ip, {172,20,21,1}},
   {netdev, "sxb-cp"},
   {reuseaddr, true}
  ]},

% Interface handlers

 {handlers,
  [{'h1', [{handler, pgw_s5s8},
	   {protocol, gn},
	   {sockets, [irx]},
	   {node_selection, [default]},
	   {aaa, [{'Username',
			[{default, ['IMSI', <<"/">>,
				    'IMEI', <<"/">>,
				    'MSISDN', <<"/">>,
				    'ATOM', <<"/">>,
				    'TEXT', <<"/">>,
				    12345,
				    <<"@">>, 'APN']}]}]}
	  ]},
   {'h2', [{handler, pgw_s5s8},
	   {protocol, s5s8},
	   {sockets, [irx]},
	   {node_selection, [default]},
	   {aaa, [{'Username',
			[{default, ['IMSI', <<"/">>,
				    'IMEI', <<"/">>,
				    'MSISDN', <<"/">>,
				    'ATOM', <<"/">>,
				    'TEXT', <<"/">>,
				    12345,
				    <<"@">>, 'APN']}]}]}
	  ]}
  ]},

%% Network APNs

 {apns,
  [{[<<"tpip">>, <<"net">>], 
	[{vrf, sgi},
	{ip_pools, ['pool-A']},
	{prefered_bearer_type, 'IPv4'}
	]},
   {[<<"APN1">>], 
	[{vrf, sgi},
	{ip_pools, ['pool-A']},
	{prefered_bearer_type, 'IPv4'}
	]}
  ]},

 {node_selection,
  [{default,
    {static,
     [
      %% APN NAPTR alternative
      {"_default.apn.$ORIGIN", {300,64536},
	[{"x-3gpp-pgw", "x-s5-gtp"}, {"x-3gpp-pgw", "x-s8-gtp"}, {"x-3gpp-pgw", "x-gn"}, {"x-3gpp-pgw", "x-gp"}],
	"topon.s5s8.pgw.$ORIGIN"},

      {"_default.apn.$ORIGIN", {300,64536},
       [{"x-3gpp-upf","x-sxb"}],
       "topon.sx.prox01.$ORIGIN"},

      {"web.apn.$ORIGIN", {300,64536},
       [{"x-3gpp-upf","x-sxb"}],
       "topon.sx.prox01.$ORIGIN"},

      %% A/AAAA record alternatives
      {"topon.s5s8.pgw.$ORIGIN", [{172,20,20,150}], []},

      {"topon.sx.prox01.$ORIGIN", [{172,20,21,2}], []}
     ]
    }
   }
  ]
 },

 {nodes,
  [{default,
    [{vrfs,
      [{cp, [{features, ['CP-Function']}]},
       {epc, [{features, ['Access']}]},
       {sgi, [{features, ['SGi-LAN']}]}
     ]},
     {ip_pools, ['pool-A']}
  ]}%%,
  %%{"topon.sx.prox01.$ORIGIN", [connect]}
]}
]},

%% {exometer_core, [{reporters, [{exometer_report_netdata, []}]}]},

%% ergw_aaa application

{ergw_aaa,
[{transports, []},
{handlers,
[{ergw_aaa_static,
[{'NAS-Identifier', <<"NAS-Identifier">>},
{'Node-Id', <<"PGW-001">>},
{'Charging-Rule-Base-Name', <<"m2m0001">>}
]}
]},

{services,
[{'Default', [{handler, 'ergw_aaa_static'}]}]},

{apps,
[{default,
[{session, ['Default']},
{procedures, [{authenticate, []},
{authorize, []},
{start, []},
{interim, []},
{stop, []}
]}
]}
]}
]}
].

@Twig96 Twig96 changed the title User authentication fails No available resources in PDP context creation Jul 23, 2020
@Twig96 Twig96 closed this as completed Jul 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant