From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_PASS, URIBL_BLOCKED,USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C998CC282C4 for ; Mon, 4 Feb 2019 08:55:04 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9C94E21871 for ; Mon, 4 Feb 2019 08:55:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1549270504; bh=YOe1QlSX8ySDPhstwZa9mAa6ILUgeHEHcGDTIcBXbbw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:List-ID:From; b=zUVObDv5LcdK5sgUEhtimePFrznEFV9Z+uJTQed0dpk3HRC2AE8Z/18eSTytos8xa 9Wa29fmx0QqRPV+3hgqQeI1ofvcHS3ysEAbLSHhlXSnBJNxFGEj/CaJEOYDlikV8rX hT15o+YxfB+FrvxMZtxIViLe+hUVuOfnRsNHm6Q8= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728571AbfBDIzE (ORCPT ); Mon, 4 Feb 2019 03:55:04 -0500 Received: from mail.kernel.org ([198.145.29.99]:55118 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728496AbfBDIzD (ORCPT ); Mon, 4 Feb 2019 03:55:03 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 19A1421871; Mon, 4 Feb 2019 08:55:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1549270502; bh=YOe1QlSX8ySDPhstwZa9mAa6ILUgeHEHcGDTIcBXbbw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=RklqtYtMjWa4fD636YWVB5okZYFRv+nurtU0+D4M2K8sq9RvTBJiX/M3Mci7MPsac XKkinY79w8ADxXylXKaeVcg30Rrf/y+BgFafUIsvhCy1BDKrlpdOexihm7DxblF1LJ vm5rRfgKFsZRagYuAiz9G1N8n9BoihyCE5++PxX8= Date: Mon, 4 Feb 2019 09:54:40 +0100 From: Greg KH To: Steve French Cc: Pavel Shilovsky , Stable Subject: Re: [PATCH] cifs: Always resolve hostname before reconnecting Message-ID: <20190204085440.GB2015@kroah.com> References: <1548893250-48583-1-git-send-email-pshilov@microsoft.com> <20190202113317.GE31341@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.11.3 (2019-02-01) Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org On Sat, Feb 02, 2019 at 02:30:41PM -0600, Steve French wrote: > On Sat, Feb 2, 2019 at 12:17 PM Pavel Shilovsky wrote: > > > > сб, 2 февр. 2019 г. в 10:13, Pavel Shilovsky : > > > > > > сб, 2 февр. 2019 г. в 03:33, Greg KH : > > > > > > > > On Wed, Jan 30, 2019 at 04:07:30PM -0800, Pavel Shilovsky wrote: > > > > > Commit 28eb24ff75c5 ("cifs: Always resolve hostname before reconnecting"). > > > > > > > > > > In case a hostname resolves to a different IP address (e.g. long > > > > > running mounts), make sure to resolve it every time prior to calling > > > > > generic_ip_connect() in reconnect. > > > > > > > > > > This patch needs user space changes of cifs.upcall that set a timeout > > > > > value for the "dns_resolver" key. > > > > > > > > Wait, you are requiring userspace to upgrade tools to support this? And > > > > you think that will happen to all systems running older kernels? > > > > > > > > This really feels like a new feature being added, what bug is this > > > > fixing that requires it to be backported to all of the stable kernel > > > > trees? > > > > > > Let's me describe what is going to happen without upgrade of the > > > userspace tools. The 1st reconnect will cause proper resolving of DNS > > > name and storing this name into the cache. All subsequent reconnects > > > will use the value stored in the cache and do not attempt to resolve > > > this DNS name. That means the fix will help partially but doesn't > > > break anything. > > > > > > Once the userspace tools are upgraded, the cached DNS name will expire > > > in 10 min, so every reconnect routine happening after that will use > > > new IP. So, Linux distros will fully benefit from the patch once they > > > upgrade the userspace tools but they do not need to synchronize > > > updates of the kernel and the tools. > > > > > > The diff has been generated against the newest kernel but I checked > > > that it cherry-picks to at least 4.4.y (and probably older ones). > > > > > > > Adding Steve to comment on that. > > > > -- > > Best regards, > > Pavel Shilovsky > > Given the seriousness of the problem it fixes (hang on reconnect when > server IP address changes) and that it could reduce possibility of > data loss, this seems like it is reasonable to include in stable for > kernels where it merges cleanly (which as Pavel noted may even include > kernels older than 4.4). Ok, thanks for the information, now queued up. greg k-h