'Unrecognized option 'stimeout'

Unrecognized option 'stimeout', is popping up when i'm using the command:

ffmpeg -re -rtsp_transport tcp -y -stimeout 1000000 -i "rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=0&unicast=true&proto=Onvif" -c copy -vsync 1 -f segment -segment_time 600 -segment_atclocktime 0 -segment_list_flags +live -reset_timestamps 1 -strftime 1 "C:\MINDA\OBITS\BlackBox\Recordings\Normal\Dahua-5M02C9FPAG1C78A\2022-1-4\%Y.%m.%d.%H.%M.%S.avi"


Solution 1:[1]

See if this works: change -stimeout to -timeout

Solution 2:[2]

The -stimeout option for rtsp has been renamed to -timeout in ffmpeg 5.0. This can be verified by comparing the rtsp section of the documentation to an older version:

Old: https://web.archive.org/web/20210328173215/https://ffmpeg.org/ffmpeg-protocols.html#rtsp

stimeout
    Set socket TCP I/O timeout in microseconds.

Current: https://ffmpeg.org/ffmpeg-protocols.html#rtsp

timeout
    Set socket TCP I/O timeout in microseconds.

The previous rtsp timeout option clashed with timeout options of other protocol implementations. All had the same name, but for other protocols timeout specifies a socket I/O timeout, while for rtsp timeout specified the maximum time to wait for incoming connection when ffmpeg is running in rtsp listen mode.

For better compatibility to other protocols, the timeout option of the rtsp implementation has been deprecated in 2018, and the new option listen_timeout has been introduced in its place. In 2021, the old option has then finally been removed, consequently also renaming the stimeout option to timeout.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Bo Yang
Solution 2 jkhsjdhjs