CIFS SMB2/SMB3 does not work for domain based DFS

Bug #1747572 reported by Sergey Fedotov on 2018-02-06
This bug affects 10 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Joseph Salisbury
Joseph Salisbury
Joseph Salisbury

Bug Description

There is upstream bug report:

"Fix was merged upstream and should be in the next kernel update. Ask your distribution maintainers to backport it." Aurélien Aptel

It looks like the following patches should be backported:

[v3,3/3] CIFS: dump IPC tcon in debug proc file
[v3,2/3] CIFS: use tcon_ipc instead of use_ipc parameter of SMB2_ioctl
[v3,1/3] CIFS: make IPC a regular tcon

Link to patchwork:

ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: linux-image-4.13.0-32-generic 4.13.0-32.35~16.04.1
ProcVersionSignature: Ubuntu 4.13.0-32.35~16.04.1-generic 4.13.13
Uname: Linux 4.13.0-32-generic x86_64
ApportVersion: 2.20.1-0ubuntu2.15
Architecture: amd64
Date: Tue Feb 6 09:50:57 2018
SourcePackage: linux-hwe
UpgradeStatus: No upgrade log present (probably fresh install)

Sergey Fedotov (sr-fido) wrote :
Sergey Fedotov (sr-fido) wrote :

Why no activity at all? Should I post this bug to Debian?

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in linux-hwe (Ubuntu):
status: New → Confirmed
gsd (gonimar) wrote :


Anton Barsukov (eye-scuzzy) wrote :


Agandeev Anton (toshagnk) wrote :


Vladimir Mauser (mauser7x63) wrote :


Tikhonov Nikita (ch4r1k) wrote :


affects: linux-hwe (Ubuntu) → linux (Ubuntu)
Changed in linux (Ubuntu):
status: Confirmed → New
tags: added: kernel-da-key
Changed in linux (Ubuntu Artful):
importance: Undecided → Medium
Changed in linux (Ubuntu):
importance: Undecided → Medium
status: New → Triaged
Changed in linux (Ubuntu Artful):
status: New → Triaged
Joseph Salisbury (jsalisbury) wrote :

I built a test kernel with the three commits mentioned in the description. The test kernel can be downloaded from:

Can you test this kernel and see if it resolves this bug?

Note, to test this kernel, you need to install both the linux-image and linux-image-extra .deb packages.

Thanks in advance!

Sergey Fedotov (sr-fido) wrote :

Thanks! Bug is resolved. Mount command was successful without errors. Tested 1.0/2.0/2.1/3.0 versions.
One red in dmesg: "CIFS VFS: BAD_NETWORK_NAME: \\domain.local\storage"

Joseph Salisbury (jsalisbury) wrote :
Changed in linux (Ubuntu Artful):
status: Triaged → In Progress
Changed in linux (Ubuntu Bionic):
status: Triaged → In Progress
Changed in linux (Ubuntu Artful):
assignee: nobody → Joseph Salisbury (jsalisbury)
Changed in linux (Ubuntu Bionic):
assignee: nobody → Joseph Salisbury (jsalisbury)
Changed in linux (Ubuntu Artful):
status: In Progress → Fix Committed
Seth Forshee (sforshee) on 2018-03-15
Changed in linux (Ubuntu Bionic):
status: In Progress → Fix Committed
Stefan Bader (smb) wrote :

This bug is awaiting verification that the kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed-artful' to 'verification-done-artful'. If the problem still exists, change the tag 'verification-needed-artful' to 'verification-failed-artful'.

If verification is not done by 5 working days from today, this fix will be dropped from the source code, and this bug will be closed.

See for documentation how to enable and use -proposed. Thank you!

tags: added: verification-needed-artful
Sergey Fedotov (sr-fido) wrote :

Successfully tested in xenial. All mount commands is work.

  Version table:
 *** 500
        500 xenial-proposed/main amd64 Packages
        100 /var/lib/dpkg/status

Sergey Fedotov (sr-fido) wrote :

TEST FAIL in artful with that kernel:

  Version table:
 *** 500
        500 artful-proposed/main amd64 Packages
        100 /var/lib/dpkg/status

Looks like kernel not patched at all. Is there any mistake? Why kernel in artful lesser than in xenial?

Sergey Fedotov (sr-fido) wrote :

People, please, help with feedback.

Stefan Bader (smb) wrote :

@Sergey, you are looking at the version number of two different meta packages. One is providing the 4.13 kernel in the Xenial release and the other the 4.13 kernel within the Artful release. The more important part is that you are *running* the right kernel (uname -a). The output should contain 4.13.0-38 in both cases. The base of the HWE kernel in Xenial is the Artful kernel, so the patches are applied to both.

Sergey Fedotov (sr-fido) wrote :

I'm pretty sure I tested the latest kernels from proposed. But in case with artful test fail with old symptoms. Futhermore mounting DFS share with SMB1 protocol fails too with error: "mount error(6): No such device or address" and dmesg output: "
cifs_mount failed w/return code = -6"
I have nothing to compare, because I have not tested artful before patch, but it is strange for me that the patch works for xenial but not for artful. I tested twice.

