Sounds like you didn’t use the full path to binaries in your script…
→ On the local console, your user / root benefits from having the correct environment set, including paths. Scripts run eg by cron, do NOT have any environment set, therefore full paths are needed!
Example:
A simple shutdown script wih poweroff won’t work
The same script with /usr/sbin/poweroff will work!
→ Always use full paths in your scripts, then they will work anywhere, in all environments…
(Permissions are a different issue!)
I’m (maybe wrongly) assuming your server does not have fail2ban or IPS modules installed, which could block connections.
At the moment your connection from the other computer is dropped/rejected, the last lines of /var/log/firewall.log might show you a hint of the cause. A more verbose version can be obtained with shorewall dump, as it will dump a large list with the firewall configuration being applied. shorewall show can display useful info too.
I’m confused because I don’t know when it’s a command argument or conversation, but to be more practical, my .sh contains “shorewall clear”, but it’s complicated
I’m taking another route, running through crontab, but I think I’m making a mistake, if you can help
As I said, I set up the script.sh with shorewall clear, it works if I run it directly, after running it I can see the log, and I see the Nethserver with firewall notified
I inserted the script.sh in contrab -e: @reboot /root/script.sh
It didn’t work, I thought it would run as soon as I restarted, I tried with * * * * * but it didn’t work either, the friend said he needed the entire path, but I don’t know how to do it and how to create the correct parameter
(FAQ 17) Why are these packets being Dropped/Rejected? How do I decode Shorewall log messages?
(…) INPUT or FORWARD
The packet has a source IP address that isn’t in any of your defined zones (“shorewall[-lite] show zones” and look at the printed zone definitions) (…)
some of the photos (with incomplete information) show rules for a wireless interface but no mention of ens2.