6to4 Tunnel seems to be broken.
-
Did get errors:
php: : The command '/sbin/ifconfig wan_stf inet6 2002:4658:b479:: prefixlen 16' returned exit code '1', the output was 'ifconfig: interface wan_stf does not exist'
and then of course:
php: : The command '/sbin/route change -inet6 default '2002:c058:6301::'' returned exit code '1', the output was 'route: writing to routing socket: No such process route: writing to routing socket: Network is unreachable change net default: gateway 2002:c058:6301::: Network is unreachable'
-
64bit pfSense also failed to create wan_stf. Here are the errors:
php: : The command '/sbin/ifconfig wan_stf inet6 2002:4658:b479:: prefixlen 16' returned exit code '1', the output was 'ifconfig: interface wan_stf does not exist'
and
php: : The command '/sbin/route change -inet6 default '2002:c058:6301::'' returned exit code '1', the output was 'route: writing to routing socket: No such process route: writing to routing socket: Network is unreachable change net default: gateway 2002:c058:6301::: Network is unreachable'
There was an error on boot about renaming the interface, but it went by quickly and I cannot capture it.
update:
okay it says that rename expect 1 parameter to be a string. -
Have you ever tried to execute that manually in Diagnostis->Command Prompt->PHP Execute?
$tmpstfiface = pfSense_interface_create("stf");
var_dump($tmpstfiface); -
nope .. but i did a scroll lock on the error and got this.
pfSense_interface_rename() expects parameter 1 to be string, array given in /etc/inc/interfaces.inc on line 3313.That line reads: pfSense_interface_rename($tmpstfiface, $stfiface);
Parameter 1 I think is $tmpstfiface and is getting set by $tmpstfiface = pfSense_interface_create("stf");
if not then it is the $stfiface set by $stfiface = "{$interface}_stf";But which ever one it is, its creating an array and not a string.
Update:
With parameters set to "wan" and "wan_stf", I no longer get the errors booting up, but it looks like stf is never created or renaming fails as I keep getting:The command '/sbin/ifconfig wan_stf inet6 2002:4658:b479:: prefixlen 16' returned exit code '1', the output was 'ifconfig: interface wan_stf does not exist'
-
The $tmpstfiface variable is an array due to the fact that the "pfSense_interface_create" function returns an array (with the key "error" and value "Could not create interface") when an error occurs.
Try without using the "pfSense_interface_create" function by executing "ifconfig stf create" and see what happens.
-
It is actually returning the string "Array" … I put in a log_error command to return the value of $tmpstfiface.
-
Directly printing an array returns the string "Array".
-
Okay .. how can I convert that from array to string to print the error? no other error is being shown.
-
Use either "$output = var_export($var, true);" or "$output = print_r($var, true);" before feeding the $output variable to the log_error function. But I would be more interested in what happens when you execute "ifconfig stf create" on the command line, as the array contents will very likely only be "array( 'error' => "Could not create interface", )".
-
It creates sft0 when I issue that command.
-
okay, got it to show what it is putting in there. It is putting in a '1'.
When I hard code it to pfSense_interface_rename("stf0", $stfiface); everything works!!!
So, I am not sure why the pfSense_interface_create("stf"); is returning a 1 since it is created, but unsure why it is erroring out. -
I can also confirm that if you do:
ifconfig stf create
ifconfig stf0 name wan_stf
from the console, that the existing code works like a charm. It does not survive reboot though unless you do this yourself. -
I found out why :)
Pushed a fix for this. The module for stf interface is not loaded that is why ifconfig works while pfSense calls do not!Upgrade/gitsync to latest code since there have been fixes for all your issues.
-
That is awesome!!! … Thanks Ermal it is working like a charm now.