openwrt / openwrt/packages

watchcat: l2tp interface won't reboot in `mode:restart_iface`

Open
#27,927 15 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug release/24.10
Dominant language
Makefile
Stars
4.6k
Forks
4k
Avg merge
3d 12h
Merged PRs (30d)
134

Description

Package Name

watchcat

Maintainer

@roger-

OpenWrt Version

24.10.4

OpenWrt Target/Subtarget

mediatek/filogic

Steps to Reproduce
  1. Set up an L2TP interface via xl2tpd
  2. Set up watchcat to reboot this interface in case ping checks through it fail
  3. Expect the interface to auto-start once it's stopped manually

Here's the interface:

> ip a
...
l2tp-beeline: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1460 qdisc fq_codel state UNKNOWN group default qlen 3
    link/ppp 
    inet XXX.XXX.XXX.XXX peer XXX.XXX.XXX.XXX scope global l2tp-beeline
       valid_lft forever preferred_lft forever
...

/etc/config/watchcat:

config watchcat
	option mode 'restart_iface'
	option period '60s'
	option pinghosts 'l2tp.internet.beeline.kz'
	option addressfamily 'any'
	option pingperiod '20s'
	option pingsize 'standard'
	option interface 'l2tp-beeline'
Actual Behaviour

The l2tp-beeline interface won't start after reaching the configured period of unavailability (60s).

Logs:

Sun Nov 23 14:52:55 2025 daemon.info watchcat[17902]: Could not reach l2tp.internet.beeline.kz via "l2tp-beeline" for "20" seconds. Restarting "l2tp-beeline" after reaching "60" seconds
Sun Nov 23 14:53:15 2025 daemon.info watchcat[17902]: Could not reach l2tp.internet.beeline.kz via "l2tp-beeline" for "40" seconds. Restarting "l2tp-beeline" after reaching "60" seconds
Sun Nov 23 14:53:35 2025 daemon.info watchcat[17902]: Could not reach l2tp.internet.beeline.kz via "l2tp-beeline" for "60" seconds. Restarting "l2tp-beeline" after reaching "60" seconds
Sun Nov 23 14:53:35 2025 daemon.info watchcat[17902]: Restarting network interface: "l2tp-beeline".
Sun Nov 23 14:53:54 2025 daemon.info watchcat[17902]: Could not reach l2tp.internet.beeline.kz via "l2tp-beeline" for "20" seconds. Restarting "l2tp-beeline" after reaching "60" seconds

It seems if up/down doesn't work with L2TP interfaces:

watchcat_restart_network_iface() {
	logger -p daemon.info -t "watchcat[$$]" "Restarting network interface: \"$1\"."
	ip link set "$1" down
	ip link set "$1" up
}

Would it be applicable to use /sbin/ifup and /sbin/ifdown instead?

Confirmation Checklist

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the watchcat_restart_network_iface entry point and review how the configured l2tp-beeline interface is handled when the restart period is reached. Compare the current ip link operations with the mentioned /sbin/ifup and /sbin/ifdown behavior for L2TP, using the supplied watchcat configuration and logs to reproduce it. Done means the interface automatically starts again after becoming unavailable.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux, shell
Domain
networking
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.