Sergey Fedotov (sr-fido) wrote :

Direct shares was mounted successfuly in both distros.

Sergey Fedotov (sr-fido) wrote :

Sorry, it was my bad :)
Tests in artful successfuly PASSED. All protocols works as expected.
The reason they were fail was trivial. According to docs "To use cifs Kerberos and DFS support, the Linux keyutils package should be installed" what was not true :o)
Can you change tag to verification-done ?\

Some output:

root@1710-vm:~# dmesg -C
root@1710-vm:~# mount.cifs //domain.local/storage T -o user=fedotov_sv,vers=3.0 --verbose
Password for fedotov_sv@//taximaxim.local/storage: ******
mount.cifs kernel mount options: ip=,unc=\\domain.local\storage,vers=3.0,user=fedotov_sv,pass=********
root@1710-vm:~# dmesg
[ 1466.111037] Status code returned 0xc0000016 STATUS_MORE_PROCESSING_REQUIRED
[ 1466.114665] Status code returned 0xc00000cc STATUS_BAD_NETWORK_NAME
[ 1466.114670] CIFS VFS: BAD_NETWORK_NAME: \\domain.local\storage
[ 1466.118649] Status code returned 0xc0000016 STATUS_MORE_PROCESSING_REQUIRED
root@1710-vm:~# mountpoint T
T is a mountpoint
root@1710-vm:~# cat /proc/fs/cifs/DebugData
Display Internal CIFS Data Structures for Debugging
CIFS Version 2.09
Features: dfs fscache lanman posix spnego xattr acl
Active VFS Requests: 0
Number of credits: 31
1) entry for not fully displayed
        TCP status: 1
        Local Users To Server: 1 SecMode: 0x1 Req On Wire: 0
        0) IPC: \\\IPC$ Mounts: 1 DevInfo: 0x0 Attributes: 0x0
        PathComponentMax: 0 Status: 1 type: 0
        Share Capabilities: None Share Flags: 0x30

        1) \\FS00-001\storage Mounts: 1 DevInfo: 0x20020 Attributes: 0xc700ff
        PathComponentMax: 255 Status: 1 type: DISK
        Share Capabilities: DFS, Aligned, Partition Aligned, Share Flags: 0x3 Optimal sector size: 0x200

Stefan Bader (smb) wrote :

@Sergey, glad this was successful now. Thanks for verifying, I marked the status as done now.

tags: added: verification-done-artful
removed: verification-needed-artful
Launchpad Janitor (janitor) wrote :
Download full text (32.6 KiB)

This bug was fixed in the package linux - 4.15.0-13.14

