OPNsense Forum

Archive => 15.7 Legacy Series => Topic started by: romain on July 08, 2015, 04:40:23 pm

Title: [SOLVED] Backup/Restore always reboots after a restore with shellcmd
Post by: romain on July 08, 2015, 04:40:23 pm
Hello,

I'm trying to manage the options loaded on my oce interface. I didn't find a way to do it correcty. So I used shellcmd. I downloaded a backup of my configuration, added the shellcmd line and reboot.

But since, I always have the message if I go to the backup/restore page (and the firewall automatically reboots) :

The firewall configuration has been changed. The firewall is now rebooting.

What can I do to avoid this strange behaviour ?
Title: Re: [BUG] - Backup/Restore always reboots after a restore with shellcmd
Post by: romain on July 08, 2015, 04:54:30 pm
I removed the shellcmd instructions

I removed the file /var/run/restore.dirty

I backup again my firewall and the config file seems to be okay and valid.

I'm not sure if it's the good solution.
Title: Re: [BUG] - Backup/Restore always reboots after a restore with shellcmd
Post by: franco on July 08, 2015, 04:59:42 pm
We can't provide support for custom shell scripts that we don't see. It also prevents us from putting in real fixes for use cases we haven't covered yet. If you can, please provide more info when posting bugs.
Title: Re: [BUG] - Backup/Restore always reboots after a restore with shellcmd
Post by: romain on July 08, 2015, 08:08:29 pm
I tried to use the shellmd to manage the options loads on my interface on boot

Code: [Select]
<shellcmd>ifconfig oce0 -tso -tso4 -tso6 -lro -hwvlanfilter</shellcmd>

But it does not work and I was stuck with this message on the backup /restore page
Title: Re: [BUG] - Backup/Restore always reboots after a restore with shellcmd
Post by: franco on July 08, 2015, 10:39:25 pm
Ah! <shellcmd/> was removed prior to our first 15.1 release. We do not like arbitrary code execution and the config trouble you see is probably natural as we only accept a well-formed and known XML.

The system always reboots after a restore for safety reasons.

"System: Settings: Networking" can disable oce(4) TSO and LRO for you.

The code tries to enable "vlanhwfilter" (not "hwvlanfilter") by default. Not sure this causes a problem?


Cheers,
Franco
Title: Re: [SOLVED] Backup/Restore always reboots after a restore with shellcmd
Post by: romain on July 09, 2015, 07:48:55 am
I'm still not sure what's my trouble. But I have an Intel card which works fine and the OCE that have bad cksum all the time. So I'm trying to have the same option on my oce network ports :

Code: [Select]
root@KISS0525002:~ # ifconfig igb0
igb0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=400b8<VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,VLAN_HWTSO>
        ether 0c:c4:7a:32:63:f4
        inet 80.80.236.214 netmask 0xfffffff0 broadcast 80.80.236.223
        inet6 fe80::ec4:7aff:fe32:63f4%igb0 prefixlen 64 scopeid 0x3
        nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
        media: Ethernet autoselect (1000baseT <full-duplex>)
        status: active
root@KISS0525002:~ # ifconfig oce0
oce0: flags=8043<UP,BROADCAST,RUNNING,MULTICAST> metric 0 mtu 1500
        options=507bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4,TSO6,LRO,VLAN_HWFILTER,VLAN_HWTSO>
        ether 00:90:fa:9d:29:d8
        nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
        media: Ethernet autoselect (10Gbase-SR <full-duplex>)
        status: active

But nothing works. I already checked :

Disable hardware large receive offload
Disable hardware TCP segmentation offload
Disable hardware checksum offload

and rebooted the firewall.  The options are still there and I have bad cksum.

Howu can I be sure that the TSO and LRO are tuned off ?
Thanks