linux (4.15.0-13.14) bionic; urgency=medium

  * linux: 4.15.0-13.14 -proposed tracker (LP: #1756408)

  * devpts: handle bind-mounts (LP: #1755857)
    - SAUCE: devpts: hoist out check for DEVPTS_SUPER_MAGIC
    - SAUCE: devpts: resolve devpts bind-mounts
    - SAUCE: devpts: comment devpts_mntget()
    - SAUCE: selftests: add devpts selftests

  * [bionic][arm64] d-i: add hisi_sas_v3_hw to scsi-modules (LP: #1756103)
    - d-i: add hisi_sas_v3_hw to scsi-modules

  * [Bionic][ARM64] enable ROCE and HNS3 driver support for hip08 SoC
    (LP: #1756097)
    - RDMA/hns: Refactor eq code for hip06
    - RDMA/hns: Add eq support of hip08
    - RDMA/hns: Add detailed comments for mb() call
    - RDMA/hns: Add rq inline data support for hip08 RoCE
    - RDMA/hns: Update the usage of sr_max and rr_max field
    - RDMA/hns: Set access flags of hip08 RoCE
    - RDMA/hns: Filter for zero length of sge in hip08 kernel mode
    - RDMA/hns: Fix QP state judgement before sending work requests
    - RDMA/hns: Assign dest_qp when deregistering mr
    - RDMA/hns: Fix endian problems around imm_data and rkey
    - RDMA/hns: Assign the correct value for tx_cqn
    - RDMA/hns: Create gsi qp in hip08
    - RDMA/hns: Add gsi qp support for modifying qp in hip08
    - RDMA/hns: Fill sq wqe context of ud type in hip08
    - RDMA/hns: Assign zero for pkey_index of wc in hip08
    - RDMA/hns: Update the verbs of polling for completion
    - RDMA/hns: Set the guid for hip08 RoCE device
    - net: hns3: Refactor of the reset interrupt handling logic
    - net: hns3: Add reset service task for handling reset requests
    - net: hns3: Refactors the requested reset & pending reset handling code
    - net: hns3: Add HNS3 VF IMP(Integrated Management Proc) cmd interface
    - net: hns3: Add mailbox support to VF driver
    - net: hns3: Add HNS3 VF HCL(Hardware Compatibility Layer) Support
    - net: hns3: Add HNS3 VF driver to kernel build framework
    - net: hns3: Unified HNS3 {VF|PF} Ethernet Driver for hip08 SoC
    - net: hns3: Add mailbox support to PF driver
    - net: hns3: Change PF to add ring-vect binding & resetQ to mailbox
    - net: hns3: Add mailbox interrupt handling to PF driver
    - net: hns3: add support to query tqps number
    - net: hns3: add support to modify tqps number
    - net: hns3: change the returned tqp number by ethtool -x
    - net: hns3: free the ring_data structrue when change tqps
    - net: hns3: get rss_size_max from configuration but not hardcode
    - net: hns3: add a mask initialization for mac_vlan table
    - net: hns3: add vlan offload config command
    - net: hns3: add ethtool related offload command
    - net: hns3: add handling vlan tag offload in bd
    - net: hns3: cleanup mac auto-negotiation state query
    - net: hns3: fix for getting auto-negotiation state in hclge_get_autoneg
    - net: hns3: add support for set_pauseparam
    - net: hns3: add support to update flow control settings after autoneg
    - net: hns3: add Asym Pause support to phy default features
    - net: hns3: add support for querying advertised pause frame by ethtool ethx
    - net:...

Changed in linux (Ubuntu Bionic):
status: Fix Committed → Fix Released
Launchpad Janitor (janitor) wrote :
Download full text (18.9 KiB)

This bug was fixed in the package linux - 4.13.0-38.43

linux (4.13.0-38.43) artful; urgency=medium

  * linux: 4.13.0-38.43 -proposed tracker (LP: #1755762)

  * Servers going OOM after updating kernel from 4.10 to 4.13 (LP: #1748408)
    - i40e: Fix memory leak related filter programming status
    - i40e: Add programming descriptors to cleaned_count

  * [SRU] Lenovo E41 Mic mute hotkey is not responding (LP: #1753347)
    - platform/x86: ideapad-laptop: Increase timeout to wait for EC answer

  * fails to dump with latest kpti fixes (LP: #1750021)
    - kdump: write correct address of mem_section into vmcoreinfo

  * headset mic can't be detected on two Dell machines (LP: #1748807)
    - ALSA: hda/realtek - Support headset mode for ALC215/ALC285/ALC289
    - ALSA: hda - Fix headset mic detection problem for two Dell machines
    - ALSA: hda - Fix a wrong FIXUP for alc289 on Dell machines

  * CIFS SMB2/SMB3 does not work for domain based DFS (LP: #1747572)
    - CIFS: make IPC a regular tcon
    - CIFS: use tcon_ipc instead of use_ipc parameter of SMB2_ioctl
    - CIFS: dump IPC tcon in debug proc file

  * i2c-thunderx: erroneous error message "unhandled state: 0" (LP: #1754076)
    - i2c: octeon: Prevent error message on bus error

  * hisi_sas: Add disk LED support (LP: #1752695)
    - scsi: hisi_sas: directly attached disk LED feature for v2 hw

  * EDAC, sb_edac: Backport 1 patch to Ubuntu 17.10 (Fix missing DIMM sysfs
    entries with KNL SNC2/SNC4 mode) (LP: #1743856)
    - EDAC, sb_edac: Fix missing DIMM sysfs entries with KNL SNC2/SNC4 mode

  * [regression] Colour banding and artefacts appear system-wide on an Asus
    Zenbook UX303LA with Intel HD 4400 graphics (LP: #1749420)
    - drm/edid: Add 6 bpc quirk for CPT panel in Asus UX303LA

  * DVB Card with SAA7146 chipset not working (LP: #1742316)
    - vmalloc: fix __GFP_HIGHMEM usage for vmalloc_32 on 32b systems

  * [Asus UX360UA] battery status in unity-panel is not changing when battery is
    being charged (LP: #1661876) // AC adapter status not detected on Asus
    ZenBook UX410UAK (LP: #1745032)
    - ACPI / battery: Add quirk for Asus UX360UA and UX410UAK

  * ASUS UX305LA - Battery state not detected correctly (LP: #1482390)
    - ACPI / battery: Add quirk for Asus GL502VSK and UX305LA

  * support thunderx2 vendor pmu events (LP: #1747523)
    - perf pmu: Extract function to get JSON alias map
    - perf pmu: Pass pmu as a parameter to get_cpuid_str()
    - perf tools arm64: Add support for get_cpuid_str function.
    - perf pmu: Add helper function is_pmu_core to detect PMU CORE devices
    - perf vendor events arm64: Add ThunderX2 implementation defined pmu core
    - perf pmu: Add check for valid cpuid in perf_pmu__find_map()

  * lpfc.ko module doesn't work (LP: #1746970)
    - scsi: lpfc: Fix loop mode target discovery

  * Ubuntu 17.10 crashes on vmalloc.c (LP: #1739498)
    - powerpc/mm/book3s64: Make KERN_IO_START a variable
    - powerpc/mm/slb: Move comment next to the code it's referring to
    - powerpc/mm/hash64: Make vmalloc 56T on hash

  * ethtool -p fails to light NIC LED on HiSilicon D05 systems (LP: #1748567)
    - net...

Changed in linux (Ubuntu Artful):
status: Fix Committed → Fix Released
Sergey Fedotov (sr-fido) wrote :

Finally :) Thanks all for you work!

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.